Top Description Fields Constructors Methods
com.fasterxml.jackson.dataformat.avro

public Class AvroFactory

extends JsonFactory
Class Inheritance
Known Direct Subclasses
com.fasterxml.jackson.dataformat.avro.apacheimpl.ApacheAvroFactory
Imports
java.io.*, java.net.URL, com.fasterxml.jackson.core.*, com.fasterxml.jackson.core.format.InputAccessor, .MatchStrength, com.fasterxml.jackson.core.io.IOContext, com.fasterxml.jackson.core.util.RecyclerPool, com.fasterxml.jackson.dataformat.avro.apacheimpl.ApacheCodecRecycler, .AvroRecyclerPools, com.fasterxml.jackson.dataformat.avro.deser.*

Default JsonFactory implementation for encoding/decoding Avro content, uses native Jackson encoder/decoder.
See Also
com.fasterxml.jackson.dataformat.avro.apacheimpl.ApacheAvroFactory

Field Summary

Modifier and TypeField and Description
protected int
protected int
protected RecyclerPool<ApacheCodecRecycler>
protected boolean
_useApacheLibDecoder

Flag that is set if Apache Avro lib's decoder is to be used for decoding; `false` to use Jackson native Avro decoder.

pack-priv static final int
DEFAULT_AVRO_GENERATOR_FEATURE_FLAGS

Bitfield (set of flags) of all generator features that are enabled by default.

pack-priv static final int
DEFAULT_AVRO_PARSER_FEATURE_FLAGS

Bitfield (set of flags) of all parser features that are enabled by default.

public static final String
private static final long
Inherited from com.fasterxml.jackson.core.JsonFactory:
_byteSymbolCanonicalizer_characterEscapes_errorReportConfiguration_factoryFeatures_generatorDecorators_generatorFeatures_inputDecorator_maximumNonEscapedChar_objectCodec_outputDecorator_parserFeatures_quoteChar_recyclerPool_rootCharSymbols_rootValueSeparator_streamReadConstraints_streamWriteConstraintsDEFAULT_FACTORY_FEATURE_FLAGSDEFAULT_GENERATOR_FEATURE_FLAGSDEFAULT_PARSER_FEATURE_FLAGSDEFAULT_QUOTE_CHARDEFAULT_ROOT_VALUE_SEPARATORFORMAT_NAME_JSON

Constructor Summary

AccessConstructor and Description
public
AvroFactory()

Default constructor used to create factory instances.

public
protected
protected
AvroFactory(AvroFactoryBuilder b)

Constructors used by AvroFactoryBuilder for instantiation.

Method Summary

Modifier and TypeMethod and Description
protected JsonGenerator
_createGenerator(Writer
Writer underlying writer to write generated content to
out
,
IOContext
I/O context to use
ctxt
)

Overrides com.fasterxml.jackson.core.JsonFactory._createGenerator.

Overridable factory method that actually instantiates desired generator.

protected AvroGenerator
protected AvroParser
_createParser(InputStream
InputStream to use for reading content to parse
in
,
IOContext
I/O context to use for parsing
ctxt
)

Overrides com.fasterxml.jackson.core.JsonFactory._createParser.

Overridable factory method that actually instantiates desired parser.

protected JsonParser
_createParser(Reader
Reader to use for reading content to parse
r
,
IOContext
I/O context to use for parsing
ctxt
)

Overrides com.fasterxml.jackson.core.JsonFactory._createParser.

Overridable factory method that actually instantiates parser using given Reader object for reading content.

protected JsonParser
_createParser(char[]
Buffer that contains content to parse
data
,
int
Offset to the first character of data to parse
offset
,
int
Number of characters within buffer to parse
len
,
IOContext
I/O context to use for parsing
ctxt
,
boolean
Whether input buffer is recycled by the factory
recyclable
)

Overrides com.fasterxml.jackson.core.JsonFactory._createParser.

Overridable factory method that actually instantiates parser using given char[] object for accessing content.

protected AvroParser
_createParser(byte[]
Buffer that contains content to parse
data
,
int
Offset to the first character of data to parse
offset
,
int
Number of characters within buffer to parse
len
,
IOContext
I/O context to use for parsing
ctxt
)

Overrides com.fasterxml.jackson.core.JsonFactory._createParser.

Overridable factory method that actually instantiates parser using given Reader object for reading content passed as raw byte array.

protected Writer
protected <T> T
protected <T> T
public static AvroFactoryBuilder
builder()

Hides com.fasterxml.jackson.core.JsonFactory.builder.

Main factory method to use for constructing a builder for creating AvroFactory instances with different configuration.

public static AvroFactoryBuilder
builderWithApacheDecoder()

Main factory method to use for constructing a builder for creating AvroFactory instances with different configuration, initialized to use Apache Avro library codec for decoding content (instead of Jackson native decoder).

public static AvroFactoryBuilder
builderWithNativeDecoder()

Main factory method to use for constructing a builder for creating AvroFactory instances with different configuration, initialized to use Jackson antive codec for decoding content (instead of Apache Avro library decoder).

public boolean
canHandleBinaryNatively()

Overrides com.fasterxml.jackson.core.JsonFactory.canHandleBinaryNatively.

Introspection method that higher-level functionality may call to see whether underlying data format can read and write binary data natively; that is, embeded it as-is without using encodings such as Base64.

public boolean
canUseSchema(FormatSchema
Schema instance to check
schema
)

Overrides com.fasterxml.jackson.core.JsonFactory.canUseSchema.

Method that can be used to quickly check whether given schema is something that parsers and/or generators constructed by this factory could use.

public final AvroFactory
configure(AvroParser.Feature f, boolean state)

Method for enabling or disabling specified parser feature (check AvroParser.Feature for list of features)

public final AvroFactory
configure(AvroGenerator.Feature f, boolean state)

Method for enabling or disabling specified generator feature (check AvroGenerator.Feature for list of features)

public AvroFactory
copy()

Overrides com.fasterxml.jackson.core.JsonFactory.copy.

Method for constructing a new JsonFactory that has the same settings as this instance, but is otherwise independent (i.e. nothing is actually shared, symbol tables are separate).

public AvroGenerator
createGenerator(OutputStream
OutputStream to use for writing JSON content
out
,
JsonEncoding
Character encoding to use
enc
)

Overrides com.fasterxml.jackson.core.JsonFactory.createGenerator.

Note

co-variant return type

public AvroGenerator
createGenerator(OutputStream out)

Overrides com.fasterxml.jackson.core.JsonFactory.createGenerator.

Since Avro format always uses UTF-8 internally, no encoding need to be passed to this method.

public AvroParser
createParser(File
File that contains JSON content to parse
f
)

Overrides com.fasterxml.jackson.core.JsonFactory.createParser.

Method for constructing JSON parser instance to parse contents of specified file.

public AvroParser
createParser(URL
URL pointing to resource that contains JSON content to parse
url
)

Overrides com.fasterxml.jackson.core.JsonFactory.createParser.

Method for constructing JSON parser instance to parse contents of resource reference by given URL.

public AvroParser
createParser(InputStream
InputStream to use for reading JSON content to parse
in
)

Overrides com.fasterxml.jackson.core.JsonFactory.createParser.

Method for constructing JSON parser instance to parse the contents accessed via specified input stream.

public AvroParser
createParser(byte[] data)

Overrides com.fasterxml.jackson.core.JsonFactory.createParser.

Method for constructing parser for parsing the contents of given byte array.

public AvroParser
createParser(byte[]
Buffer that contains data to parse
data
,
int
Offset of the first data byte within buffer
offset
,
int
Length of contents to parse within buffer
len
)

Overrides com.fasterxml.jackson.core.JsonFactory.createParser.

Method for constructing parser for parsing the contents of given byte array.

public AvroFactory
disable(AvroParser.Feature f)

Method for disabling specified parser features (check AvroParser.Feature for list of features)

public AvroFactory
disable(AvroGenerator.Feature f)

Method for disabling specified generator feature (check AvroGenerator.Feature for list of features)

public AvroFactory
enable(AvroParser.Feature f)

Method for enabling specified parser feature (check AvroParser.Feature for list of features)

public AvroFactory
enable(AvroGenerator.Feature f)

Method for enabling specified generator features (check AvroGenerator.Feature for list of features)

public int
public String
getFormatName()

Overrides com.fasterxml.jackson.core.JsonFactory.getFormatName.

Method that returns short textual id identifying format this factory supports.

public int
public MatchStrength
hasFormat(InputAccessor acc)

Overrides com.fasterxml.jackson.core.JsonFactory.hasFormat.

Sub-classes need to override this method

public final boolean
isEnabled(AvroParser.Feature f)

Checked whether specified parser feature is enabled.

public final boolean
isEnabled(AvroGenerator.Feature f)

Check whether specified generator feature is enabled.

protected Object
readResolve()

Overrides com.fasterxml.jackson.core.JsonFactory.readResolve.

Method that we need to override to actually make restoration go through constructors etc. Also: must be overridden by sub-classes as well.

public AvroFactoryBuilder
rebuild()

Overrides com.fasterxml.jackson.core.JsonFactory.rebuild.

Method that allows construction of differently configured factory, starting with settings of this factory.

public boolean
requiresPropertyOrdering()

Overrides com.fasterxml.jackson.core.JsonFactory.requiresPropertyOrdering.

Introspection method that higher-level functionality may call to see whether underlying data format requires a stable ordering of object properties or not.

public Version
version()

Overrides com.fasterxml.jackson.core.JsonFactory.version.

Implements com.fasterxml.jackson.core.Versioned.version.

Method called to detect version of the component that implements this interface; returned version should never be null, but may return specific "not available" instance (see Version for details).

Inherited from com.fasterxml.jackson.core.JsonFactory:
_checkInvalidCopy_copy_createContentReference_createContentReference_createContext_createContext_createNonBlockingContext_createParser_createUTF8Generator_decorate_decorate_decorate_decorate_decorate_decorate_getBufferRecycler_getRecyclerPoolcanParseAsynccanUseCharArraysconfigureconfigureconfigurecreateGeneratorcreateGeneratorcreateGeneratorcreateGeneratorcreateJsonGeneratorcreateJsonGeneratorcreateJsonGeneratorcreateJsonParsercreateJsonParsercreateJsonParsercreateJsonParsercreateJsonParsercreateJsonParsercreateJsonParsercreateNonBlockingByteArrayParsercreateNonBlockingByteBufferParsercreateParsercreateParsercreateParsercreateParsercreateParserdisabledisabledisableenableenableenablegetCharacterEscapesgetCodecgetFactoryFeaturesgetFormatReadFeatureTypegetFormatWriteFeatureTypegetGeneratorFeaturesgetInputDecoratorgetOutputDecoratorgetParserFeaturesgetRootValueSeparatorhasJSONFormatisEnabledisEnabledisEnabledisEnabledisEnabledrequiresCustomCodecsetCharacterEscapessetCodecsetErrorReportConfigurationsetInputDecoratorsetOutputDecoratorsetRecyclerPoolsetRootValueSeparatorsetStreamReadConstraintssetStreamWriteConstraintsstreamReadConstraintsstreamWriteConstraints

Field Detail

_avroGeneratorFeaturesback to summary
protected int _avroGeneratorFeatures
_avroParserFeaturesback to summary
protected int _avroParserFeatures
_avroRecyclerPoolback to summary
protected RecyclerPool<ApacheCodecRecycler> _avroRecyclerPool
Since
2.16
_useApacheLibDecoderback to summary
protected boolean _useApacheLibDecoder

Flag that is set if Apache Avro lib's decoder is to be used for decoding; `false` to use Jackson native Avro decoder.

Since
2.9
DEFAULT_AVRO_GENERATOR_FEATURE_FLAGSback to summary
pack-priv static final int DEFAULT_AVRO_GENERATOR_FEATURE_FLAGS

Bitfield (set of flags) of all generator features that are enabled by default.

DEFAULT_AVRO_PARSER_FEATURE_FLAGSback to summary
pack-priv static final int DEFAULT_AVRO_PARSER_FEATURE_FLAGS

Bitfield (set of flags) of all parser features that are enabled by default.

FORMAT_NAME_AVROback to summary
public static final String FORMAT_NAME_AVRO
serialVersionUIDback to summary
private static final long serialVersionUID

Hides com.fasterxml.jackson.core.JsonFactory.serialVersionUID.

Constructor Detail

AvroFactoryback to summary
public AvroFactory()

Default constructor used to create factory instances. Creation of a factory instance is a light-weight operation, but it is still a good idea to reuse limited number of factory instances (and quite often just a single instance): factories are used as context for storing some reused processing objects (such as symbol tables parsers use) and this reuse only works within context of a single factory instance.

AvroFactoryback to summary
public AvroFactory(ObjectCodec oc)
AvroFactoryback to summary
protected AvroFactory(AvroFactory src, ObjectCodec oc)
AvroFactoryback to summary
protected AvroFactory(AvroFactoryBuilder b)

Constructors used by AvroFactoryBuilder for instantiation.

Since
2.9

Method Detail

_createGeneratorback to summary
protected JsonGenerator _createGenerator(Writer out, IOContext ctxt) throws IOException

Overrides com.fasterxml.jackson.core.JsonFactory._createGenerator.

Overridable factory method that actually instantiates desired generator.

Parameters
out:Writer

Doc from com.fasterxml.jackson.core.JsonFactory._createGenerator.

Writer underlying writer to write generated content to

ctxt:IOContext

Doc from com.fasterxml.jackson.core.JsonFactory._createGenerator.

I/O context to use

Returns:JsonGenerator

Doc from com.fasterxml.jackson.core.JsonFactory._createGenerator.

This factory instance (to allow call chaining)

Annotations
@Override
Exceptions
IOException:

Doc from com.fasterxml.jackson.core.JsonFactory._createGenerator.

if parser initialization fails due to I/O (write) problem

_createGeneratorback to summary
protected AvroGenerator _createGenerator(OutputStream out, IOContext ctxt) throws IOException
_createParserback to summary
protected AvroParser _createParser(InputStream in, IOContext ctxt) throws IOException

Overrides com.fasterxml.jackson.core.JsonFactory._createParser.

Overridable factory method that actually instantiates desired parser.

Parameters
in:InputStream

Doc from com.fasterxml.jackson.core.JsonFactory._createParser.

InputStream to use for reading content to parse

ctxt:IOContext

Doc from com.fasterxml.jackson.core.JsonFactory._createParser.

I/O context to use for parsing

Returns:AvroParser

Doc from com.fasterxml.jackson.core.JsonFactory._createParser.

Parser constructed

Annotations
@Override
Exceptions
IOException:

Doc from com.fasterxml.jackson.core.JsonFactory._createParser.

if parser initialization fails due to I/O (read) problem

_createParserback to summary
protected JsonParser _createParser(Reader r, IOContext ctxt) throws IOException

Overrides com.fasterxml.jackson.core.JsonFactory._createParser.

Doc from com.fasterxml.jackson.core.JsonFactory._createParser.

Overridable factory method that actually instantiates parser using given Reader object for reading content.

This method is specifically designed to remain compatible between minor versions so that sub-classes can count on it being called as expected. That is, it is part of official interface from sub-class perspective, although not a public method available to users of factory implementations.

Parameters
r:Reader

Reader to use for reading content to parse

ctxt:IOContext

I/O context to use for parsing

Returns:JsonParser

Actual parser to use

Annotations
@Override
Exceptions
IOException:
if parser initialization fails due to I/O (read) problem
_createParserback to summary
protected JsonParser _createParser(char[] data, int offset, int len, IOContext ctxt, boolean recyclable) throws IOException

Overrides com.fasterxml.jackson.core.JsonFactory._createParser.

Doc from com.fasterxml.jackson.core.JsonFactory._createParser.

Overridable factory method that actually instantiates parser using given char[] object for accessing content.

Parameters
data:char[]

Buffer that contains content to parse

offset:int

Offset to the first character of data to parse

len:int

Number of characters within buffer to parse

ctxt:IOContext

I/O context to use for parsing

recyclable:boolean

Whether input buffer is recycled by the factory

Returns:JsonParser

Actual parser to use

Annotations
@Override
Exceptions
IOException:
if parser initialization fails due to I/O (read) problem
_createParserback to summary
protected AvroParser _createParser(byte[] data, int offset, int len, IOContext ctxt) throws IOException

Overrides com.fasterxml.jackson.core.JsonFactory._createParser.

Doc from com.fasterxml.jackson.core.JsonFactory._createParser.

Overridable factory method that actually instantiates parser using given Reader object for reading content passed as raw byte array.

This method is specifically designed to remain compatible between minor versions so that sub-classes can count on it being called as expected. That is, it is part of official interface from sub-class perspective, although not a public method available to users of factory implementations.

Parameters
data:byte[]

Buffer that contains content to parse

offset:int

Offset to the first character of data to parse

len:int

Number of characters within buffer to parse

ctxt:IOContext

I/O context to use for parsing

Returns:AvroParser

Actual parser to use

Annotations
@Override
Exceptions
IOException:
if parser initialization fails due to I/O (read) problem
_createWriterback to summary
protected Writer _createWriter(OutputStream out, JsonEncoding enc, IOContext ctxt) throws IOException

Overrides com.fasterxml.jackson.core.JsonFactory._createWriter.

Annotations
@Override
_nonByteSourceback to summary
protected <T> T _nonByteSource() throws IOException
_nonByteTargetback to summary
protected <T> T _nonByteTarget() throws IOException
builderback to summary
public static AvroFactoryBuilder builder()

Hides com.fasterxml.jackson.core.JsonFactory.builder.

Main factory method to use for constructing a builder for creating AvroFactory instances with different configuration. Builder is initialized to defaults and this is equivalent to calling builderWithNativeDecoder.

Returns:AvroFactoryBuilder

Doc from com.fasterxml.jackson.core.JsonFactory.builder.

Builder instance to use

builderWithApacheDecoderback to summary
public static AvroFactoryBuilder builderWithApacheDecoder()

Main factory method to use for constructing a builder for creating AvroFactory instances with different configuration, initialized to use Apache Avro library codec for decoding content (instead of Jackson native decoder).

builderWithNativeDecoderback to summary
public static AvroFactoryBuilder builderWithNativeDecoder()

Main factory method to use for constructing a builder for creating AvroFactory instances with different configuration, initialized to use Jackson antive codec for decoding content (instead of Apache Avro library decoder).

canHandleBinaryNativelyback to summary
public boolean canHandleBinaryNatively()

Overrides com.fasterxml.jackson.core.JsonFactory.canHandleBinaryNatively.

Doc from com.fasterxml.jackson.core.JsonFactory.canHandleBinaryNatively.

Introspection method that higher-level functionality may call to see whether underlying data format can read and write binary data natively; that is, embeded it as-is without using encodings such as Base64.

Default implementation returns false as JSON does not support native access: all binary content must use Base64 encoding. Most binary formats (like Smile and Avro) support native binary content.

Returns:boolean

Whether format supported by this factory supports native binary content

Annotations
@Override
canUseSchemaback to summary
public boolean canUseSchema(FormatSchema schema)

Overrides com.fasterxml.jackson.core.JsonFactory.canUseSchema.

Doc from com.fasterxml.jackson.core.JsonFactory.canUseSchema.

Method that can be used to quickly check whether given schema is something that parsers and/or generators constructed by this factory could use. Note that this means possible use, at the level of data format (i.e. schema is for same data format as parsers and generators this factory constructs); individual schema instances may have further usage restrictions.

Parameters
schema:FormatSchema

Schema instance to check

Returns:boolean

Whether parsers and generators constructed by this factory can use specified format schema instance

Annotations
@Override
configureback to summary
public final AvroFactory configure(AvroParser.Feature f, boolean state)

Method for enabling or disabling specified parser feature (check AvroParser.Feature for list of features)

configureback to summary
public final AvroFactory configure(AvroGenerator.Feature f, boolean state)

Method for enabling or disabling specified generator feature (check AvroGenerator.Feature for list of features)

copyback to summary
public AvroFactory copy()

Overrides com.fasterxml.jackson.core.JsonFactory.copy.

Doc from com.fasterxml.jackson.core.JsonFactory.copy.

Method for constructing a new JsonFactory that has the same settings as this instance, but is otherwise independent (i.e. nothing is actually shared, symbol tables are separate). Note that ObjectCodec reference is not copied but is set to null; caller typically needs to set it after calling this method. Reason for this is that the codec is used for callbacks, and assumption is that there is strict 1-to-1 mapping between codec, factory. Caller has to, then, explicitly set codec after making the copy.

Returns:AvroFactory

Copy of this factory instance

Annotations
@Override
createGeneratorback to summary
public AvroGenerator createGenerator(OutputStream out, JsonEncoding enc) throws IOException

Overrides com.fasterxml.jackson.core.JsonFactory.createGenerator.

Note

co-variant return type

Parameters
out:OutputStream

Doc from com.fasterxml.jackson.core.JsonFactory.createGenerator.

OutputStream to use for writing JSON content

enc:JsonEncoding

Doc from com.fasterxml.jackson.core.JsonFactory.createGenerator.

Character encoding to use

Annotations
@Override
createGeneratorback to summary
public AvroGenerator createGenerator(OutputStream out) throws IOException

Overrides com.fasterxml.jackson.core.JsonFactory.createGenerator.

Since Avro format always uses UTF-8 internally, no encoding need to be passed to this method.

Annotations
@Override
createParserback to summary
public AvroParser createParser(File f) throws IOException

Overrides com.fasterxml.jackson.core.JsonFactory.createParser.

Doc from com.fasterxml.jackson.core.JsonFactory.createParser.

Method for constructing JSON parser instance to parse contents of specified file.

Encoding is auto-detected from contents according to JSON specification recommended mechanism. Json specification supports only UTF-8, UTF-16 and UTF-32 as valid encodings, so auto-detection implemented only for this charsets. For other charsets use createParser(java.io.Reader).

Underlying input stream (needed for reading contents) will be owned (and managed, i.e. closed as need be) by the parser, since caller has no access to it.

Parameters
f:File

File that contains JSON content to parse

Annotations
@SuppressWarnings:resource
@Override
createParserback to summary
public AvroParser createParser(URL url) throws IOException

Overrides com.fasterxml.jackson.core.JsonFactory.createParser.

Doc from com.fasterxml.jackson.core.JsonFactory.createParser.

Method for constructing JSON parser instance to parse contents of resource reference by given URL.

Encoding is auto-detected from contents according to JSON specification recommended mechanism. Json specification supports only UTF-8, UTF-16 and UTF-32 as valid encodings, so auto-detection implemented only for this charsets. For other charsets use createParser(java.io.Reader).

Underlying input stream (needed for reading contents) will be owned (and managed, i.e. closed as need be) by the parser, since caller has no access to it.

Parameters
url:URL

URL pointing to resource that contains JSON content to parse

Annotations
@Override
createParserback to summary
public AvroParser createParser(InputStream in) throws IOException

Overrides com.fasterxml.jackson.core.JsonFactory.createParser.

Doc from com.fasterxml.jackson.core.JsonFactory.createParser.

Method for constructing JSON parser instance to parse the contents accessed via specified input stream.

The input stream will not be owned by the parser, it will still be managed (i.e. closed if end-of-stream is reacher, or parser close method called) if (and only if) com.fasterxml.jackson.core.StreamReadFeature#AUTO_CLOSE_SOURCE is enabled.

Note

no encoding argument is taken since it can always be auto-detected as suggested by JSON RFC. Json specification supports only UTF-8, UTF-16 and UTF-32 as valid encodings, so auto-detection implemented only for this charsets. For other charsets use createParser(java.io.Reader).

Parameters
in:InputStream

InputStream to use for reading JSON content to parse

Annotations
@Override
createParserback to summary
public AvroParser createParser(byte[] data) throws IOException

Overrides com.fasterxml.jackson.core.JsonFactory.createParser.

Doc from com.fasterxml.jackson.core.JsonFactory.createParser.

Method for constructing parser for parsing the contents of given byte array.

Annotations
@Override
createParserback to summary
public AvroParser createParser(byte[] data, int offset, int len) throws IOException

Overrides com.fasterxml.jackson.core.JsonFactory.createParser.

Doc from com.fasterxml.jackson.core.JsonFactory.createParser.

Method for constructing parser for parsing the contents of given byte array.

Parameters
data:byte[]

Buffer that contains data to parse

offset:int

Offset of the first data byte within buffer

len:int

Length of contents to parse within buffer

Annotations
@SuppressWarnings:resource
@Override
disableback to summary
public AvroFactory disable(AvroParser.Feature f)

Method for disabling specified parser features (check AvroParser.Feature for list of features)

disableback to summary
public AvroFactory disable(AvroGenerator.Feature f)

Method for disabling specified generator feature (check AvroGenerator.Feature for list of features)

enableback to summary
public AvroFactory enable(AvroParser.Feature f)

Method for enabling specified parser feature (check AvroParser.Feature for list of features)

enableback to summary
public AvroFactory enable(AvroGenerator.Feature f)

Method for enabling specified generator features (check AvroGenerator.Feature for list of features)

getFormatGeneratorFeaturesback to summary
public int getFormatGeneratorFeatures()

Overrides com.fasterxml.jackson.core.JsonFactory.getFormatGeneratorFeatures.

Annotations
@Override
getFormatNameback to summary
public String getFormatName()

Overrides com.fasterxml.jackson.core.JsonFactory.getFormatName.

Doc from com.fasterxml.jackson.core.JsonFactory.getFormatName.

Method that returns short textual id identifying format this factory supports.

Note

sub-classes should override this method; default implementation will return null for all sub-classes

Returns:String

Name of the format handled by parsers, generators this factory creates

Annotations
@Override
getFormatParserFeaturesback to summary
public int getFormatParserFeatures()

Overrides com.fasterxml.jackson.core.JsonFactory.getFormatParserFeatures.

Annotations
@Override
hasFormatback to summary
public MatchStrength hasFormat(InputAccessor acc) throws IOException

Overrides com.fasterxml.jackson.core.JsonFactory.hasFormat.

Sub-classes need to override this method

Annotations
@Override
isEnabledback to summary
public final boolean isEnabled(AvroParser.Feature f)

Checked whether specified parser feature is enabled.

isEnabledback to summary
public final boolean isEnabled(AvroGenerator.Feature f)

Check whether specified generator feature is enabled.

readResolveback to summary
protected Object readResolve()

Overrides com.fasterxml.jackson.core.JsonFactory.readResolve.

Method that we need to override to actually make restoration go through constructors etc. Also: must be overridden by sub-classes as well.

Returns:Object

Doc from com.fasterxml.jackson.core.JsonFactory.readResolve.

Newly constructed instance

Annotations
@Override
rebuildback to summary
public AvroFactoryBuilder rebuild()

Overrides com.fasterxml.jackson.core.JsonFactory.rebuild.

Doc from com.fasterxml.jackson.core.JsonFactory.rebuild.

Method that allows construction of differently configured factory, starting with settings of this factory.

Returns:AvroFactoryBuilder

Builder instance to use

Annotations
@Override
requiresPropertyOrderingback to summary
public boolean requiresPropertyOrdering()

Overrides com.fasterxml.jackson.core.JsonFactory.requiresPropertyOrdering.

Doc from com.fasterxml.jackson.core.JsonFactory.requiresPropertyOrdering.

Introspection method that higher-level functionality may call to see whether underlying data format requires a stable ordering of object properties or not. This is usually used for determining whether to force a stable ordering (like alphabetic ordering by name) if no ordering if explicitly specified.

Default implementation returns false as JSON does NOT require stable ordering. Formats that require ordering include positional textual formats like CSV, and schema-based binary formats like Avro.

Returns:boolean

Whether format supported by this factory requires Object properties to be ordered.

Annotations
@Override
versionback to summary
public Version version()

Overrides com.fasterxml.jackson.core.JsonFactory.version.

Implements com.fasterxml.jackson.core.Versioned.version.

Doc from com.fasterxml.jackson.core.Versioned.version.

Method called to detect version of the component that implements this interface; returned version should never be null, but may return specific "not available" instance (see Version for details).

Returns:Version

Version of the component

Annotations
@Override