@Beta
public interface ODataRequestResultDeserializable
Modifier and Type | Method and Description |
---|---|
<T> T |
as(Class<T> objectType)
Converts ODataRequestResult into POJO.
|
<T> List<T> |
asList(Class<T> objectType)
Converts ODataRequestResult into list of POJOs.
|
List<Map<String,Object>> |
asListOfMaps()
Construct and get a list of key-value maps from the OData response.
|
Map<String,Object> |
asMap()
Construct and get a key-value map from the OData response.
|
long |
getInlineCount()
Get the count of elements in the result set.
|
void |
streamElements(Consumer<ResultElement> handler)
Run a consumer for fluent API type ResultElement to iterate over the OData response with a continuous data
stream.
|
@Nonnull <T> T as(@Nonnull Class<T> objectType)
T
- The generic type of POJOobjectType
- type of POJOODataResponseException
- When the HTTP status indicates an erroneous response.ODataDeserializationException
- When deserialization process failed for the OData response object.@Nonnull <T> List<T> asList(@Nonnull Class<T> objectType)
T
- Generic type of the POJOobjectType
- type of POJOODataResponseException
- When the HTTP status indicates an erroneous response.ODataDeserializationException
- When deserialization process failed for the OData response objects.void streamElements(@Nonnull Consumer<ResultElement> handler)
handler
- The consumer for generic ResultElement.ODataResponseException
- When the HTTP status indicates an erroneous response.ODataDeserializationException
- When deserialization process failed for the OData response objects.long getInlineCount()
ODataResponseException
- When the HTTP status indicates an erroneous response.@Nonnull Map<String,Object> asMap()
ODataResponseException
- When the HTTP status indicates an erroneous response.ODataDeserializationException
- When deserialization process failed for the OData response object.@Nonnull List<Map<String,Object>> asListOfMaps()
ODataResponseException
- When the HTTP status indicates an erroneous response.ODataDeserializationException
- When deserialization process failed for the OData response objects.Copyright © 2021 SAP SE. All rights reserved.