From e783ec00712b9842cbe01f5b6a9d5b0f307b4783 Mon Sep 17 00:00:00 2001 From: Michael Liedtke Date: Sun, 9 Jul 2017 14:30:26 +0100 Subject: [PATCH] Make IonValueModule public for use outside of IonValueMapper --- .../jackson/dataformat/ion/ionvalue/IonValueMapper.java | 4 ++-- .../jackson/dataformat/ion/ionvalue/IonValueModule.java | 8 ++++++-- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/ion/src/main/java/com/fasterxml/jackson/dataformat/ion/ionvalue/IonValueMapper.java b/ion/src/main/java/com/fasterxml/jackson/dataformat/ion/ionvalue/IonValueMapper.java index 6551b04b0..a5d4c24dc 100644 --- a/ion/src/main/java/com/fasterxml/jackson/dataformat/ion/ionvalue/IonValueMapper.java +++ b/ion/src/main/java/com/fasterxml/jackson/dataformat/ion/ionvalue/IonValueMapper.java @@ -27,8 +27,8 @@ /** * 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 subclassing IonValue and - * the direct value will be provided. + * 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. */ diff --git a/ion/src/main/java/com/fasterxml/jackson/dataformat/ion/ionvalue/IonValueModule.java b/ion/src/main/java/com/fasterxml/jackson/dataformat/ion/ionvalue/IonValueModule.java index 70e550d1f..a58ca80cc 100644 --- a/ion/src/main/java/com/fasterxml/jackson/dataformat/ion/ionvalue/IonValueModule.java +++ b/ion/src/main/java/com/fasterxml/jackson/dataformat/ion/ionvalue/IonValueModule.java @@ -19,11 +19,15 @@ import software.amazon.ion.Timestamp; -class IonValueModule extends SimpleModule { +/** + * A module which allows for the direct serialization to and from IonValue fields. The POJO can declare fields of type + * IonValue (or a subclass) and the direct value will be provided. + */ +public class IonValueModule extends SimpleModule { private static final long serialVersionUID = 1L; - IonValueModule() { + public IonValueModule() { super("IonValueModule", PackageVersion.VERSION); addSerializer(new TimestampSerializer()); addSerializer(new IonValueSerializer());