Top Description Fields Constructors Methods
com.fasterxml.jackson.dataformat.ion.ionvalue

public Class IonValueMapper

extends IonObjectMapper
Class Inheritance
Imports
java.io.IOException, com.fasterxml.jackson.databind.ObjectMapper, .PropertyNamingStrategy, com.fasterxml.jackson.dataformat.ion.EnumAsIonSymbolModule, .IonFactory, .IonObjectMapper, com.amazon.ion.IonSystem, .IonValue, com.amazon.ion.system.IonSystemBuilder

Supports serializing Ion to POJO and back using the Jackson Ion framework. Direct serialization to and from IonValue fields is supported. The POJO can declare fields of type IonValue (or a subclass) and the direct value will be provided. Enums are serialized as symbols by default.

Field Summary

Modifier and TypeField and Description
private static final long

Constructor Summary

AccessConstructor and Description
public
IonValueMapper(IonSystem ionSystem)

Constructor which provides a mapper with a null PropertyNamingStrategy.

protected
IonValueMapper(IonValueMapper src)

Needed for `copy()`

protected
IonValueMapper(IonFactory f, PropertyNamingStrategy strategy)

Needed for some builders

public
IonValueMapper(IonSystem ionSystem, PropertyNamingStrategy
Strategy Jackson uses for mapping POJO field names to Json/Ion field names PropertyNamingStrategy
strategy
)

Constructor that provides an override on the default Constructor for the PropertyNamingStrategy.

Method Summary

Modifier and TypeMethod and Description
public static IonObjectMapper.Builder
builder()

Hides com.fasterxml.jackson.dataformat.ion.IonObjectMapper.builder.

A builder for a mapper that will use textual writers by default.

public static IonObjectMapper.Builder
builder(IonSystem ionSystem)

Hides com.fasterxml.jackson.dataformat.ion.IonObjectMapper.builder.

A builder for a mapper that will use textual writers by default and the provided IonSystem.

public static IonObjectMapper.Builder
builder(IonSystem ionSystem, PropertyNamingStrategy strategy)

Canonical builder() method that most other methods ultimately call.

public static IonObjectMapper.Builder
public static IonObjectMapper.Builder
builder(IonFactory streamFactory, PropertyNamingStrategy strategy)

public static IonObjectMapper.Builder
builderForBinaryWriters()

Hides com.fasterxml.jackson.dataformat.ion.IonObjectMapper.builderForBinaryWriters.

A builder for a mapper that will use binary writers by default.

public static IonObjectMapper.Builder
builderForBinaryWriters(IonSystem ionSystem)

Hides com.fasterxml.jackson.dataformat.ion.IonObjectMapper.builderForBinaryWriters.

A builder for a mapper that will use binary writers by default and the provided IonSystem

public static IonObjectMapper.Builder
builderForTextualWriters()

Hides com.fasterxml.jackson.dataformat.ion.IonObjectMapper.builderForTextualWriters.

A builder for a mapper that will use textual writers by default.

public static IonObjectMapper.Builder
builderForTextualWriters(IonSystem ionSystem)

Hides com.fasterxml.jackson.dataformat.ion.IonObjectMapper.builderForTextualWriters.

A builder for a mapper that will use textual writers by default and the provided IonSystem.

public ObjectMapper
copy()

Overrides com.fasterxml.jackson.dataformat.ion.IonObjectMapper.copy.

Method for creating a new ObjectMapper instance that has same initial configuration as this instance.

public <T> T
parse(IonValue value, Class<T> clazz)

public <T> IonValue
serialize(T o)

Inherited from com.fasterxml.jackson.dataformat.ion.IonObjectMapper:
configureconfigurecreateGeneratorcreateParsercreateParserdisabledisableenableenablegetFactoryreadValuereadValuereadValuereadValuereadValuereadValuesetCreateBinaryWritersversionwriteValuewriteValueAsIonValue

Field Detail

serialVersionUIDback to summary
private static final long serialVersionUID

Hides com.fasterxml.jackson.dataformat.ion.IonObjectMapper.serialVersionUID.

Constructor Detail

IonValueMapperback to summary
public IonValueMapper(IonSystem ionSystem)

Constructor which provides a mapper with a null PropertyNamingStrategy.

IonValueMapperback to summary
protected IonValueMapper(IonValueMapper src)

Needed for `copy()`

Since
2.18
IonValueMapperback to summary
protected IonValueMapper(IonFactory f, PropertyNamingStrategy strategy)

Needed for some builders

Since
2.18
IonValueMapperback to summary
public IonValueMapper(IonSystem ionSystem, PropertyNamingStrategy strategy)

Constructor that provides an override on the default Constructor for the PropertyNamingStrategy.

Parameters
strategy:PropertyNamingStrategy

Strategy Jackson uses for mapping POJO field names to Json/Ion field names PropertyNamingStrategy

Method Detail

builderback to summary
public static IonObjectMapper.Builder builder()

Hides com.fasterxml.jackson.dataformat.ion.IonObjectMapper.builder.

Doc from com.fasterxml.jackson.dataformat.ion.IonObjectMapper.builder.

A builder for a mapper that will use textual writers by default. Same as builderForTextualWriters().

builderback to summary
public static IonObjectMapper.Builder builder(IonSystem ionSystem)

Hides com.fasterxml.jackson.dataformat.ion.IonObjectMapper.builder.

Doc from com.fasterxml.jackson.dataformat.ion.IonObjectMapper.builder.

A builder for a mapper that will use textual writers by default and the provided IonSystem. Same as builderForTextualWriters(IonSystem).

builderback to summary
public static IonObjectMapper.Builder builder(IonSystem ionSystem, PropertyNamingStrategy strategy)

Canonical builder() method that most other methods ultimately call.

builderback to summary
public static IonObjectMapper.Builder builder(IonFactory streamFactory)

Hides com.fasterxml.jackson.dataformat.ion.IonObjectMapper.builder.

builderback to summary
public static IonObjectMapper.Builder builder(IonFactory streamFactory, PropertyNamingStrategy strategy)
builderForBinaryWritersback to summary
public static IonObjectMapper.Builder builderForBinaryWriters()

Hides com.fasterxml.jackson.dataformat.ion.IonObjectMapper.builderForBinaryWriters.

Doc from com.fasterxml.jackson.dataformat.ion.IonObjectMapper.builderForBinaryWriters.

A builder for a mapper that will use binary writers by default.

builderForBinaryWritersback to summary
public static IonObjectMapper.Builder builderForBinaryWriters(IonSystem ionSystem)

Hides com.fasterxml.jackson.dataformat.ion.IonObjectMapper.builderForBinaryWriters.

Doc from com.fasterxml.jackson.dataformat.ion.IonObjectMapper.builderForBinaryWriters.

A builder for a mapper that will use binary writers by default and the provided IonSystem

builderForTextualWritersback to summary
public static IonObjectMapper.Builder builderForTextualWriters()

Hides com.fasterxml.jackson.dataformat.ion.IonObjectMapper.builderForTextualWriters.

Doc from com.fasterxml.jackson.dataformat.ion.IonObjectMapper.builderForTextualWriters.

A builder for a mapper that will use textual writers by default.

builderForTextualWritersback to summary
public static IonObjectMapper.Builder builderForTextualWriters(IonSystem ionSystem)

Hides com.fasterxml.jackson.dataformat.ion.IonObjectMapper.builderForTextualWriters.

Doc from com.fasterxml.jackson.dataformat.ion.IonObjectMapper.builderForTextualWriters.

A builder for a mapper that will use textual writers by default and the provided IonSystem.

copyback to summary
public ObjectMapper copy()

Overrides com.fasterxml.jackson.dataformat.ion.IonObjectMapper.copy.

Doc from com.fasterxml.jackson.databind.ObjectMapper.copy.

Method for creating a new ObjectMapper instance that has same initial configuration as this instance. Note that this also requires making a copy of the underlying JsonFactory instance.

Method is typically used when multiple, differently configured mappers are needed. Although configuration is shared, cached serializers and deserializers are NOT shared, which means that the new instance may be re-configured before use; meaning that it behaves the same way as if an instance was constructed from scratch.

Annotations
@Override
parseback to summary
public <T> T parse(IonValue value, Class<T> clazz) throws IOException
serializeback to summary
public <T> IonValue serialize(T o) throws IOException