Interface FixedFormatSerializer
public interface FixedFormatSerializer
OData serializer for fixed output formats.
-
Method Summary
Modifier and TypeMethodDescriptionasyncResponse
(ODataResponse odataResponse) Serializes a ODataResponse into an async response.batchResponse
(List<ODataResponsePart> batchResponses, String boundary) Serializes a batch response.binary
(byte[] binary) Writes binary output into an InputStream.Writes a count into an InputStream as plain text.mediaEntityStreamed
(EntityMediaObject mediaEntity) Writes bytes to an Input streamprimitiveValue
(EdmPrimitiveType type, Object value, PrimitiveValueSerializerOptions options) Writes the raw value of a primitive-type instance into an InputStream.
-
Method Details
-
binary
Writes binary output into an InputStream.- Parameters:
binary
- the binary data- Throws:
SerializerException
-
mediaEntityStreamed
SerializerStreamResult mediaEntityStreamed(EntityMediaObject mediaEntity) throws SerializerException Writes bytes to an Input stream- Parameters:
mediaEntity
- bytes- Returns:
- Throws:
SerializerException
-
count
Writes a count into an InputStream as plain text.- Parameters:
count
- the count- Throws:
SerializerException
-
primitiveValue
InputStream primitiveValue(EdmPrimitiveType type, Object value, PrimitiveValueSerializerOptions options) throws SerializerException Writes the raw value of a primitive-type instance into an InputStream.- Parameters:
type
- the primitive typevalue
- the valueoptions
- options for the serializer- Throws:
SerializerException
-
batchResponse
InputStream batchResponse(List<ODataResponsePart> batchResponses, String boundary) throws BatchSerializerException Serializes a batch response.- Parameters:
batchResponses
- the response partsboundary
- the boundary between the parts- Returns:
- response as an input stream
- Throws:
BatchSerializerException
-
asyncResponse
Serializes a ODataResponse into an async response.- Parameters:
odataResponse
- the response parts- Returns:
- response as an input stream
- Throws:
SerializerException
-