Class ByteArrayResponseConverterFunction

java.lang.Object
com.linecorp.armeria.server.annotation.ByteArrayResponseConverterFunction
All Implemented Interfaces:
ResponseConverterFunction

public final class ByteArrayResponseConverterFunction
extends Object
implements ResponseConverterFunction
A ResponseConverterFunction which creates an HttpResponse when:
  • the result is an instance of HttpData or byte[]
  • the result is an instance of Publisher or Stream while the "content-type" of the ResponseHeaders is "application/binary" or "application/octet-stream"
Note that this ResponseConverterFunction is applied to an annotated service by default, so you don't have to specify this converter explicitly.