borland Packages  Class Hierarchy  dx.dataset Package 

AggDescriptor class

java.lang.Object
   +----com.borland.dx.dataset.AggDescriptor

About the AggDescriptor class

Constructors  Properties  Methods  

Implements Serializable

The AggDescriptor class collects the properties associated with an aggregation calculation. It is associated with a Column by the Column component's agg property.

Set the agg property of a Column component to an instance of this class to define the type of aggregation to perform: count, sum, minimum value or maximum value. You specify a single column for the aggregation operation. You can optionally include a set of Column names to base the grouping logic of the aggregation (subtotals) or, if left unspecified, the calculation is maintained across an entire DataSet.

The update order of calc, lookup and aggregate columns is as follows:

  1. All lookup values are initialized in the row that is passed to the CalcFields event handler. Calculations on aggregates must be performed in the calcAggAdd() and calcAggDelete() event handlers.

    Note: DataSet.addRow() and DataSet.updateRow() methods will be modifed with the appropriate lookup values for any lookup columns they may contain before the calcFields event is called.

  2. The calcAggAdd and calcAggDelete event handlers are both called after the non-calculated aggregates have been updated for add or delete operations. An update operation is performed as a delete and then followed by an add operation.

AggDescriptor constructors

AggDescriptor properties

*Read-only properties **Write-only properties

Properties implemented in this class

Properties implemented in java.lang.Object

AggDescriptor methods

Methods implemented in java.lang.Object


AggDescriptor constructors

AggDescriptor(java.lang.String[], java.lang.String, com.borland.dx.dataset.AggOperator)

  public AggDescriptor(String[]groupColumnNames, String aggColumnName, AggOperator aggOperator)
Constructs an AggDescriptor object with the specified parameters.

Parameters:

groupColumnNames
An array of Column names that define the groups of rows to aggregate on.
aggColumnName
The name of the Column to perform the aggregation on.
aggOperator
The aggregation operation to perform. See the aggOperator property for valid values.

AggDescriptor properties

aggColumnName

 public String getAggColumnName()
Read-only property that returns the Column (by name) to perform the aggregation on.

aggOperator

 public AggOperator getAggOperator()
Read-only property that specifies the aggregation operation to perform. Valid values are:

groupColumnNames

 public String[]getGroupColumnNames()
Read-only property that returns the array of Column names that define the groups of rows to aggregate on.