Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## net.sf.jasperreports.engine.component
Class FillPrepareResult

    java.lang.Object
      net.sf.jasperreports.engine.component.FillPrepareResult

    public class FillPrepareResult

extends java.lang.Object

A result of a `component fill preparation`.

Version:
  $Id: FillPrepareResult.java 3033 2009-08-27 11:46:22Z teodord $
Author:
  Lucian Chirita (lucianc@users.sourceforge.net)

Field Summary
`static FillPrepareResult` | `NO_PRINT_NO_OVERFLOW` A result that indicates that the component will not print and does not require a band overflow.
`static FillPrepareResult` | `PRINT_NO_STRETCH` A result that indicates that the component will print, but will not stretch vertically.

Constructor Summary
`FillPrepareResult(boolean toPrint, int stretchHeight, boolean overflow)` Creates a fill preparation result.

Method Summary
`int` | `getStretchHeight()` Returns the amount of vertical space consumed by the component.
`boolean` | `isToPrint()` Returns whether the component will produce a print element at the current position in the generated report.
`static FillPrepareResult` | `noPrintOverflow(int stretchHeight)` Returns a result that indicates that the component will not print (at the current position in the generated report), but requires an overflow so that it can print on a new column/page.
`static FillPrepareResult` | `printStretch(int stretchHeight, boolean overflow)` Returns a result which indicates that the component will print at the current position, and optionally consume more vertical space and/or require a band overflow.
`boolean` | `willOverflow()` Returns whether a band overflow is required in order to continue the component fill on a new column/page.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### NO_PRINT_NO_OVERFLOW

    public static final FillPrepareResult NO_PRINT_NO_OVERFLOW

  A result that indicates that the component will not print and does not require a band overflow.

  This result would be used when the component does not intend to include any print element in the generated report.

### PRINT_NO_STRETCH

    public static final FillPrepareResult PRINT_NO_STRETCH

  A result that indicates that the component will print, but will not stretch vertically.

  This would be used when the component will produce a print element that fits the space allocated at design time for the component element.

Constructor Detail

### FillPrepareResult

    public FillPrepareResult(boolean toPrint,
                             int stretchHeight,
                             boolean overflow)

  Creates a fill preparation result.

  Parameters:
    `toPrint` - indicates whether the component will produce a print element at the current position in the generated report
    `stretchHeight` - the amount of vertical space consumed by the component
    `overflow` - indicates whether a band overflow is required in order to continue the component fill on a new column/page

Method Detail

### noPrintOverflow

    public static FillPrepareResult noPrintOverflow(int stretchHeight)

  Returns a result that indicates that the component will not print (at the current position in the generated report), but requires an overflow so that it can print on a new column/page.

  Parameters:
    `stretchHeight` - the height that is consumed by the component; usually this would be the same as the `availableHeight` argument passed to `FillComponent.prepare(int)`
  Returns:
    a result as described above

### printStretch

    public static FillPrepareResult printStretch(int stretchHeight,
                                                 boolean overflow)

  Returns a result which indicates that the component will print at the current position, and optionally consume more vertical space and/or require a band overflow.

  Parameters:
    `stretchHeight` - the stretched height of the component
    `overflow` - whether a band overflow is required so that the component would continue printing on a new column/page
  Returns:
    a result that the component will print with the specified stretch height and overflow flag

### isToPrint

    public boolean isToPrint()

  Returns whether the component will produce a print element at the current position in the generated report.

  Returns:
    whether the component will print

### willOverflow

    public boolean willOverflow()

  Returns whether a band overflow is required in order to continue the component fill on a new column/page.

  Returns:
    whether a band overflow is required

### getStretchHeight

    public int getStretchHeight()

  Returns the amount of vertical space consumed by the component.

  Returns:
    the amount of vertical space consumed by the component

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

© 2001-2010 Jaspersoft Corporation www.jaspersoft.com