Class ErrorEntityMessageBodyWriter

java.lang.Object
com.atlassian.crowd.plugin.rest.exception.mapper.ErrorEntityMessageBodyWriter
All Implemented Interfaces:
javax.ws.rs.ext.MessageBodyWriter<ErrorEntity>

@Provider @Produces({"text/plain; charset=utf-8","text/csv"}) public class ErrorEntityMessageBodyWriter extends Object implements javax.ws.rs.ext.MessageBodyWriter<ErrorEntity>
  • Constructor Details

    • ErrorEntityMessageBodyWriter

      public ErrorEntityMessageBodyWriter()
  • Method Details

    • isWriteable

      public boolean isWriteable(Class<?> aClass, Type type, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType)
      Specified by:
      isWriteable in interface javax.ws.rs.ext.MessageBodyWriter<ErrorEntity>
    • getSize

      public long getSize(@Nullable ErrorEntity errorEntity, Class<?> aClass, Type type, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType)
      Specified by:
      getSize in interface javax.ws.rs.ext.MessageBodyWriter<ErrorEntity>
    • writeTo

      public void writeTo(@Nullable ErrorEntity errorEntity, Class<?> aClass, Type type, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType, javax.ws.rs.core.MultivaluedMap<String,Object> multivaluedMap, OutputStream entityStream) throws IOException, javax.ws.rs.WebApplicationException
      Specified by:
      writeTo in interface javax.ws.rs.ext.MessageBodyWriter<ErrorEntity>
      Throws:
      IOException
      javax.ws.rs.WebApplicationException