Class SmileMapper

  • All Implemented Interfaces:
    javax.ws.rs.ext.MessageBodyReader<Object>, javax.ws.rs.ext.MessageBodyWriter<Object>

    @Provider
    @Consumes("application/x-jackson-smile")
    @Produces("application/x-jackson-smile; qs=0.1")
    public class SmileMapper
    extends Object
    • Field Detail

      • log

        protected final Logger log
      • objectMapper

        protected final com.fasterxml.jackson.databind.ObjectMapper objectMapper
    • Constructor Detail

      • SmileMapper

        @Inject
        public SmileMapper​(com.fasterxml.jackson.databind.ObjectMapper objectMapper)
    • Method Detail

      • getReaderJsonFactory

        protected com.fasterxml.jackson.core.JsonFactory getReaderJsonFactory()
      • isReadable

        public boolean isReadable​(Class<?> type,
                                  Type genericType,
                                  Annotation[] annotations,
                                  javax.ws.rs.core.MediaType mediaType)
        Specified by:
        isReadable in interface javax.ws.rs.ext.MessageBodyReader<Object>
      • isWriteable

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

        public long getSize​(Object value,
                            Class<?> type,
                            Type genericType,
                            Annotation[] annotations,
                            javax.ws.rs.core.MediaType mediaType)
        Specified by:
        getSize in interface javax.ws.rs.ext.MessageBodyWriter<Object>