Package com.github.nylle.javafixture
Class SpecimenType<T>
- java.lang.Object
-
- com.github.nylle.javafixture.SpecimenType<T>
-
public class SpecimenType<T> extends Object
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedSpecimenType()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Class<T>asClass()ParameterizedTypeasParameterizedType()static Class<?>castToClass(Type type)booleanequals(Object o)static <T> SpecimenType<T>fromClass(Type typeReference)static <T> SpecimenType<T>fromRawType(Class<?> rawType, Type[] actualTypeArguments)Class<?>getComponentType()List<Constructor<T>>getDeclaredConstructors()T[]getEnumConstants()List<Method>getFactoryMethods()TypegetGenericTypeArgument(int index)Type[]getGenericTypeArguments()StringgetName()StringgetTypeParameterName(int index)String[]getTypeParameterNames()inthashCode()booleanisAbstract()booleanisArray()booleanisBoxed()booleanisCollection()booleanisEnum()booleanisInterface()booleanisMap()booleanisParameterized()static booleanisParameterized(Type type)booleanisPrimitive()booleanisTimeType()
-
-
-
Method Detail
-
fromClass
public static <T> SpecimenType<T> fromClass(Type typeReference)
-
fromRawType
public static <T> SpecimenType<T> fromRawType(Class<?> rawType, Type[] actualTypeArguments)
-
isParameterized
public static boolean isParameterized(Type type)
-
asParameterizedType
public ParameterizedType asParameterizedType()
-
getGenericTypeArguments
public Type[] getGenericTypeArguments()
-
getGenericTypeArgument
public Type getGenericTypeArgument(int index)
-
getTypeParameterNames
public String[] getTypeParameterNames()
-
getTypeParameterName
public String getTypeParameterName(int index)
-
getComponentType
public Class<?> getComponentType()
-
getEnumConstants
public T[] getEnumConstants()
-
getName
public String getName()
-
isParameterized
public boolean isParameterized()
-
isCollection
public boolean isCollection()
-
isMap
public boolean isMap()
-
isTimeType
public boolean isTimeType()
-
isPrimitive
public boolean isPrimitive()
-
isBoxed
public boolean isBoxed()
-
isEnum
public boolean isEnum()
-
isArray
public boolean isArray()
-
isInterface
public boolean isInterface()
-
isAbstract
public boolean isAbstract()
-
getDeclaredConstructors
public List<Constructor<T>> getDeclaredConstructors()
-
-