Package org.codehaus.jackson.map
Class MappingJsonFactory
- java.lang.Object
-
- org.codehaus.jackson.JsonFactory
-
- org.codehaus.jackson.map.MappingJsonFactory
-
- All Implemented Interfaces:
Versioned
public class MappingJsonFactory extends JsonFactory
Sub-class ofJsonFactory
that will create a properObjectCodec
to allow seamless conversions between Json content and Java objects (POJOs). The only addition to regularJsonFactory
currently is thatObjectMapper
is constructed and passed as the codec to use.
-
-
Field Summary
-
Fields inherited from class org.codehaus.jackson.JsonFactory
_characterEscapes, _generatorFeatures, _inputDecorator, _objectCodec, _outputDecorator, _parserFeatures, _recyclerRef, _rootByteSymbols, _rootCharSymbols, FORMAT_NAME_JSON
-
-
Constructor Summary
Constructors Constructor Description MappingJsonFactory()
MappingJsonFactory(ObjectMapper mapper)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ObjectMapper
getCodec()
We'll override the method to return more specific type; co-variance helps herejava.lang.String
getFormatName()
Sub-classes need to override this method (as of 1.8)MatchStrength
hasFormat(InputAccessor acc)
Sub-classes need to override this method (as of 1.8)-
Methods inherited from class org.codehaus.jackson.JsonFactory
_createContext, _createJsonGenerator, _createJsonParser, _createJsonParser, _createJsonParser, _createUTF8JsonGenerator, _createWriter, _getBufferRecycler, _optimizedStreamFromURL, configure, configure, createJsonGenerator, createJsonGenerator, createJsonGenerator, createJsonGenerator, createJsonParser, createJsonParser, createJsonParser, createJsonParser, createJsonParser, createJsonParser, createJsonParser, disable, disable, disableGeneratorFeature, disableParserFeature, enable, enable, enableGeneratorFeature, enableParserFeature, getCharacterEscapes, getInputDecorator, getOutputDecorator, hasJSONFormat, isEnabled, isEnabled, isGeneratorFeatureEnabled, isParserFeatureEnabled, setCharacterEscapes, setCodec, setGeneratorFeature, setInputDecorator, setOutputDecorator, setParserFeature, version
-
-
-
-
Constructor Detail
-
MappingJsonFactory
public MappingJsonFactory()
-
MappingJsonFactory
public MappingJsonFactory(ObjectMapper mapper)
-
-
Method Detail
-
getCodec
public final ObjectMapper getCodec()
We'll override the method to return more specific type; co-variance helps here- Overrides:
getCodec
in classJsonFactory
-
getFormatName
public java.lang.String getFormatName()
Sub-classes need to override this method (as of 1.8)- Overrides:
getFormatName
in classJsonFactory
-
hasFormat
public MatchStrength hasFormat(InputAccessor acc) throws java.io.IOException
Sub-classes need to override this method (as of 1.8)- Overrides:
hasFormat
in classJsonFactory
- Throws:
java.io.IOException
-
-