org.springframework.http.converter

Class ByteArrayHttpMessageConverter

  • All Implemented Interfaces:
    HttpMessageConverter<byte[]>


    public class ByteArrayHttpMessageConverter
    extends AbstractHttpMessageConverter<byte[]>
    Implementation of HttpMessageConverter that can read and write byte arrays.

    By default, this converter supports all media types (&#42;&#47;&#42;), and writes with a Content-Type of application/octet-stream. This can be overridden by setting the supportedMediaTypes property.

    Since:
    3.0
    Author:
    Arjen Poutsma, Juergen Hoeller