Specific Visual Object element for an Area. An Area is a filled polygon, which border is given as a list of geo-coordinates. Areas can have multiple disjunct parts as well as each part can have an arbitrary number of exclusions/holes.
The inner part and the edges of areas are interactive and fire events on click.
Since the actual size of an area depends on the zoom level it might be only partly visible. Thus detail windows will open at the click position.
Constructor for a new Area.
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.vbm.Area(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 |
---|---|---|---|
borderDash | string | Defines the dashing style of the area border using an array. Visibility: public |
|
color | string | The fill color of the Area. Visibility: public |
|
colorBorder | string | The border color of the Area. Visibility: public |
|
position | string | The position array for the Area. For single part areas the format is "lon0;lat0;0.0;...;lonN,latN,0.0". For multi part areas you need to provide an array of arrays of the above position string: "[['lon0...'],['lon0...']]" (sequence of single and double quotes is important). Single and Multi part areas must not be mixed within one Areas aggregation. |
Name | Type | Default Value | Description |
---|---|---|---|
changeable | boolean | false | Set to true if VO is changeable. Which properties are actually changeable can be controlled on the related VO aggregation. Visibility: public |
dragData | string | Data to be dragged. This property allows you to provide an arbitrary data string, which is transfered to the target in a drag'n drop operation Visibility: public |
|
entity | string | The visual object builds an entity/group with other VO elements when it is hovered. The property is not supported when the PlugIn is used. Visibility: public |
|
fxdir | string | true | The visual object is not rotated when the map is rotated. The property is only required when the PlugIn is used and only meaningful for some VOs. Visibility: public |
fxsize | string | true | The visual object should keep its size when the map is zoomed. Default value is 'true'. Only meaningful for some VOs. Visibility: public |
hotDeltaColor | string | RHLSA(0;1.3;1.0;1.0) | Color change applied when visual object is hovered. The format is RHLSA(<hue>;<lightness>;<saturation>;<opacity>). The hue shift is given in degree (0 to 360). The other parameters are given as multipliers, where 1 means the component remains unchanged. |
hotScale | string | 1.0;1.0;1.0 | Scaling factor applied when visual object is hovered. This is only supported on selected VOs, which do not present a defined geo area. Visibility: public |
key | string | Unique identifier for the object. This is optional. If not provided the default identifier sId is used. However, sId is generated if template binding is used and thus it is not stable. Provide the key if the object really needs to have a unique and stable identifier. Visibility: public |
|
labelArrow | boolean | false | The visual objects label arrow. For left/right/top/bottom aligned labels an additional arrow points to the label's object. Visibility: public |
labelBgColor | string | RGB(255;255;255) | The visual objects label background color. The default value is white. Visibility: public |
labelBorderColor | string | The visual objects label border color. The default is no border. Visibility: public |
|
labelPos | string | The visual objects label position. This property determines the positioning of the label relative to the VO it belongs to. Possible values are:
For multiple position based VOs, like Route, or Area the label is dynamically positioned. If the current display of a VO consists of multiple disconnected parts, each part gets an own label.Visibility: public |
|
labelText | string | The visual objects label text. Providing a label text required, but also sufficient the get a label displayed. Visibility: public |
|
labelType | sap.ui.vbm.SemanticType | None | Type for semantic labels. A given semantic type will overrule color settings and add an icon. Visibility: public |
select | boolean | false | Set to true if the element is selected Visibility: public |
selectColor | string | RHLSA(0.0;1.0;1.0;1.0) | Color change applied when visual object is selected. This can be explicit or a relative one. See above. Visibility: public |
Event | Description |
---|---|
edgeClick |
This event is raised when the edge of an Area is clicked. |
edgeContextMenu |
This event is raised when the edge of an Area is right clicked. |
Method | Description |
---|---|
attachEdgeClick |
Attaches event handler When called, the context of the event handler (its This event is raised when the edge of an Area is clicked. |
attachEdgeContextMenu |
Attaches event handler When called, the context of the event handler (its This event is raised when the edge of an Area is right clicked. |
detachEdgeClick |
Detaches event handler The passed function and listener object must match the ones used for event registration. |
detachEdgeContextMenu |
Detaches event handler The passed function and listener object must match the ones used for event registration. |
sap.ui.vbm.Area.extend |
Creates a new subclass of class sap.ui.vbm.Area with name
|
fireEdgeClick |
Fires event edgeClick to attached listeners. |
fireEdgeContextMenu |
Fires event edgeContextMenu to attached listeners. |
getBorderDash |
Gets current value of property borderDash. Defines the dashing style of the area border using an array. |
getColor |
Gets current value of property color. The fill color of the Area. |
getColorBorder |
Gets current value of property colorBorder. The border color of the Area. |
sap.ui.vbm.Area.getMetadata |
Returns a metadata object for class sap.ui.vbm.Area. |
getPosition |
Gets current value of property position. The position array for the Area. For single part areas the format is "lon0;lat0;0.0;...;lonN,latN,0.0". For multi part areas you need to provide an array of arrays of the above position string: "[['lon0...'],['lon0...']]" (sequence of single and double quotes is important). Single and Multi part areas must not be mixed within one Areas aggregation. |
setBorderDash |
Sets a new value for property borderDash. Defines the dashing style of the area border using an array. When called with a value of |
setColor |
Sets a new value for property color. The fill color of the Area. When called with a value of |
setColorBorder |
Sets a new value for property colorBorder. The border color of the Area. When called with a value of |
setPosition |
Sets a new value for property position. The position array for the Area. For single part areas the format is "lon0;lat0;0.0;...;lonN,latN,0.0". For multi part areas you need to provide an array of arrays of the above position string: "[['lon0...'],['lon0...']]" (sequence of single and double quotes is important). Single and Multi part areas must not be mixed within one Areas aggregation. When called with a value of |
Attaches event handler fnFunction
to the edgeClick event of this sap.ui.vbm.Area
.
When called, the context of the event handler (its this
) will be bound to oListener
if specified, otherwise it will be bound to this sap.ui.vbm.Area
itself.
This event is raised when the edge of an Area is clicked.
Param | Type | DefaultValue | Description |
---|---|---|---|
oData | object |
An application-specific payload object that will be passed to the event handler along with the event object when firing the event |
|
fnFunction | function(sap.ui.base.Event) : void |
The function to be called when the event occurs |
|
oListener | object |
Context object to call the event handler with. Defaults to this |
Attaches event handler fnFunction
to the edgeContextMenu event of this sap.ui.vbm.Area
.
When called, the context of the event handler (its this
) will be bound to oListener
if specified, otherwise it will be bound to this sap.ui.vbm.Area
itself.
This event is raised when the edge of an Area is right clicked.
Param | Type | DefaultValue | Description |
---|---|---|---|
oData | object |
An application-specific payload object that will be passed to the event handler along with the event object when firing the event |
|
fnFunction | function(sap.ui.base.Event) : void |
The function to be called when the event occurs |
|
oListener | object |
Context object to call the event handler with. Defaults to this |
Detaches event handler fnFunction
from the edgeClick event of this sap.ui.vbm.Area
.
The passed function and listener object must match the ones used for event registration.
Param | Type | DefaultValue | Description |
---|---|---|---|
fnFunction | function(sap.ui.base.Event) : void |
The function to be called, when the event occurs |
|
oListener | object |
Context object on which the given function had to be called |
Detaches event handler fnFunction
from the edgeContextMenu event of this sap.ui.vbm.Area
.
The passed function and listener object must match the ones used for event registration.
Param | Type | DefaultValue | Description |
---|---|---|---|
fnFunction | function(sap.ui.base.Event) : void |
The function to be called, when the event occurs |
|
oListener | object |
Context object on which the given function had to be called |
Creates a new subclass of class sap.ui.vbm.Area 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.vbm.VoBase.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 |
Fires event edgeClick to attached listeners.
Param | Type | DefaultValue | Description |
---|---|---|---|
mParameters | object |
Parameters to pass along with the event |
Fires event edgeContextMenu to attached listeners.
Param | Type | DefaultValue | Description |
---|---|---|---|
mParameters | object |
Parameters to pass along with the event |
Gets current value of property borderDash.
Defines the dashing style of the area border using an array.
Gets current value of property position.
The position array for the Area. For single part areas the format is "lon0;lat0;0.0;...;lonN,latN,0.0". For multi part areas you need to provide an array of arrays of the above position string: "[['lon0...'],['lon0...']]" (sequence of single and double quotes is important). Single and Multi part areas must not be mixed within one Areas aggregation.
Finally each area part can have multiple exclusions/holes. In that case the position list of excluded areas has follow the list of the base shape: "['lon0...', 'exLon0...']".
Sets a new value for property borderDash.
Defines the dashing style of the area border using an array.
When called with a value of null
or undefined
, the default value of the property will be restored.
Param | Type | DefaultValue | Description |
---|---|---|---|
sBorderDash | string |
New value for property |
Sets a new value for property color.
The fill color of the Area.
When called with a value of null
or undefined
, the default value of the property will be restored.
Param | Type | DefaultValue | Description |
---|---|---|---|
sColor | string |
New value for property |
Sets a new value for property colorBorder.
The border color of the Area.
When called with a value of null
or undefined
, the default value of the property will be restored.
Param | Type | DefaultValue | Description |
---|---|---|---|
sColorBorder | string |
New value for property |
Sets a new value for property position.
The position array for the Area. For single part areas the format is "lon0;lat0;0.0;...;lonN,latN,0.0". For multi part areas you need to provide an array of arrays of the above position string: "[['lon0...'],['lon0...']]" (sequence of single and double quotes is important). Single and Multi part areas must not be mixed within one Areas aggregation.
Finally each area part can have multiple exclusions/holes. In that case the position list of excluded areas has follow the list of the base shape: "['lon0...', 'exLon0...']".
When called with a value of null
or undefined
, the default value of the property will be restored.
Param | Type | DefaultValue | Description |
---|---|---|---|
sPosition | string |
New value for property |