Class BaseDataLevelBucket
- java.lang.Object
-
- net.sf.jasperreports.engine.analytics.dataset.BaseDataLevelBucket
-
- All Implemented Interfaces:
java.io.Serializable,java.lang.Cloneable,DataLevelBucket,JRCloneable
- Direct Known Subclasses:
DesignDataLevelBucket
public class BaseDataLevelBucket extends java.lang.Object implements DataLevelBucket, java.io.Serializable
- Author:
- Lucian Chirita (lucianc@users.sourceforge.net)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected java.util.List<DataLevelBucketProperty>bucketPropertiesprotected JRExpressioncomparatorExpressionstatic java.lang.StringEXCEPTION_MESSAGE_KEY_BUCKET_LOAD_ERRORprotected JRExpressionexpressionprotected JRExpressionlabelExpressionprotected BucketOrderorderprotected SortOrderEnumorderValueDeprecated.protected java.lang.Class<?>valueClassprotected java.lang.StringvalueClassNameprotected java.lang.StringvalueClassRealName
-
Constructor Summary
Constructors Modifier Constructor Description protectedBaseDataLevelBucket()BaseDataLevelBucket(DataLevelBucket bucket, JRBaseObjectFactory factory)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Objectclone()java.util.List<DataLevelBucketProperty>getBucketProperties()JRExpressiongetComparatorExpression()Returns the comparator expression.JRExpressiongetExpression()Returns the grouping expression.JRExpressiongetLabelExpression()Optional expression that provides labels for buckets.BucketOrdergetOrder()Returns the bucket sorting type.java.lang.Class<?>getValueClass()Returns the class of the bucket value.java.lang.StringgetValueClassName()Returns the string name of the bucket value class.
-
-
-
Field Detail
-
EXCEPTION_MESSAGE_KEY_BUCKET_LOAD_ERROR
public static final java.lang.String EXCEPTION_MESSAGE_KEY_BUCKET_LOAD_ERROR
- See Also:
- Constant Field Values
-
valueClassName
protected java.lang.String valueClassName
-
valueClassRealName
protected java.lang.String valueClassRealName
-
valueClass
protected java.lang.Class<?> valueClass
-
orderValue
@Deprecated protected SortOrderEnum orderValue
Deprecated.
-
order
protected BucketOrder order
-
expression
protected JRExpression expression
-
labelExpression
protected JRExpression labelExpression
-
comparatorExpression
protected JRExpression comparatorExpression
-
bucketProperties
protected java.util.List<DataLevelBucketProperty> bucketProperties
-
-
Constructor Detail
-
BaseDataLevelBucket
protected BaseDataLevelBucket()
-
BaseDataLevelBucket
public BaseDataLevelBucket(DataLevelBucket bucket, JRBaseObjectFactory factory)
-
-
Method Detail
-
getValueClassName
public java.lang.String getValueClassName()
Description copied from interface:DataLevelBucketReturns the string name of the bucket value class.- Specified by:
getValueClassNamein interfaceDataLevelBucket
-
getOrder
public BucketOrder getOrder()
Description copied from interface:DataLevelBucketReturns the bucket sorting type.The possible values are:
- Specified by:
getOrderin interfaceDataLevelBucket- Returns:
- the bucket sorting type
- See Also:
DataLevelBucket.getComparatorExpression()
-
getExpression
public JRExpression getExpression()
Description copied from interface:DataLevelBucketReturns the grouping expression.- Specified by:
getExpressionin interfaceDataLevelBucket- Returns:
- the grouping expression
-
getLabelExpression
public JRExpression getLabelExpression()
Description copied from interface:DataLevelBucketOptional expression that provides labels for buckets.- Specified by:
getLabelExpressionin interfaceDataLevelBucket- Returns:
- the bucket label expression
-
getComparatorExpression
public JRExpression getComparatorExpression()
Description copied from interface:DataLevelBucketReturns the comparator expression.The result of this expression is used to sort the buckets, in ascending or descending order (given by
getOrder(). If the order type isBucketOrder.NONE, no sorting will be performed and the comparator expression will be ignored.If no comparator expression is specified, the natural order will be used.
If the bucket has an order by expression, the comparator will be used to compare values as produced by that expression.
- Specified by:
getComparatorExpressionin interfaceDataLevelBucket- Returns:
- the comparator expression
-
getValueClass
public java.lang.Class<?> getValueClass()
Description copied from interface:DataLevelBucketReturns 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 interfaceDataLevelBucket- Returns:
- a Class instance representing the bucket value class
-
getBucketProperties
public java.util.List<DataLevelBucketProperty> getBucketProperties()
- Specified by:
getBucketPropertiesin interfaceDataLevelBucket
-
clone
public java.lang.Object clone()
- Specified by:
clonein interfaceJRCloneable- Overrides:
clonein classjava.lang.Object
-
-