TypeResolverBuilder which produces TypeSerializers and TypeDeserializers that use
Ion type annotations to communicate type metadata. Jackson polymorphism, the Ion way.
This TypeResolverBuilder expects to be initialized with a functional TypeIdResolver, and will serialize
type information (and deserialize to something other than the default type) when it resolves the provided
JavaType to a non-null type identifier, and vice versa.
| Modifier and Type | Field and Description |
|---|---|
| private Class | |
| private TypeIdResolver | |
| private boolean | typeIdVisible
Whether type id should be exposed to deserializers or not |
| Access | Constructor and Description |
|---|---|
| public | |
| protected |
| defaultImpl | back to summary |
|---|---|
| private Class<?> defaultImpl | |
| typeIdResolver | back to summary |
|---|---|
| private TypeIdResolver typeIdResolver | |
| typeIdVisible | back to summary |
|---|---|
| private boolean typeIdVisible Whether type id should be exposed to deserializers or not | |
| IonAnnotationTypeResolverBuilder | back to summary |
|---|---|
| public IonAnnotationTypeResolverBuilder() | |
| IonAnnotationTypeResolverBuilder | back to summary |
|---|---|
| protected IonAnnotationTypeResolverBuilder(IonAnnotationTypeResolverBuilder base, Class<?> defaultImpl) | |
| buildTypeDeserializer | back to summary |
|---|---|
| public TypeDeserializer buildTypeDeserializer(DeserializationConfig config, JavaType baseType, Collection<NamedType> subtypes) Implements com. Creates a Jackson
| |
| buildTypeSerializer | back to summary |
|---|---|
| public TypeSerializer buildTypeSerializer(SerializationConfig config, JavaType baseType, Collection<NamedType> subtypes) Implements com. Creates a Jackson
| |
| defaultImpl | back to summary |
|---|---|
| public IonAnnotationTypeResolverBuilder defaultImpl(Class<?> di) Implements com. Doc from com. Method for specifying default implementation to use if type id is either not available, or cannot be resolved.
| |
| getDefaultImpl | back to summary |
|---|---|
| public Class Implements com. Doc from com. Accessor for currently configured default type; implementation class that may be used in case no valid type information is available during type resolution
| |
| inclusion | back to summary |
|---|---|
| public IonAnnotationTypeResolverBuilder inclusion(JsonTypeInfo. Implements com. Doc from com. Method for specifying mechanism to use for including type metadata
in JSON.
If not explicitly called, setting defaults to
| |
| init | back to summary |
|---|---|
| public IonAnnotationTypeResolverBuilder init(JsonTypeInfo. Implements com. Doc from com. Initialization method that is called right after constructing the builder instance.
| |
| typeIdVisibility | back to summary |
|---|---|
| public IonAnnotationTypeResolverBuilder typeIdVisibility(boolean isVisible) Implements com. Doc from com. Method for specifying whether type id should be visible to
| |
| typeProperty | back to summary |
|---|---|
| public IonAnnotationTypeResolverBuilder typeProperty(String propName) Implements com. Doc from com. Method for specifying name of property used for including type
information. Not used for all inclusion mechanisms;
usually only used with
If not explicitly called, name of property to use is based on
defaults for
| |
| withDefaultImpl | back to summary |
|---|---|
| public IonAnnotationTypeResolverBuilder withDefaultImpl(Class<?> newDefaultImpl) Overrides default com. Doc from com. "Mutant factory" method for creating a new instance with different default implementation.
| |
| withSettings | back to summary |
|---|---|
| public IonAnnotationTypeResolverBuilder withSettings(JsonTypeInfo. Overrides default com. Doc from com. Method for overriding type information.
| |