com.couchbase.client.deps.com.fasterxml.jackson.databind.jsontype.SubtypeResolver Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of core-io Show documentation
Show all versions of core-io Show documentation
The official Couchbase JVM Core IO Library
package com.couchbase.client.deps.com.fasterxml.jackson.databind.jsontype;
import java.util.Collection;
import com.couchbase.client.deps.com.fasterxml.jackson.databind.AnnotationIntrospector;
import com.couchbase.client.deps.com.fasterxml.jackson.databind.JavaType;
import com.couchbase.client.deps.com.fasterxml.jackson.databind.cfg.MapperConfig;
import com.couchbase.client.deps.com.fasterxml.jackson.databind.introspect.AnnotatedClass;
import com.couchbase.client.deps.com.fasterxml.jackson.databind.introspect.AnnotatedMember;
/**
* Helper object used for handling registration on resolving of super-types
* to sub-types.
*/
public abstract class SubtypeResolver
{
/**
* Method for registering specified subtypes (possibly including type
* names); for type entries without name, non-qualified class name
* as used as name (unless overridden by annotation).
*/
public abstract void registerSubtypes(NamedType... types);
public abstract void registerSubtypes(Class... classes);
/**
* Method for finding out all reachable subtypes for a property specified
* by given element (method or field)
*
* @param baseType Effective property base type to use; may differ from
* actual type of property; for structured types it is content (value) type and NOT
* structured type.
*
* @since 2.1
*/
public abstract Collection collectAndResolveSubtypes(AnnotatedMember property,
MapperConfig config, AnnotationIntrospector ai, JavaType baseType);
/**
* Method for finding out all reachable subtypes for given type.
*/
public abstract Collection collectAndResolveSubtypes(AnnotatedClass basetype,
MapperConfig config, AnnotationIntrospector ai);
}