net.sf.jasperreports.crosstabs
Interface JRCrosstabGroup

All Superinterfaces:
java.lang.Cloneable, JRCloneable
All Known Subinterfaces:
JRCrosstabColumnGroup, JRCrosstabRowGroup
All Known Implementing Classes:
JRBaseCrosstabColumnGroup, JRBaseCrosstabGroup, JRBaseCrosstabRowGroup, JRDesignCrosstabColumnGroup, JRDesignCrosstabGroup, JRDesignCrosstabRowGroup, JRFillCrosstabColumnGroup, JRFillCrosstabGroup, JRFillCrosstabRowGroup

public interface JRCrosstabGroup
extends JRCloneable

Base interface for crosstab row and column groups.

Version:
$Id: JRCrosstabGroup.java 5180 2012-03-29 13:23:12Z teodord $
Author:
Lucian Chirita (lucianc@users.sourceforge.net)

Method Summary
 JRCrosstabBucket getBucket()
          Returns the bucketing information for this group.
 JRCellContents getHeader()
          Returns the group header cell.
 java.lang.String getName()
          Returns the name of the group.
 JRCellContents getTotalHeader()
          Returns the group total header cell.
 CrosstabTotalPositionEnum getTotalPositionValue()
          Returns the position of the total row/column for this group.
 JRVariable getVariable()
          Returns the variable associated to this group.
 boolean hasTotal()
          Returns whether the group has a total row/column.
 
Methods inherited from interface net.sf.jasperreports.engine.JRCloneable
clone
 

Method Detail

getName

java.lang.String getName()
Returns the name of the group.

Returns:
the name of the group
See Also:
getVariable()

getTotalPositionValue

CrosstabTotalPositionEnum getTotalPositionValue()
Returns the position of the total row/column for this group.

A group can have a total row/column summing the values for all the entries in the group. E.g. if there is a Year group having Month as a subgroup, the total row/column for the Year group would sum the values for all the years and the total row/column for the Month group would sum the values for all the months of an year.

Possible values for this attribute are:


getBucket

JRCrosstabBucket getBucket()
Returns the bucketing information for this group.

The bucketing information consists of grouping expression and group ordering.

Returns:
the bucketing information for this group

getHeader

JRCellContents getHeader()
Returns the group header cell.

The size of the header cell is computed based on the following rules (only the row header rules are listed, the ones for columns can be deducted by simmetrical duality):

Should never return null, but empty cell contents instead.

Returns:
the group header cell

getTotalHeader

JRCellContents getTotalHeader()
Returns the group total header cell.

The size of a row group total header is computed based on the following rules:

Should never return null, but empty cell contents instead.

Returns:
the group total header cell

getVariable

JRVariable getVariable()
Returns the variable associated to this group.

Each group in the crosstab has a variable that can be used inside the group header as the current group value. The variable has the same name as the group and the same type as the bucket expression of the group.

Returns:
the variable associated to this group

hasTotal

boolean hasTotal()
Returns whether the group has a total row/column.

This method is currently equivalent to getTotalPosition() != Bucket.TOTAL_POSITION_NONE and is therefore redundant.

Returns:
whether the group has a total row/column


© 2001-2010 Jaspersoft Corporation www.jaspersoft.com