Class sap.ui.core.mvc.JSViewModule: sap/ui/core/mvc/JSView

extends View

A View defined/constructed by JavaScript code.

Constructor Summary
new sap.ui.core.mvc.JSView(sId?, mSettings?)Constructor for a new mvc/JSView.
Field Summary
sap.ui.core.mvc.JSView.asyncSupportFlag for feature detection of asynchronous loading/rendering
Events borrowed from class sap.ui.core.Control
Method Summary
sap.ui.core.mvc.JSView.extend(sClassName, oClassInfo?, FNMetaImpl?)Creates a new subclass of class sap.ui.core.mvc.JSView with name sClassName and enriches it with the information contained in oClassInfo.
sap.ui.core.mvc.JSView.getMetadata()Returns a metadata object for class sap.ui.core.mvc.JSView.
createContent()A method to be implemented by JSViews, returning the View UI.
getAutoPrefixId()A method to be implemented by JSViews, returning the flag whether to prefix the IDs of controls automatically or not if the controls are created inside the sap.ui.core.mvc.JSView#createContent function.
Constructor Detail
new sap.ui.core.mvc.JSView(sId?, mSettings?)
Constructor for a new mvc/JSView.
Parameters:
{string}sId? id for the new control, generated automatically if no id is given
{object}mSettings? initial settings for the new control
Field Detail
sap.ui.core.mvc.JSView.asyncSupport
Flag for feature detection of asynchronous loading/rendering
Since:
1.30
Method Detail
sap.ui.core.mvc.JSView.extend(sClassName, oClassInfo?, FNMetaImpl?): function
Creates a new subclass of class sap.ui.core.mvc.JSView 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.mvc.View.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.core.mvc.JSView.getMetadata(): sap.ui.base.Metadata
Returns a metadata object for class sap.ui.core.mvc.JSView.
Returns:
{sap.ui.base.Metadata} Metadata object describing this class
createContent(): sap.ui.core.Control
A method to be implemented by JSViews, returning the View UI. While for declarative View types like XMLView or JSONView the user interface definition is declared in a separate file, JSViews programmatically construct the UI. This happens in the createContent method which every JSView needs to implement. The View implementation can construct the complete UI in this method - or only return the root control and create the rest of the UI lazily later on.
Returns:
{sap.ui.core.Control} a control or (typically) tree of controls representing the View user interface
getAutoPrefixId(): boolean
A method to be implemented by JSViews, returning the flag whether to prefix the IDs of controls automatically or not if the controls are created inside the sap.ui.core.mvc.JSView#createContent function. By default this feature is not activated.

You can overwrite this function and return true to activate the automatic prefixing.

Experimental API:Since 1.15.1. This feature might be changed in future.

Experimental:
Since 1.15.1. This feature might be changed in future.
Since:
1.15.1
Returns:
{boolean} true, if the controls IDs should be prefixed automatically