Class MirrorTypeFactory.MirrorPrimitiveType
java.lang.Object
org.infinispan.protostream.annotations.impl.processor.types.MirrorTypeFactory.MirrorPrimitiveType
- All Implemented Interfaces:
HasModelElement, XClass, XElement
- Enclosing class:
MirrorTypeFactory
private final class MirrorTypeFactory.MirrorPrimitiveType
extends Object
implements XClass, HasModelElement
A primitive type or void.
- Since:
- 4.3
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionClass<?> asClass()This is the only place we can get back the java.lang.Class object and should be used very sparingly.boolean<A extends Annotation>
AgetAnnotation(Class<A> annotationClass) Returns this element's annotation if present.<A extends Annotation>
A[]getAnnotationsByType(Class<A> annotationClass) Array component type, for arrays only.getDeclaredConstructor(XClass... argTypes) Iterable<? extends XConstructor> Collect and concatenate the description text from the (possibly multiple)@ProtoDoc.valueannotations found on the element, in order of occurrence.Get theElement, nevernull.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.intThe modifiers, as per java.lang.reflect.Modifier.getName()inthashCode()booleanisArray()booleanisAssignableTo(XClass other) booleanisEnum()booleanisLocal()Is it a local or anonymous class?booleantoString()Methods inherited from interface XClass
isAbstract, isAssignableTo, isInterface, isRecord
-
Field Details
-
clazz
-
primitiveType
-
-
Constructor Details
-
MirrorPrimitiveType
MirrorPrimitiveType(Class<?> clazz, TypeMirror primitiveType)
-
-
Method Details
-
getFactory
- Specified by:
getFactoryin interfaceXClass
-
asClass
Description copied from interface:XClassThis is the only place we can get back the java.lang.Class object and should be used very sparingly. Some implementations can throwUnsupportedOperationException. -
getName
-
getSimpleName
- Specified by:
getSimpleNamein interfaceXClass
-
getCanonicalName
- Specified by:
getCanonicalNamein interfaceXClass
-
getPackageName
- Specified by:
getPackageNamein interfaceXClass
-
isPrimitive
public boolean isPrimitive()- Specified by:
isPrimitivein interfaceXClass
-
isEnum
-
getEnumConstants
Description copied from interface:XClassEnum constants, for enums only.- Specified by:
getEnumConstantsin interfaceXClass
-
getEnumConstant
- Specified by:
getEnumConstantin interfaceXClass
-
isArray
-
getComponentType
Description copied from interface:XClassArray component type, for arrays only.- Specified by:
getComponentTypein interfaceXClass
-
getEnclosingClass
- Specified by:
getEnclosingClassin interfaceXClass
-
getSuperclass
- Specified by:
getSuperclassin interfaceXClass
-
getInterfaces
Description copied from interface:XClassDirectly implemented interfaces.- Specified by:
getInterfacesin interfaceXClass
-
getGenericInterfaceParameterTypes
Description copied from interface:XClassGets the actual type params of an interface implemented directly by this class or all its supers.- Specified by:
getGenericInterfaceParameterTypesin interfaceXClass
-
isAssignableTo
- Specified by:
isAssignableToin interfaceXClass
-
getAnnotation
Description copied from interface:XElementReturns this element's annotation if present.- Specified by:
getAnnotationin interfaceXElement
-
getAnnotationsByType
- Specified by:
getAnnotationsByTypein interfaceXElement
-
getDocumentation
Description copied from interface:XElementCollect and concatenate the description text from the (possibly multiple)@ProtoDoc.valueannotations found on the element, in order of occurrence.- Specified by:
getDocumentationin interfaceXElement- Returns:
- the documentation or
nullif no doc or empty doc present
-
getModifiers
public int getModifiers()Description copied from interface:XElementThe modifiers, as per java.lang.reflect.Modifier.- Specified by:
getModifiersin interfaceXElement
-
getDeclaredConstructor
- Specified by:
getDeclaredConstructorin interfaceXClass
-
getDeclaredConstructors
- Specified by:
getDeclaredConstructorsin interfaceXClass
-
getDeclaredMethods
- Specified by:
getDeclaredMethodsin interfaceXClass
-
getMethod
-
getDeclaredFields
- Specified by:
getDeclaredFieldsin interfaceXClass
-
isLocal
-
equals
-
hashCode
-
toString
-
getElement
Description copied from interface:HasModelElementGet theElement, nevernull.- Specified by:
getElementin interfaceHasModelElement- Returns:
- the
Element, nevernull
-