The Item for the field/property metadata used within MDC controls, an instance can be created to override the default/metadata behavior.
The control is experimental and the API/behaviour is not finalised and hence this should not be used for productive usage.
Constructor for a new measure Item.
Accepts an object literal mSettings
that defines initial property values, aggregated and associated objects as well as event handlers. See sap.ui.base.ManagedObject#constructor for a general description of the syntax of the settings object.
new sap.ui.mdc.chart.MeasureItem(sId?, mSettings?)
Param | Type | Default Value | Description |
---|---|---|---|
sId? | string | ID for the new control, generated automatically if no ID is given |
|
mSettings? | object | initial settings for the new control |
Name | Type | Default Value | Description |
---|---|---|---|
aggregationMethod | string | undefined | The aggregation method which depends on the data service. For OData based services this can be |
dataPoint | object | The measures data point for coloring A data point is an object that defines relation between measures and criticality it is inspired by a @com.sap.vocabularies.UI.v1.DataPoint used in the odata protocol Its structure is:
Since: 1.64.Visibility: public |
|
propertyPath | string | The property path of the chart item which may differ from the corresponsing property Visibility: public |
|
role | string | axis1 | How values of Measure will be rendered in the chart. Possible role values are axis1, axis2, axis3, and axis4. The default is axis1. They correspond to the well-known concepts of axis identifiers in the Cartesian coordinate system, e.g. a Y-axis in a bar/column/line chart, an X- and a Y-axis in a scatter chart, or two Y-axes in bar charts, and an optional third axis for the weight/size/intensity/temperature of a data point. You can create a new measure as follow: ... new sap.chart.data.Measure({name: "MEASURE1", role: sap.chart.data.MeasureRoleType.axis1}) ... Detailed usage of measure role. Please refer to MeasureRoleType NOTE: Role definition would not work for Bullet Chart and users need to set semantics instead. Visibility: public |
Name | Type | Default Value | Description |
---|---|---|---|
key | string | The unique identifier of the chart item which reflects to the name of the data property in the resulting data set Visibility: public |
|
label | string | Label for the item, either as a string literal or by a pointer using the binding syntax to some property containing the label. NOTE: This property was bound internally if automatically created via metadata of oData service and please call "unbindProperty" before setting. Visibility: public |
|
type | string | string | The data type Visibility: public |
visible | boolean | true | The visibility of the chart item Visibility: public |
Method | Description |
---|---|
sap.ui.mdc.chart.MeasureItem.createVizChartItem |
Creates a vizChart Item with given settings |
sap.ui.mdc.chart.MeasureItem.extend |
Creates a new subclass of class sap.ui.mdc.chart.MeasureItem with name
|
getAdditionalColoringMeasures |
Retrieve the additional measures from coloring for initially equiping the chart |
getAggregationMethod |
Gets current value of property aggregationMethod. The aggregation method which depends on the data service. For OData based services this can be Default value is |
getDataPoint |
Gets current value of property dataPoint. The measures data point for coloring A data point is an object that defines relation between measures and criticality it is inspired by a @com.sap.vocabularies.UI.v1.DataPoint used in the odata protocol Its structure is:
|
sap.ui.mdc.chart.MeasureItem.getMetadata |
Returns a metadata object for class sap.ui.mdc.chart.MeasureItem. |
getPropertyPath |
Gets current value of property propertyPath. The property path of the chart item which may differ from the corresponsing property |
getRole |
Gets current value of property role. How values of Measure will be rendered in the chart. Possible role values are axis1, axis2, axis3, and axis4. The default is axis1. They correspond to the well-known concepts of axis identifiers in the Cartesian coordinate system, e.g. a Y-axis in a bar/column/line chart, an X- and a Y-axis in a scatter chart, or two Y-axes in bar charts, and an optional third axis for the weight/size/intensity/temperature of a data point. You can create a new measure as follow: ... new sap.chart.data.Measure({name: "MEASURE1", role: sap.chart.data.MeasureRoleType.axis1}) ... Detailed usage of measure role. Please refer to MeasureRoleType NOTE: Role definition would not work for Bullet Chart and users need to set semantics instead. Default value is |
getSettings |
Retrieve the setting for translating the measure item to a viz chart measure |
sap.ui.mdc.chart.MeasureItem.getVizItemSettings |
Translate mdc measure item settings to viz chart measure settings |
getVizItemType |
Gets the type of the item (dimension or measure) |
setAggregationMethod |
Sets a new value for property aggregationMethod. The aggregation method which depends on the data service. For OData based services this can be When called with a value of Default value is |
setDataPoint |
Set the data point for coloring. Note the 'dataPoint' property is final |
setPropertyPath |
Sets a new value for property propertyPath. The property path of the chart item which may differ from the corresponsing property When called with a value of |
setRole |
Role of the inner chart item, see @sap.ui.mdc.ChartItemRoleType |
toChart |
Pushes updates on the item to the inner chart |
toVizChartItem |
Returns a promise that resolves to a Vizchart Item with given metadata |
Creates a vizChart Item with given settings
Param | Type | DefaultValue | Description |
---|---|---|---|
mSettings | any |
settings for the item |
Creates a new subclass of class sap.ui.mdc.chart.MeasureItem with name sClassName
and enriches it with the information contained in oClassInfo
.
oClassInfo
might contain the same kind of information as described in sap.ui.mdc.chart.Item.extend.
Param | Type | DefaultValue | Description |
---|---|---|---|
sClassName | string |
Name of the class being created |
|
oClassInfo | object |
Object literal with information about the class |
|
FNMetaImpl | function |
Constructor function for the metadata object; if not given, it defaults to the metadata implementation used by this class |
Retrieve the additional measures from coloring for initially equiping the chart
Param | Type | DefaultValue | Description |
---|---|---|---|
mItems | undefined |
Gets current value of property aggregationMethod.
The aggregation method which depends on the data service.
For OData based services this can be min,max,sum,average
Default value is undefined
.
Gets current value of property dataPoint.
The measures data point for coloring
A data point is an object that defines relation between measures and criticality it is inspired by a @com.sap.vocabularies.UI.v1.DataPoint used in the odata protocol
Its structure is:
Returns a metadata object for class sap.ui.mdc.chart.MeasureItem.
Gets current value of property propertyPath.
The property path of the chart item which may differ from the corresponsing property
Gets current value of property role.
How values of Measure will be rendered in the chart. Possible role values are axis1, axis2, axis3, and axis4. The default is axis1. They correspond to the well-known concepts of axis identifiers in the Cartesian coordinate system, e.g. a Y-axis in a bar/column/line chart, an X- and a Y-axis in a scatter chart, or two Y-axes in bar charts, and an optional third axis for the weight/size/intensity/temperature of a data point.
You can create a new measure as follow:
... new sap.chart.data.Measure({name: "MEASURE1", role: sap.chart.data.MeasureRoleType.axis1}) ...
Detailed usage of measure role. Please refer to MeasureRoleType
NOTE: Role definition would not work for Bullet Chart and users need to set semantics instead.
Default value is "axis1"
.
Retrieve the setting for translating the measure item to a viz chart measure
Param | Type | DefaultValue | Description |
---|---|---|---|
mMetadataSettings | undefined |
Translate mdc measure item settings to viz chart measure settings
Param | Type | DefaultValue | Description |
---|---|---|---|
mMetadataSettings | undefined |
Sets a new value for property aggregationMethod.
The aggregation method which depends on the data service.
For OData based services this can be min,max,sum,average
When called with a value of null
or undefined
, the default value of the property will be restored.
Default value is undefined
.
Param | Type | DefaultValue | Description |
---|---|---|---|
sAggregationMethod | string |
New value for property |
Set the data point for coloring.
Note the 'dataPoint' property is final
Param | Type | DefaultValue | Description |
---|---|---|---|
oValue | undefined |
Sets a new value for property propertyPath.
The property path of the chart item which may differ from the corresponsing property
When called with a value of null
or undefined
, the default value of the property will be restored.
Param | Type | DefaultValue | Description |
---|---|---|---|
sPropertyPath | string |
New value for property |
Role of the inner chart item, see @sap.ui.mdc.ChartItemRoleType
Param | Type | DefaultValue | Description |
---|---|---|---|
vRole | undefined |
The role of the inner chart item |