|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.codehaus.jackson.jaxrs.MapperConfigurator
public class MapperConfigurator
Helper class used to encapsulate details of configuring an
ObjectMapper
instance to be used for data binding, as
well as accessing it.
Field Summary | |
---|---|
protected Annotations[] |
_defaultAnnotationsToUse
Annotations set to use by default; overridden by explicit call to setAnnotationsToUse(org.codehaus.jackson.jaxrs.Annotations[]) |
protected ObjectMapper |
_defaultMapper
If no mapper was specified when constructed, and no configuration calls are made, a default mapper is constructed. |
protected Class<? extends AnnotationIntrospector> |
_jaxbIntrospectorClass
To support optional dependency to Jackson-XC module (needed if and when JAXB annotations are used for configuration) |
protected ObjectMapper |
_mapper
Mapper provider was constructed with if any, or that was constructed due to a call to explicitly configure mapper. |
Constructor Summary | |
---|---|
MapperConfigurator(ObjectMapper mapper,
Annotations[] defAnnotations)
|
Method Summary | |
---|---|
protected AnnotationIntrospector |
_resolveIntrospector(Annotations ann)
|
protected AnnotationIntrospector |
_resolveIntrospectors(Annotations[] annotationsToUse)
|
protected void |
_setAnnotations(ObjectMapper mapper,
Annotations[] annotationsToUse)
|
void |
configure(DeserializationConfig.Feature f,
boolean state)
|
void |
configure(JsonGenerator.Feature f,
boolean state)
|
void |
configure(JsonParser.Feature f,
boolean state)
|
void |
configure(SerializationConfig.Feature f,
boolean state)
|
ObjectMapper |
getConfiguredMapper()
Method that locates, configures and returns ObjectMapper to use |
ObjectMapper |
getDefaultMapper()
|
protected ObjectMapper |
mapper()
Helper method that will ensure that there is a configurable non-default mapper (constructing an instance if one didn't yet exit), and return that mapper. |
void |
setAnnotationsToUse(Annotations[] annotationsToUse)
|
void |
setMapper(ObjectMapper m)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected ObjectMapper _mapper
protected ObjectMapper _defaultMapper
protected Annotations[] _defaultAnnotationsToUse
setAnnotationsToUse(org.codehaus.jackson.jaxrs.Annotations[])
protected Class<? extends AnnotationIntrospector> _jaxbIntrospectorClass
Constructor Detail |
---|
public MapperConfigurator(ObjectMapper mapper, Annotations[] defAnnotations)
Method Detail |
---|
public ObjectMapper getConfiguredMapper()
ObjectMapper
to use
public ObjectMapper getDefaultMapper()
public void setMapper(ObjectMapper m)
public void setAnnotationsToUse(Annotations[] annotationsToUse)
public void configure(DeserializationConfig.Feature f, boolean state)
public void configure(SerializationConfig.Feature f, boolean state)
public void configure(JsonParser.Feature f, boolean state)
public void configure(JsonGenerator.Feature f, boolean state)
protected ObjectMapper mapper()
protected void _setAnnotations(ObjectMapper mapper, Annotations[] annotationsToUse)
protected AnnotationIntrospector _resolveIntrospectors(Annotations[] annotationsToUse)
protected AnnotationIntrospector _resolveIntrospector(Annotations ann)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |