abstract class sap.ui.app.MockServer

Control sample: sap.ui.app.MockServer
Visiblity: public
UX Guidelines:
Implements:
Available since: N/A
Module: sap/ui/app/MockServer
Application Component: CA-UI5-COR

Class to mock a server.


Constructor

Creates a mocked server. This helps to mock all or some backend calls, e.g. for OData/JSON Models or simple XHR calls, without changing the application code. This class can also be used for qunit tests.

new sap.ui.app.MockServer(sId?, mSettings?, oScope?)
Param Type Default Value Description
sId? string

id for the new server object; generated automatically if no non-empty id is given Note: this can be omitted, no matter whether mSettings will be given or not!

mSettings? object

optional map/JSON-object with initial property values, aggregated objects etc. for the new object

oScope? object

scope object for resolving string based type and formatter references in bindings