REST.Client.TCustomRESTResponse.JSONValue
Delphi
property JSONValue: TJsonValue read GetJSONValue;
C++
__property System::Json::TJSONValue* JSONValue = {read=GetJSONValue};
Properties
Type | Visibility | Source | Unit | Parent |
---|---|---|---|---|
property | public | REST.Client.pas REST.Client.hpp |
REST.Client | TCustomRESTResponse |
Description
Returns the response content string that was successfully parsed as a JSON value. Otherwise, it returns Nil
.
The response content depends on the RootElement value.
To clarify, consider the following example:
Suppose that the JSON format response string is "{response:{"name":"Smith", "phone":"1234", "orders":[{...}, {...}]}}". In that case, setting RootElement to "response" returns the whole customer object. But if RootElement is set to "response.orders", the JSONValue property will return the array of order objects.