Interface XClass
- All Superinterfaces:
XElement
- All Known Implementing Classes:
MirrorTypeFactory.MirrorArray,MirrorTypeFactory.MirrorClass,MirrorTypeFactory.MirrorPrimitiveType,ReflectionTypeFactory.ReflectionClass
- Since:
- 4.3
-
Method Summary
Modifier and TypeMethodDescriptionClass<?> asClass()Deprecated.Array component type, for arrays only.getDeclaredConstructor(XClass... argTypes) Iterable<? extends XConstructor> getEnumConstant(String name) Iterable<? extends XEnumConstant> Enum constants, for enums only.String[]Gets the actual type params of an interface implemented directly by this class or all its supers.XClass[]Directly implemented interfaces.default booleanbooleanisArray()default booleanisAssignableTo(Class<?> c) Should only be used with class literals.booleanbooleanisEnum()default booleanbooleanisLocal()Is it a local or anonymous class?booleandefault booleanisRecord()Methods inherited from interface org.infinispan.protostream.annotations.impl.types.XElement
getAnnotation, getAnnotationsByType, getDocumentation, getModifiers, getName, getTypeArgument, isFinal, isPrivate, isPublic, isStatic
-
Method Details
-
getFactory
XTypeFactory getFactory() -
asClass
Deprecated.This is the only place we can get back the java.lang.Class object and should be used very sparingly. Some implementations can throwUnsupportedOperationException.- Throws:
UnsupportedOperationException
-
getSimpleName
String getSimpleName() -
getCanonicalName
String getCanonicalName() -
getPackageName
String getPackageName() -
isPrimitive
boolean isPrimitive() -
isEnum
boolean isEnum() -
getEnumConstants
Iterable<? extends XEnumConstant> getEnumConstants()Enum constants, for enums only. -
getEnumConstant
-
isArray
boolean isArray() -
getComponentType
XClass getComponentType()Array component type, for arrays only. -
getEnclosingClass
XClass getEnclosingClass() -
getSuperclass
XClass getSuperclass() -
getInterfaces
XClass[] getInterfaces()Directly implemented interfaces. -
getGenericInterfaceParameterTypes
Gets the actual type params of an interface implemented directly by this class or all its supers. -
isAssignableTo
-
isAssignableTo
Should only be used with class literals. Any other type of usage should be considered suspect. -
getDeclaredConstructor
-
getDeclaredConstructors
Iterable<? extends XConstructor> getDeclaredConstructors() -
getDeclaredMethods
-
getMethod
-
getDeclaredFields
-
isLocal
boolean isLocal()Is it a local or anonymous class? -
isAbstract
default boolean isAbstract() -
isInterface
default boolean isInterface() -
isRecord
default boolean isRecord()
-