The main entry point for constructing VTM controls.
Constructor for a new Vtm. This constructor can be used to construct an instance of sap.ui.vtm.Vtm with a specific set of extensions. Alternatively sap.ui.vtm.createVtm can be used to create a sap.ui.vtm.Vtm instance with a default set of extensions.
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.vtm.Vtm(sId, mSettings)
Param | Type | Default Value | Description |
---|---|---|---|
sId | string | The id to use for the sap.ui.vtm.Vtm instance. |
|
mSettings | object | A set of settings for the sap.ui.vtm.Vtm instance (normally used to populate the |
Default Aggregation: extensions
Name | Cardinality | Type | Description |
---|---|---|---|
extensions (default) | 0..n | sap.ui.vtm.Extension |
The set of VTM extensions. Extensions are used to provide extensibility. Default behaviors are implemented as extensions that can be replaced. |
Event | Description |
---|---|
activePanelChanged |
Raised when the active panel has changed. |
initialized |
Raised when this sap.ui.vtm.Vtm instance and its extensions have been initialized. Applications should add event handlers after the sap.ui.vtm.Vtm instance has initialized so that the extensions can attach event handlers before the application attempts to attach event handlers to the same events. |
panelAdded |
Raised when a panel has been added. |
Raised when the active panel has changed.
Param | Type | Description |
---|---|---|
oControlEvent | sap.ui.base.Event | |
getSource | sap.ui.base.EventProvider | |
getParameters | object |
Raised when this sap.ui.vtm.Vtm instance and its extensions have been initialized.
Applications should add event handlers after the sap.ui.vtm.Vtm instance has initialized so that the extensions can attach event handlers before the application attempts to attach event handlers to the same events.
Param | Type | Description |
---|---|---|
oControlEvent | sap.ui.base.Event | |
getSource | sap.ui.base.EventProvider | |
getParameters | object |
Method | Description |
---|---|
addExtension |
Adds some extension to the aggregation extensions. |
attachActivePanelChanged |
Attaches event handler When called, the context of the event handler (its Raised when the active panel has changed. |
attachInitialized |
Attaches event handler When called, the context of the event handler (its Raised when this sap.ui.vtm.Vtm instance and its extensions have been initialized. Applications should add event handlers after the sap.ui.vtm.Vtm instance has initialized so that the extensions can attach event handlers before the application attempts to attach event handlers to the same events. |
attachPanelAdded |
Attaches event handler When called, the context of the event handler (its Raised when a panel has been added. |
createPanel |
Creates a VTM panel associated with this sap.ui.vtm.Vtm instance. |
destroyExtensions |
Destroys all the extensions in the aggregation extensions. |
detachActivePanelChanged |
Detaches event handler The passed function and listener object must match the ones used for event registration. |
detachInitialized |
Detaches event handler The passed function and listener object must match the ones used for event registration. |
detachPanelAdded |
Detaches event handler The passed function and listener object must match the ones used for event registration. |
sap.ui.vtm.Vtm.extend |
Creates a new subclass of class sap.ui.vtm.Vtm with name
|
fireActivePanelChanged |
Fires event activePanelChanged to attached listeners. |
fireInitialized |
Fires event initialized to attached listeners. |
firePanelAdded |
Fires event panelAdded to attached listeners. |
getActivePanel |
Gets the active panel. |
getAddDefaultExtensions |
Gets current value of property addDefaultExtensions. When true populates the |
getExtensionByInterface |
Gets the extension implementing a specified interface. Returns |
getExtensionByName |
Gets an extension with a specified class name. Returns |
getExtensions |
Gets content of aggregation extensions. The set of VTM extensions. Extensions are used to provide extensibility. Default behaviors are implemented as extensions that can be replaced. |
getExtensionsByInterface |
Gets the extensions implementing a specified interface. |
getExtensionsByName |
Gets the extensions with a specified class name. |
sap.ui.vtm.Vtm.getMetadata |
Returns a metadata object for class sap.ui.vtm.Vtm. |
getPanel |
Gets a panel given its id. Returns undefined if no match is found. |
getPanels |
Gets the set of created panels. Do not modify the returned array. |
getScene |
Gets the scene. |
indexOfExtension |
Checks for the provided |
insertExtension |
Inserts a extension into the aggregation extensions. |
removeAllExtensions |
Removes all the controls from the aggregation extensions. Additionally, it unregisters them from the hosting UIArea. |
removeExtension |
Removes a extension from the aggregation extensions. |
setActivePanel |
Sets the active panel. |
setAddDefaultExtensions |
Sets a new value for property addDefaultExtensions. When true populates the When called with a value of |
Adds some extension to the aggregation extensions.
Param | Type | DefaultValue | Description |
---|---|---|---|
oExtension | sap.ui.vtm.Extension |
The extension to add; if empty, nothing is inserted |
Attaches event handler fnFunction
to the activePanelChanged event of this sap.ui.vtm.Vtm
.
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.vtm.Vtm
itself.
Raised when the active panel has changed.
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 initialized event of this sap.ui.vtm.Vtm
.
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.vtm.Vtm
itself.
Raised when this sap.ui.vtm.Vtm instance and its extensions have been initialized.
Applications should add event handlers after the sap.ui.vtm.Vtm instance has initialized so that the extensions can attach event handlers before the application attempts to attach event handlers to the same events.
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 panelAdded event of this sap.ui.vtm.Vtm
.
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.vtm.Vtm
itself.
Raised when a panel has been added.
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 |
Creates a VTM panel associated with this sap.ui.vtm.Vtm instance.
Param | Type | DefaultValue | Description |
---|---|---|---|
sId | string |
The ID to pass to the panel constructor. |
|
mSettings | object |
The settings to pass to the panel constructor. |
Detaches event handler fnFunction
from the activePanelChanged event of this sap.ui.vtm.Vtm
.
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 initialized event of this sap.ui.vtm.Vtm
.
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 panelAdded event of this sap.ui.vtm.Vtm
.
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.vtm.Vtm 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 |
Fires event activePanelChanged to attached listeners.
Param | Type | DefaultValue | Description |
---|---|---|---|
mParameters | object |
Parameters to pass along with the event |
Fires event initialized to attached listeners.
Param | Type | DefaultValue | Description |
---|---|---|---|
mParameters | object |
Parameters to pass along with the event |
Fires event panelAdded to attached listeners.
Param | Type | DefaultValue | Description |
---|---|---|---|
mParameters | object |
Parameters to pass along with the event |
|
panel | sap.ui.vtm.Panel |
Gets current value of property addDefaultExtensions.
When true populates the extensions
aggregation with the default set of extensions in the default configuration.
Gets the extension implementing a specified interface.
Returns undefined
if there is not exactly one matching extension.
Param | Type | DefaultValue | Description |
---|---|---|---|
sInterfaceName | string |
The fully qualified name of the interface. |
Gets an extension with a specified class name.
Returns undefined
if there is not exactly one matching extension.
Param | Type | DefaultValue | Description |
---|---|---|---|
sExtensionName | string |
The fully qualified class name of the extension. |
Gets content of aggregation extensions.
The set of VTM extensions. Extensions are used to provide extensibility. Default behaviors are implemented as extensions that can be replaced.
Gets the extensions implementing a specified interface.
Param | Type | DefaultValue | Description |
---|---|---|---|
sInterfaceName | string |
The fully qualified name of the interface. |
Gets the extensions with a specified class name.
Param | Type | DefaultValue | Description |
---|---|---|---|
sExtensionName | string |
The fully qualified class name of the extension. |
Gets a panel given its id. Returns undefined if no match is found.
Param | Type | DefaultValue | Description |
---|---|---|---|
panelId | string |
The id of the panel to find. |
Checks for the provided sap.ui.vtm.Extension
in the aggregation extensions. and returns its index if found or -1 otherwise.
Param | Type | DefaultValue | Description |
---|---|---|---|
oExtension | sap.ui.vtm.Extension |
The extension whose index is looked for |
Inserts a extension into the aggregation extensions.
Param | Type | DefaultValue | Description |
---|---|---|---|
oExtension | sap.ui.vtm.Extension |
The extension to insert; if empty, nothing is inserted |
|
iIndex | int |
The |
Removes all the controls from the aggregation extensions.
Additionally, it unregisters them from the hosting UIArea.
Removes a extension from the aggregation extensions.
Param | Type | DefaultValue | Description |
---|---|---|---|
vExtension | int string sap.ui.vtm.Extension |
The extension to remove or its index or id |
Sets the active panel.
Param | Type | DefaultValue | Description |
---|---|---|---|
oActivePanel | sap.ui.vtm.Panel |
The active panel. |
Sets a new value for property addDefaultExtensions.
When true populates the extensions
aggregation with the default set of extensions in the default configuration.
When called with a value of null
or undefined
, the default value of the property will be restored.
Param | Type | DefaultValue | Description |
---|---|---|---|
bAddDefaultExtensions | boolean |
New value for property |