|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.fasterxml.jackson.core.type.ResolvedType com.fasterxml.jackson.databind.JavaType com.fasterxml.jackson.databind.type.TypeBase com.fasterxml.jackson.databind.type.SimpleType
public final class SimpleType
Simple types are defined as anything other than one of recognized container types (arrays, Collections, Maps). For our needs we need not know anything further, since we have no way of dealing with generic types other than Collections and Maps.
Field Summary | |
---|---|
protected String[] |
_typeNames
Names of generic type arguments for this type; will match values in _typeParameters |
protected JavaType[] |
_typeParameters
Generic type arguments for this type. |
Fields inherited from class com.fasterxml.jackson.databind.JavaType |
---|
_class, _hashCode, _typeHandler, _valueHandler |
Constructor Summary | |
---|---|
protected |
SimpleType(Class<?> cls)
|
protected |
SimpleType(Class<?> cls,
String[] typeNames,
JavaType[] typeParams,
Object valueHandler,
Object typeHandler)
|
Method Summary | |
---|---|
protected JavaType |
_narrow(Class<?> subclass)
|
protected String |
buildCanonicalName()
|
static SimpleType |
construct(Class<?> cls)
|
static SimpleType |
constructUnsafe(Class<?> raw)
Method used by core Jackson classes: NOT to be used by application code. |
JavaType |
containedType(int index)
|
int |
containedTypeCount()
|
String |
containedTypeName(int index)
|
boolean |
equals(Object o)
|
StringBuilder |
getErasedSignature(StringBuilder sb)
Method for accessing signature without generic type information, in form compatible with all versions of JVM, and specifically used for type descriptions when generating byte code. |
StringBuilder |
getGenericSignature(StringBuilder sb)
|
boolean |
isContainerType()
|
JavaType |
narrowContentsBy(Class<?> subclass)
|
String |
toString()
|
JavaType |
widenContentsBy(Class<?> subclass)
|
JavaType |
withContentTypeHandler(Object h)
"Copy method" that will construct a new instance that is identical to this instance, except that its content type will have specified type handler assigned. |
SimpleType |
withContentValueHandler(Object h)
"Copy method" that will construct a new instance that is identical to this instance, except that it will have specified content value handler assigned. |
SimpleType |
withTypeHandler(Object h)
"Copy method" that will construct a new instance that is identical to this instance, except that it will have specified type handler assigned. |
SimpleType |
withValueHandler(Object h)
"Copy method" that will construct a new instance that is identical to this instance, except that it will have specified value handler assigned. |
Methods inherited from class com.fasterxml.jackson.databind.type.TypeBase |
---|
_classSignature, getTypeHandler, getValueHandler, serialize, serializeWithType, toCanonical |
Methods inherited from class com.fasterxml.jackson.databind.JavaType |
---|
_assertSubclass, _widen, forcedNarrowBy, getContentType, getErasedSignature, getGenericSignature, getKeyType, getRawClass, hasGenericTypes, hashCode, hasRawClass, isAbstract, isArrayType, isCollectionLikeType, isConcrete, isEnumType, isFinal, isInterface, isMapLikeType, isPrimitive, isThrowable, narrowBy, widenBy |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected final JavaType[] _typeParameters
protected final String[] _typeNames
_typeParameters
Constructor Detail |
---|
protected SimpleType(Class<?> cls)
protected SimpleType(Class<?> cls, String[] typeNames, JavaType[] typeParams, Object valueHandler, Object typeHandler)
Method Detail |
---|
public static SimpleType constructUnsafe(Class<?> raw)
NOTE: public only because it is called by ObjectMapper
which is
not in same package
protected JavaType _narrow(Class<?> subclass)
_narrow
in class JavaType
public JavaType narrowContentsBy(Class<?> subclass)
narrowContentsBy
in class JavaType
public JavaType widenContentsBy(Class<?> subclass)
widenContentsBy
in class JavaType
public static SimpleType construct(Class<?> cls)
public SimpleType withTypeHandler(Object h)
JavaType
withTypeHandler
in class JavaType
public JavaType withContentTypeHandler(Object h)
JavaType
withContentTypeHandler
in class JavaType
public SimpleType withValueHandler(Object h)
JavaType
withValueHandler
in class JavaType
public SimpleType withContentValueHandler(Object h)
JavaType
withContentValueHandler
in class JavaType
protected String buildCanonicalName()
buildCanonicalName
in class TypeBase
public boolean isContainerType()
isContainerType
in class JavaType
public int containedTypeCount()
containedTypeCount
in class JavaType
public JavaType containedType(int index)
containedType
in class JavaType
public String containedTypeName(int index)
containedTypeName
in class JavaType
public StringBuilder getErasedSignature(StringBuilder sb)
JavaType
getErasedSignature
in class TypeBase
sb
- StringBuilder to append signature to
public StringBuilder getGenericSignature(StringBuilder sb)
getGenericSignature
in class TypeBase
sb
- StringBuilder to append signature to
public String toString()
toString
in class JavaType
public boolean equals(Object o)
equals
in class JavaType
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |