class sap.ui.vbm.Adapter

Control sample: sap.ui.vbm.Adapter
Visiblity: public
UX Guidelines:
Implements:
Available since: N/A
Module: sap/ui/vbm/Adapter
Application Component: CA-GTF-VBZ

Provides the ability to load VBI JSON into sap.ui.vbm.GeoMap control.


Constructor

Constructor for a new GeoMap Adapter.

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.Adapter(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 object


Associations

Name Cardinality Type Description
map 0..1 sap.ui.vbm.GeoMap

The GeoMap control associated with the Adapter. The adapter would invoke methods and subscribe to events on this GeoMap instance


Events Overview

Event Description
submit

The event is raised when a when the Adapter receives an event from GeoMap control. It is intended to unify the various GeoMap events as provided by VBI.

submit

The event is raised when a when the Adapter receives an event from GeoMap control. It is intended to unify the various GeoMap events as provided by VBI.

Param Type Description
oControlEvent sap.ui.base.Event
getSource sap.ui.base.EventProvider
getParameters object
data string

Methods Overview

Method Description
attachSubmit

Attaches event handler fnFunction to the submit event of this sap.ui.vbm.Adapter.

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.Adapter itself.

The event is raised when a when the Adapter receives an event from GeoMap control. It is intended to unify the various GeoMap events as provided by VBI.

detachSubmit

Detaches event handler fnFunction from the submit event of this sap.ui.vbm.Adapter.

The passed function and listener object must match the ones used for event registration.

sap.ui.vbm.Adapter.extend

Creates a new subclass of class sap.ui.vbm.Adapter 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.core.Element.extend.

fireSubmit

Fires event submit to attached listeners.

getMap

ID of the element which is the current target of the association map, or null.

sap.ui.vbm.Adapter.getMetadata

Returns a metadata object for class sap.ui.vbm.Adapter.

load

Parses and process sections of the VBI JSON and loads them into JSON Model bound to the GeoMap

setMap

Sets the associated map.

attachSubmit

Attaches event handler fnFunction to the submit event of this sap.ui.vbm.Adapter.

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.Adapter itself.

The event is raised when a when the Adapter receives an event from GeoMap control. It is intended to unify the various GeoMap events as provided by VBI.

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 sap.ui.vbm.Adapter itself

detachSubmit

Detaches event handler fnFunction from the submit event of this sap.ui.vbm.Adapter.

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

sap.ui.vbm.Adapter.extend

Creates a new subclass of class sap.ui.vbm.Adapter 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.core.Element.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

fireSubmit

Fires event submit to attached listeners.

Param Type DefaultValue Description
mParameters object

Parameters to pass along with the event

data string

getMap

ID of the element which is the current target of the association map, or null.

sap.ui.vbm.Adapter.getMetadata

Returns a metadata object for class sap.ui.vbm.Adapter.

load

Parses and process sections of the VBI JSON and loads them into JSON Model bound to the GeoMap

Param Type DefaultValue Description
data string object

VBI JSON to be loaded into the GeoMap control.

setMap

Sets the associated map.

Param Type DefaultValue Description
oMap sap.ui.core.ID sap.ui.vbm.GeoMap

ID of an element which becomes the new target of this map association; alternatively, an element instance may be given