|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.qi4j.api.util.Classes
public final class Classes
Class-related utility methods
Constructor Summary | |
---|---|
Classes()
|
Method Summary | ||
---|---|---|
static Type |
actualTypeOf(Type type)
|
|
static Set<Class> |
classesOf(Type type)
|
|
static List<Constructor> |
constructorsOf(Class clazz)
|
|
static String |
denormalizeURIToClass(String uriPart)
|
|
static List<Field> |
fieldsOf(Class clazz)
|
|
static Set<Type> |
genericInterfacesOf(Type type)
Get all interfaces for the given type, including the provided type. |
|
static
|
getAnnotationOfTypeOrAnyOfSuperTypes(Class<?> type,
Class<AnnotationType> annotationClass)
|
|
static Class<?> |
getRawClass(Type genericType)
|
|
static String |
getSimpleGenericName(Type type)
|
|
static Set<Class> |
interfacesOf(Type type)
Get all interfaces for the given type, including the provided type. |
|
static Set<Class> |
interfacesWithMethods(Set<Class> interfaces)
|
|
static List<Method> |
methodsOf(Class clazz)
|
|
static String |
normalizeClassToURI(String className)
|
|
static Type |
resolveTypeVariable(TypeVariable name,
Class declaringClass,
Class topClass)
Given a type variable, find what it resolves to given the declaring class where type variable was found and a top class that extends the declaring class. |
|
static Class[] |
toClassArray(Set<Class> types)
|
|
static String |
toClassName(String uri)
Get class name from a URI |
|
static String |
toURI(Class clazz)
Get URI for a class. |
|
static String |
toURI(String className)
Get URI for a class name. |
|
static Set<Class> |
typesOf(Type type)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Classes()
Method Detail |
---|
public static Set<Class> interfacesOf(Type type)
type
- to extract interfaces from
public static Set<Type> genericInterfacesOf(Type type)
type
- to extract interfaces from
public static Set<Class> interfacesWithMethods(Set<Class> interfaces)
public static Set<Class> classesOf(Type type)
public static Set<Class> typesOf(Type type)
public static Class[] toClassArray(Set<Class> types)
public static Type actualTypeOf(Type type)
public static String getSimpleGenericName(Type type)
public static <AnnotationType extends Annotation> AnnotationType getAnnotationOfTypeOrAnyOfSuperTypes(Class<?> type, Class<AnnotationType> annotationClass)
public static Class<?> getRawClass(Type genericType)
public static List<Constructor> constructorsOf(Class clazz)
public static List<Method> methodsOf(Class clazz)
public static List<Field> fieldsOf(Class clazz)
public static Type resolveTypeVariable(TypeVariable name, Class declaringClass, Class topClass)
name
- declaringClass
- topClass
-
public static String toURI(Class clazz) throws NullPointerException
clazz
- class
NullPointerException
- if clazz is nullpublic static String toURI(String className) throws NullPointerException
className
- class name
NullPointerException
- if className is nullpublic static String toClassName(String uri) throws NullPointerException
uri
- URI
NullPointerException
- if uri is nullpublic static String normalizeClassToURI(String className)
public static String denormalizeURIToClass(String uriPart)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |