Class JRBaseCrosstabBucket
- java.lang.Object
-
- net.sf.jasperreports.crosstabs.base.JRBaseCrosstabBucket
-
- All Implemented Interfaces:
Serializable,Cloneable,JRCrosstabBucket,JRCloneable
- Direct Known Subclasses:
JRDesignCrosstabBucket
public class JRBaseCrosstabBucket extends Object implements JRCrosstabBucket, Serializable
Base read-only implementation ofJRCrosstabBucket.- Author:
- Lucian Chirita (lucianc@users.sourceforge.net)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected BucketOrderbucketOrderprotected JRExpressioncomparatorExpressionstatic StringEXCEPTION_MESSAGE_KEY_BUCKET_LOAD_ERRORprotected JRExpressionexpressionprotected JRExpressionorderByExpressionprotected SortOrderEnumorderValueDeprecated.protected Class<?>valueClassprotected StringvalueClassNameprotected StringvalueClassRealName
-
Constructor Summary
Constructors Modifier Constructor Description protectedJRBaseCrosstabBucket()JRBaseCrosstabBucket(JRCrosstabBucket bucket, JRBaseObjectFactory factory)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Objectclone()JRExpressiongetComparatorExpression()Returns the comparator expression.JRExpressiongetExpression()Returns the grouping expression.BucketOrdergetOrder()Returns the bucket sorting type.JRExpressiongetOrderByExpression()Returns an expression that provides order by values for group buckets.Class<?>getValueClass()Returns the class of the bucket value.StringgetValueClassName()Returns the string name of the bucket value class.
-
-
-
Field Detail
-
EXCEPTION_MESSAGE_KEY_BUCKET_LOAD_ERROR
public static final String EXCEPTION_MESSAGE_KEY_BUCKET_LOAD_ERROR
- See Also:
- Constant Field Values
-
valueClassName
protected String valueClassName
-
valueClassRealName
protected String valueClassRealName
-
valueClass
protected transient Class<?> valueClass
-
orderValue
@Deprecated protected SortOrderEnum orderValue
Deprecated.
-
bucketOrder
protected BucketOrder bucketOrder
-
expression
protected JRExpression expression
-
orderByExpression
protected JRExpression orderByExpression
-
comparatorExpression
protected JRExpression comparatorExpression
-
-
Constructor Detail
-
JRBaseCrosstabBucket
protected JRBaseCrosstabBucket()
-
JRBaseCrosstabBucket
public JRBaseCrosstabBucket(JRCrosstabBucket bucket, JRBaseObjectFactory factory)
-
-
Method Detail
-
getValueClassName
public String getValueClassName()
Description copied from interface:JRCrosstabBucketReturns the string name of the bucket value class.- Specified by:
getValueClassNamein interfaceJRCrosstabBucket
-
getOrder
public BucketOrder getOrder()
Description copied from interface:JRCrosstabBucketReturns the bucket sorting type.The possible values are:
- Specified by:
getOrderin interfaceJRCrosstabBucket- Returns:
- the bucket sorting type
- See Also:
JRCrosstabBucket.getComparatorExpression()
-
getExpression
public JRExpression getExpression()
Description copied from interface:JRCrosstabBucketReturns the grouping expression.- Specified by:
getExpressionin interfaceJRCrosstabBucket- Returns:
- the grouping expression
-
getOrderByExpression
public JRExpression getOrderByExpression()
Description copied from interface:JRCrosstabBucketReturns an expression that provides order by values for group buckets. If not set, the bucket values as returned byJRCrosstabBucket.getExpression()are used to order the buckets.The expression is evaluated in the context of the crosstab group and can reference measure variables, which evaluate to group totals.
- Specified by:
getOrderByExpressionin interfaceJRCrosstabBucket- Returns:
- the order by value expression for the group bucket
-
getComparatorExpression
public JRExpression getComparatorExpression()
Description copied from interface:JRCrosstabBucketReturns the comparator expression.The result of this expression is used to sort the buckets, in ascending or descending order (given by
getOrder(). If the bucket has an order by expression, the comparator will be used to compare values as produced by that expression. If no comparator expression is specified, the natural order will be used.- Specified by:
getComparatorExpressionin interfaceJRCrosstabBucket- Returns:
- the comparator expression
- See Also:
JRCrosstabBucket.getOrderByExpression()
-
getValueClass
public Class<?> getValueClass()
Description copied from interface:JRCrosstabBucketReturns the class of the bucket value. Any class is allowed as long as it is in the classpath at compile and run time.- Specified by:
getValueClassin interfaceJRCrosstabBucket- Returns:
- a Class instance representing the bucket value class
-
clone
public Object clone()
- Specified by:
clonein interfaceJRCloneable- Overrides:
clonein classObject
-
-