public enum ResolvedPrimitiveType extends Enum<ResolvedPrimitiveType> implements ResolvedType
| Enum Constant and Description |
|---|
BOOLEAN |
BYTE |
CHAR |
DOUBLE |
FLOAT |
INT |
LONG |
SHORT |
| Modifier and Type | Method and Description |
|---|---|
ResolvedPrimitiveType |
asPrimitive() |
ResolvedPrimitiveType |
bnp(ResolvedPrimitiveType other) |
static Optional<ResolvedType> |
byBoxTypeQName(String qName) |
static ResolvedType |
byName(String name) |
String |
describe() |
Class |
getBoxTypeClass() |
String |
getBoxTypeQName() |
static ResolvedPrimitiveType[] |
getNumericPrimitiveTypes() |
boolean |
in(ResolvedPrimitiveType... types) |
boolean |
isArray() |
boolean |
isAssignableBy(ResolvedType other)
This method checks if ThisType t = new OtherType() would compile.
|
boolean |
isBoolean()
Is this a boolean type?
|
static boolean |
isBoxType(ResolvedType type) |
boolean |
isNumeric() |
boolean |
isPrimitive()
Is this a primitive type?
|
boolean |
isReferenceType()
Can this be seen as a ReferenceTypeUsage?
|
boolean |
isTypeVariable() |
String |
toDescriptor() |
String |
toString() |
static ResolvedType |
unp(ResolvedType type) |
static ResolvedPrimitiveType |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static ResolvedPrimitiveType[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, valueOfarrayLevel, asArrayType, asConstraintType, asReferenceType, asTypeParameter, asTypeVariable, asUnionType, asWildcard, erasure, isConstraint, isInferenceVariable, isNull, isNumericType, isReference, isUnionType, isVoid, isWildcard, mention, replaceTypeVariables, replaceTypeVariables, solveGenericTypespublic static final ResolvedPrimitiveType BYTE
public static final ResolvedPrimitiveType SHORT
public static final ResolvedPrimitiveType CHAR
public static final ResolvedPrimitiveType INT
public static final ResolvedPrimitiveType LONG
public static final ResolvedPrimitiveType BOOLEAN
public static final ResolvedPrimitiveType FLOAT
public static final ResolvedPrimitiveType DOUBLE
public static ResolvedPrimitiveType[] values()
for (ResolvedPrimitiveType c : ResolvedPrimitiveType.values()) System.out.println(c);
public static ResolvedPrimitiveType valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant with the specified nameNullPointerException - if the argument is nullpublic static ResolvedType byName(String name)
public static boolean isBoxType(ResolvedType type)
public static Optional<ResolvedType> byBoxTypeQName(String qName)
public static ResolvedPrimitiveType[] getNumericPrimitiveTypes()
public String toString()
toString in class Enum<ResolvedPrimitiveType>public ResolvedPrimitiveType asPrimitive()
asPrimitive in interface ResolvedTypepublic boolean isArray()
isArray in interface ResolvedTypepublic boolean isPrimitive()
ResolvedTypeisPrimitive in interface ResolvedTypepublic boolean isReferenceType()
ResolvedTypeisReferenceType in interface ResolvedTypepublic String describe()
describe in interface ResolvedTypepublic boolean isTypeVariable()
isTypeVariable in interface ResolvedTypepublic boolean isAssignableBy(ResolvedType other)
ResolvedTypeisAssignableBy in interface ResolvedTypepublic String getBoxTypeQName()
public Class getBoxTypeClass()
public boolean isNumeric()
public boolean isBoolean()
public ResolvedPrimitiveType bnp(ResolvedPrimitiveType other)
public static ResolvedType unp(ResolvedType type)
public boolean in(ResolvedPrimitiveType... types)
public String toDescriptor()
toDescriptor in interface ResolvedTypeCopyright © 2007–2024. All rights reserved.