OData implementation of the sap.ui.core.message.MessageParser class. Parses message responses from the back end.
OData implementation of the sap.ui.core.message.MessageParser class. Parses message responses from the back end.
new sap.ui.model.odata.ODataMessageParser(sServiceUrl, oMetadata, bPersistTechnicalMessages)
Param | Type | Default Value | Description |
---|---|---|---|
sServiceUrl | string | Base URI of the service used for the calculation of message targets |
|
oMetadata | sap.ui.model.odata.ODataMetadata | The ODataMetadata object |
|
bPersistTechnicalMessages | boolean | Whether technical messages should always be treated as persistent, since 1.83.0 |
Method | Description |
---|---|
sap.ui.model.odata.ODataMessageParser.extend |
Creates a new subclass of class sap.ui.model.odata.ODataMessageParser with name
|
getHeaderField |
Returns the name of the header field that is used to parse the server messages |
sap.ui.model.odata.ODataMessageParser.getMetadata |
Returns a metadata object for class sap.ui.model.odata.ODataMessageParser. |
parse |
Parses the given response for messages, calculates the delta and fires the messageChange-event on the MessageProcessor if messages are found. Messages of responses to GET requests with status codes 204 or 424 are ignored. |
setHeaderField |
Sets the header field name that should be used for parsing the JSON messages |
Creates a new subclass of class sap.ui.model.odata.ODataMessageParser 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.message.MessageParser.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 |
Returns a metadata object for class sap.ui.model.odata.ODataMessageParser.
Parses the given response for messages, calculates the delta and fires the messageChange-event on the MessageProcessor if messages are found. Messages of responses to GET requests with status codes 204 or 424 are ignored.
Param | Type | DefaultValue | Description |
---|---|---|---|
oResponse | object |
The response from the server containing body and headers |
|
oRequest | object |
The original request that lead to this response |
|
mGetEntities | object |
A map with the keys of the entities requested from the back-end mapped to true |
|
mChangeEntities | object |
A map with the keys of the entities changed in the back-end mapped to true |
|
bMessageScopeSupported | boolean |
Whether the used OData service supports the message scope sap.ui.model.odata.MessageScope.BusinessObject |