Class sap.ui.vbm.AreaModule: sap/ui/vbm/Area

extends VoBase

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 Summary
new sap.ui.vbm.Area(sId?, mSettings?)Constructor for a new Area.
Event Summary
edgeClick(oControlEvent)This event is raised when the edge of an Area is clicked.
edgeContextMenu(oControlEvent)This event is raised when the edge of an Area is right clicked.
Method Summary
sap.ui.vbm.Area.extend(sClassName, oClassInfo?, FNMetaImpl?)Creates a new subclass of class sap.ui.vbm.Area with name sClassName and enriches it with the information contained in oClassInfo.
sap.ui.vbm.Area.getMetadata()Returns a metadata object for class sap.ui.vbm.Area.
attachEdgeClick(oData?, fnFunction, oListener?)Attaches event handler fnFunction to the edgeClick event of this sap.ui.vbm.Area.
attachEdgeContextMenu(oData?, fnFunction, oListener?)Attaches event handler fnFunction to the edgeContextMenu event of this sap.ui.vbm.Area.
detachEdgeClick(fnFunction, oListener)Detaches event handler fnFunction from the edgeClick event of this sap.ui.vbm.Area.
detachEdgeContextMenu(fnFunction, oListener)Detaches event handler fnFunction from the edgeContextMenu event of this sap.ui.vbm.Area.
fireEdgeClick(mArguments?)Fires event edgeClick to attached listeners.
fireEdgeContextMenu(mArguments?)Fires event edgeContextMenu to attached listeners.
getBorderDash()Gets current value of property borderDash.
getColor()Gets current value of property color.
getColorBorder()Gets current value of property colorBorder.
getPosition()Gets current value of property position.
setBorderDash(sBorderDash)Sets a new value for property borderDash.
setColor(sColor)Sets a new value for property color.
setColorBorder(sColorBorder)Sets a new value for property colorBorder.
setPosition(sPosition)Sets a new value for property position.
Constructor Detail
new sap.ui.vbm.Area(sId?, mSettings?)
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 for a general description of the syntax of the settings object.

The supported settings are:

  • Properties
  • Events
    • edgeClick : fnListenerFunction or [fnListenerFunction, oListenerObject] or [oData, fnListenerFunction, oListenerObject]
    • edgeContextMenu : fnListenerFunction or [fnListenerFunction, oListenerObject] or [oData, fnListenerFunction, oListenerObject]

In addition, all settings applicable to the base type sap.ui.vbm.VoBase can be used as well.

Parameters:
{string}sId? id for the new control, generated automatically if no id is given
{object}mSettings? initial settings for the new control
Event Detail
edgeClick(oControlEvent)
This event is raised when the edge of an Area is clicked.
Parameters:
{sap.ui.base.Event}oControlEvent
{sap.ui.base.EventProvider}oControlEvent.getSource
{object}oControlEvent.getParameters
edgeContextMenu(oControlEvent)
This event is raised when the edge of an Area is right clicked.
Parameters:
{sap.ui.base.Event}oControlEvent
{sap.ui.base.EventProvider}oControlEvent.getSource
{object}oControlEvent.getParameters
Method Detail
sap.ui.vbm.Area.extend(sClassName, oClassInfo?, FNMetaImpl?): function
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.

Parameters:
{string}sClassName Name of the class being created
{object}oClassInfo? Object literal with information about the class
{function}FNMetaImpl? Constructor function for the metadata object; if not given, it defaults to sap.ui.core.ElementMetadata
Returns:
{function} Created class / constructor function
sap.ui.vbm.Area.getMetadata(): sap.ui.base.Metadata
Returns a metadata object for class sap.ui.vbm.Area.
Returns:
{sap.ui.base.Metadata} Metadata object describing this class
attachEdgeClick(oData?, fnFunction, oListener?): sap.ui.vbm.Area
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.

Parameters:
{object}oData? An application-specific payload object that will be passed to the event handler along with the event object when firing the event
{function}fnFunction The function to be called when the event occurs
{object}oListener? Context object to call the event handler with. Defaults to this sap.ui.vbm.Area itself
Returns:
{sap.ui.vbm.Area} Reference to this in order to allow method chaining
attachEdgeContextMenu(oData?, fnFunction, oListener?): sap.ui.vbm.Area
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.

Parameters:
{object}oData? An application-specific payload object that will be passed to the event handler along with the event object when firing the event
{function}fnFunction The function to be called when the event occurs
{object}oListener? Context object to call the event handler with. Defaults to this sap.ui.vbm.Area itself
Returns:
{sap.ui.vbm.Area} Reference to this in order to allow method chaining
detachEdgeClick(fnFunction, oListener): sap.ui.vbm.Area
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.

Parameters:
{function}fnFunction The function to be called, when the event occurs
{object}oListener Context object on which the given function had to be called
Returns:
{sap.ui.vbm.Area} Reference to this in order to allow method chaining
detachEdgeContextMenu(fnFunction, oListener): sap.ui.vbm.Area
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.

Parameters:
{function}fnFunction The function to be called, when the event occurs
{object}oListener Context object on which the given function had to be called
Returns:
{sap.ui.vbm.Area} Reference to this in order to allow method chaining
fireEdgeClick(mArguments?): sap.ui.vbm.Area
Fires event edgeClick to attached listeners.
Parameters:
{Map}mArguments? The arguments to pass along with the event
Returns:
{sap.ui.vbm.Area} Reference to this in order to allow method chaining
fireEdgeContextMenu(mArguments?): sap.ui.vbm.Area
Fires event edgeContextMenu to attached listeners.
Parameters:
{Map}mArguments? The arguments to pass along with the event
Returns:
{sap.ui.vbm.Area} Reference to this in order to allow method chaining
getBorderDash(): string
Gets current value of property borderDash.

Defines the dashing style of the area border using an array.

Returns:
{string} Value of property borderDash
getColor(): string
Gets current value of property color.

The fill color of the Area.

Returns:
{string} Value of property color
getColorBorder(): string
Gets current value of property colorBorder.

The border color of the Area.

Returns:
{string} Value of property colorBorder
getPosition(): string
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...']".

Returns:
{string} Value of property position
setBorderDash(sBorderDash): sap.ui.vbm.Area
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.

Parameters:
{string}sBorderDash New value for property borderDash
Returns:
{sap.ui.vbm.Area} Reference to this in order to allow method chaining
setColor(sColor): sap.ui.vbm.Area
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.

Parameters:
{string}sColor New value for property color
Returns:
{sap.ui.vbm.Area} Reference to this in order to allow method chaining
setColorBorder(sColorBorder): sap.ui.vbm.Area
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.

Parameters:
{string}sColorBorder New value for property colorBorder
Returns:
{sap.ui.vbm.Area} Reference to this in order to allow method chaining
setPosition(sPosition): sap.ui.vbm.Area
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.

Parameters:
{string}sPosition New value for property position
Returns:
{sap.ui.vbm.Area} Reference to this in order to allow method chaining