org.apache.olingo.server.api.serializer

## Interface FixedFormatSerializer

-     public interface FixedFormatSerializer

  OData serializer for fixed output formats.

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `InputStream` | `asyncResponse(ODataResponse odataResponse)` Serializes a ODataResponse into an async response.
    `InputStream` | `batchResponse(List<ODataResponsePart> batchResponses, String boundary)` Serializes a batch response.
    `InputStream` | `binary(byte[] binary)` Writes binary output into an InputStream.
    `InputStream` | `count(Integer count)` Writes a count into an InputStream as plain text.
    `SerializerStreamResult` | `mediaEntityStreamed(EntityMediaObject mediaEntity)` Writes bytes to an Input stream
    `InputStream` | `primitiveValue(EdmPrimitiveType type, Object value, PrimitiveValueSerializerOptions options)` Writes the raw value of a primitive-type instance into an InputStream.

- - ### Method Detail

    - #### binary

          InputStream binary(byte[] binary)
                      throws SerializerException

      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

          InputStream count(Integer count)
                     throws SerializerException

      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 type
        `value` - the value
        `options` - options for the serializer
      Throws:
        `SerializerException`

    - #### batchResponse

          InputStream batchResponse(List<ODataResponsePart> batchResponses,
                                    String boundary)
                             throws BatchSerializerException

      Serializes a batch response.
      Parameters:
        `batchResponses` - the response parts
        `boundary` - the boundary between the parts
      Returns:
        response as an input stream
      Throws:
        `BatchSerializerException`

    - #### asyncResponse

          InputStream asyncResponse(ODataResponse odataResponse)
                             throws SerializerException

      Serializes a ODataResponse into an async response.
      Parameters:
        `odataResponse` - the response parts
      Returns:
        response as an input stream
      Throws:
        `SerializerException`

Copyright © 2013–2020 The Apache Software Foundation. All rights reserved.