Class ResteasyJackson2Provider

java.lang.Object
com.fasterxml.jackson.jakarta.rs.base.ProviderBase<com.fasterxml.jackson.jakarta.rs.json.JacksonJsonProvider,com.fasterxml.jackson.databind.ObjectMapper,com.fasterxml.jackson.jakarta.rs.json.JsonEndpointConfig,com.fasterxml.jackson.jakarta.rs.json.JsonMapperConfigurator>
com.fasterxml.jackson.jakarta.rs.json.JacksonJsonProvider
org.jboss.resteasy.plugins.providers.jackson.ResteasyJackson2Provider
All Implemented Interfaces:
com.fasterxml.jackson.core.Versioned, jakarta.ws.rs.ext.MessageBodyReader<Object>, jakarta.ws.rs.ext.MessageBodyWriter<Object>, AsyncBufferedMessageBodyWriter<Object>, AsyncMessageBodyWriter<Object>

@Provider @Consumes({"application/json","application/*+json","text/json"}) @Produces({"application/json","application/*+json","text/json"}) public class ResteasyJackson2Provider extends com.fasterxml.jackson.jakarta.rs.json.JacksonJsonProvider implements AsyncBufferedMessageBodyWriter<Object>
Only different from Jackson one is *+json in @Produces/@Consumes
Version:
$Revision: 1 $
Author:
Bill Burke
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected final ConcurrentHashMap<org.jboss.resteasy.plugins.providers.jackson.ResteasyJackson2Provider.ClassAnnotationKey,com.fasterxml.jackson.jakarta.rs.json.JsonEndpointConfig>
     
    protected final ConcurrentHashMap<org.jboss.resteasy.plugins.providers.jackson.ResteasyJackson2Provider.ClassAnnotationKey,com.fasterxml.jackson.jakarta.rs.json.JsonEndpointConfig>
     
    protected final ConcurrentHashMap<org.jboss.resteasy.plugins.providers.jackson.ResteasyJackson2Provider.ClassAnnotationKey,Boolean>
     

    Fields inherited from class com.fasterxml.jackson.jakarta.rs.json.JacksonJsonProvider

    _jsonpFunctionName, _providers, BASIC_ANNOTATIONS, MIME_JAVASCRIPT, MIME_JAVASCRIPT_MS

    Fields inherited from class com.fasterxml.jackson.jakarta.rs.base.ProviderBase

    _cfgCheckCanDeserialize, _cfgCheckCanSerialize, _cfgCustomUntouchables, _defaultReadView, _defaultWriteView, _jakartaRSFeatures, _mapperConfig, _unreadableClasses, _untouchables, _unwritableClasses, DEFAULT_UNREADABLES, DEFAULT_UNTOUCHABLES, DEFAULT_UNWRITABLES, HEADER_CONTENT_TYPE_OPTIONS, JAKARTA_RS_FEATURE_DEFAULTS
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected com.fasterxml.jackson.databind.ObjectMapper
    _locateMapperViaProvider(Class<?> type, jakarta.ws.rs.core.MediaType mediaType)
     
    boolean
    isReadable(Class<?> aClass, Type type, Annotation[] annotations, jakarta.ws.rs.core.MediaType mediaType)
     
    boolean
    isWriteable(Class<?> aClass, Type type, Annotation[] annotations, jakarta.ws.rs.core.MediaType mediaType)
     
    readFrom(Class<Object> type, Type genericType, Annotation[] annotations, jakarta.ws.rs.core.MediaType mediaType, jakarta.ws.rs.core.MultivaluedMap<String,String> httpHeaders, InputStream entityStream)
     
    void
    writeTo(Object value, Class<?> type, Type genericType, Annotation[] annotations, jakarta.ws.rs.core.MediaType mediaType, jakarta.ws.rs.core.MultivaluedMap<String,Object> httpHeaders, OutputStream entityStream)
     

    Methods inherited from class com.fasterxml.jackson.jakarta.rs.json.JacksonJsonProvider

    _configForReading, _configForWriting, hasMatchingMediaType, setJSONPFunctionName, version

    Methods inherited from class com.fasterxml.jackson.jakarta.rs.base.ProviderBase

    _addSuperTypes, _configForReading, _configForWriting, _containedIn, _createGenerator, _createNoContentException, _createParser, _endpointForReading, _endpointForWriting, _findCustomUntouchable, _isIgnorableForReading, _isIgnorableForWriting, _isSpecialReadable, _modifyHeaders, addUntouchable, checkCanDeserialize, checkCanSerialize, configure, configure, configure, configure, configure, disable, disable, disable, disable, disable, disable, enable, enable, enable, enable, enable, enable, findEncoding, findSuperTypes, findSuperTypes, getSize, hasMatchingMediaTypeForReading, hasMatchingMediaTypeForWriting, isEnabled, locateMapper, removeUntouchable, setAnnotationsToUse, setDefaultReadView, setDefaultView, setDefaultWriteView, setMapper

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface org.jboss.resteasy.core.messagebody.AsyncBufferedMessageBodyWriter

    asyncWriteTo

    Methods inherited from interface jakarta.ws.rs.ext.MessageBodyWriter

    getSize
  • Field Details

    • _readers

      protected final ConcurrentHashMap<org.jboss.resteasy.plugins.providers.jackson.ResteasyJackson2Provider.ClassAnnotationKey,com.fasterxml.jackson.jakarta.rs.json.JsonEndpointConfig> _readers
    • decorators

      protected final ConcurrentHashMap<org.jboss.resteasy.plugins.providers.jackson.ResteasyJackson2Provider.ClassAnnotationKey,Boolean> decorators
    • _writers

      protected final ConcurrentHashMap<org.jboss.resteasy.plugins.providers.jackson.ResteasyJackson2Provider.ClassAnnotationKey,com.fasterxml.jackson.jakarta.rs.json.JsonEndpointConfig> _writers
  • Constructor Details

    • ResteasyJackson2Provider

      public ResteasyJackson2Provider()
  • Method Details

    • isReadable

      public boolean isReadable(Class<?> aClass, Type type, Annotation[] annotations, jakarta.ws.rs.core.MediaType mediaType)
      Specified by:
      isReadable in interface jakarta.ws.rs.ext.MessageBodyReader<Object>
      Overrides:
      isReadable in class com.fasterxml.jackson.jakarta.rs.base.ProviderBase<com.fasterxml.jackson.jakarta.rs.json.JacksonJsonProvider,com.fasterxml.jackson.databind.ObjectMapper,com.fasterxml.jackson.jakarta.rs.json.JsonEndpointConfig,com.fasterxml.jackson.jakarta.rs.json.JsonMapperConfigurator>
    • isWriteable

      public boolean isWriteable(Class<?> aClass, Type type, Annotation[] annotations, jakarta.ws.rs.core.MediaType mediaType)
      Specified by:
      isWriteable in interface jakarta.ws.rs.ext.MessageBodyWriter<Object>
      Overrides:
      isWriteable in class com.fasterxml.jackson.jakarta.rs.base.ProviderBase<com.fasterxml.jackson.jakarta.rs.json.JacksonJsonProvider,com.fasterxml.jackson.databind.ObjectMapper,com.fasterxml.jackson.jakarta.rs.json.JsonEndpointConfig,com.fasterxml.jackson.jakarta.rs.json.JsonMapperConfigurator>
    • readFrom

      public Object readFrom(Class<Object> type, Type genericType, Annotation[] annotations, jakarta.ws.rs.core.MediaType mediaType, jakarta.ws.rs.core.MultivaluedMap<String,String> httpHeaders, InputStream entityStream) throws IOException
      Specified by:
      readFrom in interface jakarta.ws.rs.ext.MessageBodyReader<Object>
      Overrides:
      readFrom in class com.fasterxml.jackson.jakarta.rs.base.ProviderBase<com.fasterxml.jackson.jakarta.rs.json.JacksonJsonProvider,com.fasterxml.jackson.databind.ObjectMapper,com.fasterxml.jackson.jakarta.rs.json.JsonEndpointConfig,com.fasterxml.jackson.jakarta.rs.json.JsonMapperConfigurator>
      Throws:
      IOException
    • writeTo

      public void writeTo(Object value, Class<?> type, Type genericType, Annotation[] annotations, jakarta.ws.rs.core.MediaType mediaType, jakarta.ws.rs.core.MultivaluedMap<String,Object> httpHeaders, OutputStream entityStream) throws IOException
      Specified by:
      writeTo in interface jakarta.ws.rs.ext.MessageBodyWriter<Object>
      Overrides:
      writeTo in class com.fasterxml.jackson.jakarta.rs.base.ProviderBase<com.fasterxml.jackson.jakarta.rs.json.JacksonJsonProvider,com.fasterxml.jackson.databind.ObjectMapper,com.fasterxml.jackson.jakarta.rs.json.JsonEndpointConfig,com.fasterxml.jackson.jakarta.rs.json.JsonMapperConfigurator>
      Throws:
      IOException
    • _locateMapperViaProvider

      protected com.fasterxml.jackson.databind.ObjectMapper _locateMapperViaProvider(Class<?> type, jakarta.ws.rs.core.MediaType mediaType)
      Overrides:
      _locateMapperViaProvider in class com.fasterxml.jackson.jakarta.rs.json.JacksonJsonProvider