Pakket | mx.collections |
Klasse | public class SummaryField |
Overerving | SummaryField Object |
Taalversie: | ActionScript 3.0 |
Productversie: | Flex 3 |
Runtimeversies: | Flash Player 9, AIR 1.1 |
Use the dataField
property to specify the data field used to generate the summary,
the label
property to specify the name of the data field created to hold the summary data,
and the operation
property to specify how to create the summary for numeric fields.
You can specify one of the following values:
SUM
, MIN
, MAX
, AVG
, or COUNT
.
The following example creates summary rows based on two fields of the data provider of the AdvancedDataGrid control:
<mx:AdvancedDataGrid id="myADG" initialize="gc.refresh();"> <mx:dataProvider> <mx:GroupingCollection id="gc" source="{dpFlat}"> <mx:Grouping> <mx:GroupingField name="Region"> <mx:summaries> <mx:SummaryRow summaryPlacement="group"> <mx:fields> <mx:SummaryField dataField="Actual" label="Min Actual" operation="MIN"/> <mx:SummaryField dataField="Actual" label="Max Actual" operation="MAX"/> </mx:fields> </mx:SummaryRow> </mx:summaries> </mx:GroupingField> <mx:GroupingField name="Territory"> <mx:summaries> <mx:SummaryRow summaryPlacement="group"> <mx:fields> <mx:SummaryField dataField="Actual" label="Min Actual" operation="MIN"/> <mx:SummaryField dataField="Actual" label="Max Actual" operation="MAX"/> </mx:fields> </mx:SummaryRow> </mx:summaries> </mx:GroupingField> </mx:Grouping> </mx:GroupingCollection> </mx:dataProvider> <mx:columns> <mx:AdvancedDataGridColumn dataField="Region"/> <mx:AdvancedDataGridColumn dataField="Territory_Rep" headerText="Territory Rep"/> <mx:AdvancedDataGridColumn dataField="Actual"/> <mx:AdvancedDataGridColumn dataField="Estimate"/> <mx:AdvancedDataGridColumn dataField="Min Actual"/> <mx:AdvancedDataGridColumn dataField="Max Actual"/> </mx:columns> </mx:AdvancedDataGrid>
This Class has been deprecated and replaced by a new Class
SummaryField2
.
Properties operation
and summaryFunction
are
not present in the Class SummaryField2
.
A new property summaryOperation
is introduced in
SummaryField2
.
Verwante API-elementen
Eigenschap | Gedefinieerd door | ||
---|---|---|---|
constructor : Object
Verwijzing naar het klasseobject of de constructorfunctie van een bepaalde objectinstantie. | Object | ||
dataField : String
Data field for which the summary is computed. | SummaryField | ||
label : String
The property used inside the summary object,
an instance of the SummaryObject class, to
hold summary information. | SummaryField | ||
operation : String = "SUM"
The function that should be performed on the children. | SummaryField | ||
summaryFunction : Function
Specifies a callback function to compute a custom data summary. | SummaryField |
Methode | Gedefinieerd door | ||
---|---|---|---|
Constructor. | SummaryField | ||
Geeft aan of voor een object een opgegeven eigenschap is gedefinieerd. | Object | ||
Geeft aan of een instantie van de klasse Object zich in de prototypeketen van het object bevindt dat als parameter is opgegeven. | Object | ||
Geeft aan of de opgegeven eigenschap bestaat en kan worden opgesomd. | Object | ||
Stelt de beschikbaarheid van een dynamische eigenschap voor lusbewerkingen in. | Object | ||
Geeft de tekenreeksweergave van dit object weer, geformatteerd volgens de locatiespecifieke conventies. | Object | ||
Retourneert een tekenreeksrepresentatie van het opgegeven object. | Object | ||
Retourneert de primitieve waarde van het opgegeven object. | Object |
dataField | eigenschap |
public var dataField:String
Taalversie: | ActionScript 3.0 |
Productversie: | Flex 3 |
Runtimeversies: | Flash Player 9, AIR 1.1 |
Data field for which the summary is computed.
label | eigenschap |
public var label:String
Taalversie: | ActionScript 3.0 |
Productversie: | Flex 3 |
Runtimeversies: | Flash Player 9, AIR 1.1 |
The property used inside the summary object, an instance of the SummaryObject class, to hold summary information.
For example, if you set the label
property to "Summary",
then the computed summary is placed in a property named "Summary"
in the summary object. The property of the SummaryObject instance
containing the summary data will appear as below:
{Summary:1000}
Verwante API-elementen
operation | eigenschap |
public var operation:String = "SUM"
Taalversie: | ActionScript 3.0 |
Productversie: | Flex 3 |
Runtimeversies: | Flash Player 9, AIR 1.1 |
The function that should be performed on the children.
You can specify one of the following values for numeric fields:
SUM
, MIN
, MAX
, AVG
, or COUNT
.
De standaardwaarde is SUM.
summaryFunction | eigenschap |
public var summaryFunction:Function
Taalversie: | ActionScript 3.0 |
Productversie: | Flex 3 |
Runtimeversies: | Flash Player 9, AIR 1.1 |
Specifies a callback function to compute a custom data summary.
You use this property with the SummaryRow.summaryObjectFunction
property,
which defines an instance of the SummaryObject class used
to collect summary data for display in the AdvancedDataGrid control.
The function signature should be as follows:
function mySummaryFunction(iterator:IViewCursor, dataField:String, operation:String):Object
The built-in summary functions for SUM
, MIN
,
MAX
, AVG
, and COUNT
all return a Number containing
the summary data.
Verwante API-elementen
SummaryField | () | Constructor |
public function SummaryField(dataField:String = null, operation:String = "SUM")
Taalversie: | ActionScript 3.0 |
Productversie: | Flex 3 |
Runtimeversies: | Flash Player 9, AIR 1.1 |
Constructor.
ParametersdataField:String (default = null ) — Data field for which the summary is computed.
| |
operation:String (default = "SUM ") — The function that should be performed on the children.
You can specify one of the following values for numeric fields:
SUM , MIN , MAX , AVG , or COUNT .
|
Wed Jun 13 2018, 11:42 AM Z