|
Spring Data Commons | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.springframework.data.util.ArrayTypeDiscoverer
public class ArrayTypeDiscoverer
Special TypeDiscoverer
handling GenericArrayType
s.
Constructor Summary | |
---|---|
protected |
ArrayTypeDiscoverer(GenericArrayType type,
org.springframework.data.util.TypeDiscoverer parent)
|
Method Summary | |
---|---|
protected TypeInformation |
createInfo(Type fieldType)
Creates TypeInformation for the given Type . |
boolean |
equals(Object obj)
|
TypeInformation |
getComponentType()
Returns the component type for Collection s or the key type for Map s. |
TypeInformation |
getMapValueType()
Will return the type of the value in case the underlying type is a Map . |
TypeInformation |
getProperty(String fieldname)
Returns the property information for the property with the given name. |
Class<?> |
getType()
Returns the type of the property. |
int |
hashCode()
|
boolean |
isCollectionLike()
Returns whether the type can be considered a collection, which means it's a container of elements, e.g. a Collection and Array or anything implementing Iterable . |
boolean |
isMap()
Returns whether the property is a Map . |
protected Class<?> |
resolveType(Type type)
Resolves the given type into a plain Class . |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
protected ArrayTypeDiscoverer(GenericArrayType type, org.springframework.data.util.TypeDiscoverer parent)
type
- parent
- parent
- Method Detail |
---|
public Class<?> getType()
TypeInformation
getType
in interface TypeInformation
public TypeInformation getComponentType()
TypeInformation
Collection
s or the key type for Map
s.
getComponentType
in interface TypeInformation
protected TypeInformation createInfo(Type fieldType)
TypeInformation
for the given Type
.
fieldType
-
protected Class<?> resolveType(Type type)
Class
.
type
-
public TypeInformation getProperty(String fieldname)
TypeInformation
getProperty
in interface TypeInformation
public boolean isMap()
TypeInformation
Map
. If this returns true you can expect
TypeInformation.getComponentType()
as well as TypeInformation.getMapValueType()
to return something not null.
isMap
in interface TypeInformation
public TypeInformation getMapValueType()
TypeInformation
Map
.
getMapValueType
in interface TypeInformation
public boolean isCollectionLike()
TypeInformation
Collection
and Array
or anything implementing Iterable
. If this returns true you
can expect TypeInformation.getComponentType()
to return a non-null value.
isCollectionLike
in interface TypeInformation
public boolean equals(Object obj)
equals
in class Object
public int hashCode()
hashCode
in class Object
|
Spring Data Commons | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |