Class sap.ui.rta.RuntimeAuthoringModule: sap/ui/rta/RuntimeAuthoring


The runtime authoring allows to adapt the fields of a running application.

Experimental API:Since 1.30. This class is experimental and provides only limited functionality. Also the API might be changed in future.


Since: 1.30.
Constructor Summary
new sap.ui.rta.RuntimeAuthoring()Constructor for a new sap.ui.rta.RuntimeAuthoring class.
Event Summary
selectionChange(oControlEvent)Event fired when a DesignTime selection is changed
start(oControlEvent)Fired when the runtime authoring is started
stop(oControlEvent)Fired when the runtime authoring is stopped
undoRedoStackModified(oControlEvent)Fired when the undo/redo stack has changed, undo/redo buttons can be updated
Method Summary
sap.ui.rta.RuntimeAuthoring.extend(sClassName, oClassInfo?, FNMetaImpl?)Creates a new subclass of class sap.ui.rta.RuntimeAuthoring with name sClassName and enriches it with the information contained in oClassInfo.
sap.ui.rta.RuntimeAuthoring.getMetadata()Returns a metadata object for class sap.ui.rta.RuntimeAuthoring.
attachSelectionChange(oData?, fnFunction, oListener?)Attaches event handler fnFunction to the selectionChange event of this sap.ui.rta.RuntimeAuthoring.
attachStart(oData?, fnFunction, oListener?)Attaches event handler fnFunction to the start event of this sap.ui.rta.RuntimeAuthoring.
attachStop(oData?, fnFunction, oListener?)Attaches event handler fnFunction to the stop event of this sap.ui.rta.RuntimeAuthoring.
attachUndoRedoStackModified(oData?, fnFunction, oListener?)Attaches event handler fnFunction to the undoRedoStackModified event of this sap.ui.rta.RuntimeAuthoring.
closeToolBars()Close Toolbars
detachSelectionChange(fnFunction, oListener)Detaches event handler fnFunction from the selectionChange event of this sap.ui.rta.RuntimeAuthoring.
detachStart(fnFunction, oListener)Detaches event handler fnFunction from the start event of this sap.ui.rta.RuntimeAuthoring.
detachStop(fnFunction, oListener)Detaches event handler fnFunction from the stop event of this sap.ui.rta.RuntimeAuthoring.
detachUndoRedoStackModified(fnFunction, oListener)Detaches event handler fnFunction from the undoRedoStackModified event of this sap.ui.rta.RuntimeAuthoring.
exit()Exit Runtime Authoring - destroy all controls
fireSelectionChange(mArguments?)Fires event selectionChange to attached listeners.
fireStart(mArguments?)Fires event start to attached listeners.
fireStop(mArguments?)Fires event stop to attached listeners.
fireUndoRedoStackModified(mArguments?)Fires event undoRedoStackModified to attached listeners.
getCustomFieldUrl()Gets current value of property customFieldUrl.
getRootControl()ID of the element which is the current target of the association rootControl, or null.
getSelection()Returns a selection from the DesignTime
getShowCreateCustomField()Gets current value of property showCreateCustomField.
getShowSettingsDialog()Gets current value of property showSettingsDialog.
getShowToolbars()Gets current value of property showToolbars.
getShowWindowUnloadDialog()Gets current value of property showWindowUnloadDialog.
setCustomFieldUrl(sCustomFieldUrl)Sets a new value for property customFieldUrl.
setRootControl(oRootControl)Sets the associated rootControl.
setShowCreateCustomField(bShowCreateCustomField)Sets a new value for property showCreateCustomField.
setShowSettingsDialog(bShowSettingsDialog)Sets a new value for property showSettingsDialog.
setShowToolbars(bShowToolbars)Sets a new value for property showToolbars.
setShowWindowUnloadDialog(bShowWindowUnloadDialog)Sets a new value for property showWindowUnloadDialog.
start()Start Runtime Authoring
stop()Stop Runtime Authoring
Constructor Detail
new sap.ui.rta.RuntimeAuthoring()
Constructor for a new sap.ui.rta.RuntimeAuthoring class.

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
    • start : fnListenerFunction or [fnListenerFunction, oListenerObject] or [oData, fnListenerFunction, oListenerObject]
    • stop : fnListenerFunction or [fnListenerFunction, oListenerObject] or [oData, fnListenerFunction, oListenerObject]
    • selectionChange : fnListenerFunction or [fnListenerFunction, oListenerObject] or [oData, fnListenerFunction, oListenerObject]
    • undoRedoStackModified : fnListenerFunction or [fnListenerFunction, oListenerObject] or [oData, fnListenerFunction, oListenerObject]

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

Event Detail
selectionChange(oControlEvent)
Event fired when a DesignTime selection is changed
Parameters:
{sap.ui.base.Event}oControlEvent
{sap.ui.base.EventProvider}oControlEvent.getSource
{object}oControlEvent.getParameters
{sap.ui.dt.Overlay[]}oControlEvent.getParameters.selection
start(oControlEvent)
Fired when the runtime authoring is started
Parameters:
{sap.ui.base.Event}oControlEvent
{sap.ui.base.EventProvider}oControlEvent.getSource
{object}oControlEvent.getParameters
stop(oControlEvent)
Fired when the runtime authoring is stopped
Parameters:
{sap.ui.base.Event}oControlEvent
{sap.ui.base.EventProvider}oControlEvent.getSource
{object}oControlEvent.getParameters
undoRedoStackModified(oControlEvent)
Fired when the undo/redo stack has changed, undo/redo buttons can be updated
Parameters:
{sap.ui.base.Event}oControlEvent
{sap.ui.base.EventProvider}oControlEvent.getSource
{object}oControlEvent.getParameters
Method Detail
sap.ui.rta.RuntimeAuthoring.extend(sClassName, oClassInfo?, FNMetaImpl?): function
Creates a new subclass of class sap.ui.rta.RuntimeAuthoring 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.ManagedObject.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.rta.RuntimeAuthoring.getMetadata(): sap.ui.base.Metadata
Returns a metadata object for class sap.ui.rta.RuntimeAuthoring.
Returns:
{sap.ui.base.Metadata} Metadata object describing this class
attachSelectionChange(oData?, fnFunction, oListener?): sap.ui.rta.RuntimeAuthoring
Attaches event handler fnFunction to the selectionChange event of this sap.ui.rta.RuntimeAuthoring.

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.rta.RuntimeAuthoring itself.

Event fired when a DesignTime selection is changed

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.rta.RuntimeAuthoring itself
Returns:
{sap.ui.rta.RuntimeAuthoring} Reference to this in order to allow method chaining
attachStart(oData?, fnFunction, oListener?): sap.ui.rta.RuntimeAuthoring
Attaches event handler fnFunction to the start event of this sap.ui.rta.RuntimeAuthoring.

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.rta.RuntimeAuthoring itself.

Fired when the runtime authoring is started

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.rta.RuntimeAuthoring itself
Returns:
{sap.ui.rta.RuntimeAuthoring} Reference to this in order to allow method chaining
attachStop(oData?, fnFunction, oListener?): sap.ui.rta.RuntimeAuthoring
Attaches event handler fnFunction to the stop event of this sap.ui.rta.RuntimeAuthoring.

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.rta.RuntimeAuthoring itself.

Fired when the runtime authoring is stopped

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.rta.RuntimeAuthoring itself
Returns:
{sap.ui.rta.RuntimeAuthoring} Reference to this in order to allow method chaining
attachUndoRedoStackModified(oData?, fnFunction, oListener?): sap.ui.rta.RuntimeAuthoring
Attaches event handler fnFunction to the undoRedoStackModified event of this sap.ui.rta.RuntimeAuthoring.

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.rta.RuntimeAuthoring itself.

Fired when the undo/redo stack has changed, undo/redo buttons can be updated

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.rta.RuntimeAuthoring itself
Returns:
{sap.ui.rta.RuntimeAuthoring} Reference to this in order to allow method chaining
closeToolBars()
Close Toolbars
detachSelectionChange(fnFunction, oListener): sap.ui.rta.RuntimeAuthoring
Detaches event handler fnFunction from the selectionChange event of this sap.ui.rta.RuntimeAuthoring.

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.rta.RuntimeAuthoring} Reference to this in order to allow method chaining
detachStart(fnFunction, oListener): sap.ui.rta.RuntimeAuthoring
Detaches event handler fnFunction from the start event of this sap.ui.rta.RuntimeAuthoring.

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.rta.RuntimeAuthoring} Reference to this in order to allow method chaining
detachStop(fnFunction, oListener): sap.ui.rta.RuntimeAuthoring
Detaches event handler fnFunction from the stop event of this sap.ui.rta.RuntimeAuthoring.

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.rta.RuntimeAuthoring} Reference to this in order to allow method chaining
detachUndoRedoStackModified(fnFunction, oListener): sap.ui.rta.RuntimeAuthoring
Detaches event handler fnFunction from the undoRedoStackModified event of this sap.ui.rta.RuntimeAuthoring.

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.rta.RuntimeAuthoring} Reference to this in order to allow method chaining
exit()
Exit Runtime Authoring - destroy all controls
fireSelectionChange(mArguments?): sap.ui.rta.RuntimeAuthoring
Fires event selectionChange to attached listeners.

Expects the following event parameters:

  • selection of type sap.ui.dt.Overlay[]
Parameters:
{Map}mArguments? The arguments to pass along with the event
Returns:
{sap.ui.rta.RuntimeAuthoring} Reference to this in order to allow method chaining
fireStart(mArguments?): sap.ui.rta.RuntimeAuthoring
Fires event start to attached listeners.
Parameters:
{Map}mArguments? The arguments to pass along with the event
Returns:
{sap.ui.rta.RuntimeAuthoring} Reference to this in order to allow method chaining
fireStop(mArguments?): sap.ui.rta.RuntimeAuthoring
Fires event stop to attached listeners.
Parameters:
{Map}mArguments? The arguments to pass along with the event
Returns:
{sap.ui.rta.RuntimeAuthoring} Reference to this in order to allow method chaining
fireUndoRedoStackModified(mArguments?): sap.ui.rta.RuntimeAuthoring
Fires event undoRedoStackModified to attached listeners.
Parameters:
{Map}mArguments? The arguments to pass along with the event
Returns:
{sap.ui.rta.RuntimeAuthoring} Reference to this in order to allow method chaining
getCustomFieldUrl(): string
Gets current value of property customFieldUrl.

The URL which is called when the custom field dialog is opened

Returns:
{string} Value of property customFieldUrl
getRootControl(): sap.ui.core.Control
ID of the element which is the current target of the association rootControl, or null.
Returns:
{sap.ui.core.Control}
getSelection(): sap.ui.dt.Overlay[]
Returns a selection from the DesignTime
Returns:
{sap.ui.dt.Overlay[]} selected overlays
getShowCreateCustomField(): boolean
Gets current value of property showCreateCustomField.

Whether the create custom field button should be shown

Returns:
{boolean} Value of property showCreateCustomField
getShowSettingsDialog(): boolean
Gets current value of property showSettingsDialog.

Temporary property : whether to show a dialog for changing control's properties# should be removed after DTA will fully switch to a property panel

Default value is true.

Returns:
{boolean} Value of property showSettingsDialog
getShowToolbars(): boolean
Gets current value of property showToolbars.

Whether the create custom field button should be shown

Default value is true.

Returns:
{boolean} Value of property showToolbars
getShowWindowUnloadDialog(): boolean
Gets current value of property showWindowUnloadDialog.

Whether the window unload dialog should be shown

Default value is true.

Returns:
{boolean} Value of property showWindowUnloadDialog
setCustomFieldUrl(sCustomFieldUrl): sap.ui.rta.RuntimeAuthoring
Sets a new value for property customFieldUrl.

The URL which is called when the custom field dialog is opened

When called with a value of null or undefined, the default value of the property will be restored.

Parameters:
{string}sCustomFieldUrl New value for property customFieldUrl
Returns:
{sap.ui.rta.RuntimeAuthoring} Reference to this in order to allow method chaining
setRootControl(oRootControl): sap.ui.rta.RuntimeAuthoring
Sets the associated rootControl.
Parameters:
{sap.ui.core.Control}oRootControl Id of an element which becomes the new target of this rootControl association; alternatively, an element instance may be given
Returns:
{sap.ui.rta.RuntimeAuthoring} Reference to this in order to allow method chaining
setShowCreateCustomField(bShowCreateCustomField): sap.ui.rta.RuntimeAuthoring
Sets a new value for property showCreateCustomField.

Whether the create custom field button should be shown

When called with a value of null or undefined, the default value of the property will be restored.

Parameters:
{boolean}bShowCreateCustomField New value for property showCreateCustomField
Returns:
{sap.ui.rta.RuntimeAuthoring} Reference to this in order to allow method chaining
setShowSettingsDialog(bShowSettingsDialog): sap.ui.rta.RuntimeAuthoring
Sets a new value for property showSettingsDialog.

Temporary property : whether to show a dialog for changing control's properties# should be removed after DTA will fully switch to a property panel

When called with a value of null or undefined, the default value of the property will be restored.

Default value is true.

Parameters:
{boolean}bShowSettingsDialog New value for property showSettingsDialog
Returns:
{sap.ui.rta.RuntimeAuthoring} Reference to this in order to allow method chaining
setShowToolbars(bShowToolbars): sap.ui.rta.RuntimeAuthoring
Sets a new value for property showToolbars.

Whether the create custom field button should be shown

When called with a value of null or undefined, the default value of the property will be restored.

Default value is true.

Parameters:
{boolean}bShowToolbars New value for property showToolbars
Returns:
{sap.ui.rta.RuntimeAuthoring} Reference to this in order to allow method chaining
setShowWindowUnloadDialog(bShowWindowUnloadDialog): sap.ui.rta.RuntimeAuthoring
Sets a new value for property showWindowUnloadDialog.

Whether the window unload dialog should be shown

When called with a value of null or undefined, the default value of the property will be restored.

Default value is true.

Parameters:
{boolean}bShowWindowUnloadDialog New value for property showWindowUnloadDialog
Returns:
{sap.ui.rta.RuntimeAuthoring} Reference to this in order to allow method chaining
start()
Start Runtime Authoring
stop()
Stop Runtime Authoring