public interface JavaHasType extends JavaElement
Modifier and Type | Field and Description |
---|---|
static JavaHasType[] |
EMPTY_ARRAY |
Modifier and Type | Method and Description |
---|---|
JavaType |
getResolvedType()
A JavaField instance will return the field's type.
|
UnresolvedType |
getUnresolvedType()
Information about a type that has not been resolved.
|
getElementKind, getFile, getModifiers, getOwner, getSourceElement, isDeprecated, isFinal, isHidden, isSourceElement, isSynthetic, printCompiledInfo
static final JavaHasType[] EMPTY_ARRAY
JavaType getResolvedType()
A JavaMethod instance will return the method's return type.
A JavaVariable instance will return the variable's type.
A JavaType instance will return itself.
An array is a special case, you can't determine the type of an array by its members, e.g. with { 0, 'e', (short)5 } the type could be int[], char[], short[], long[], Object[] and more. So for arrays the Null type (returns 'null' for the name) will be returned with the appropriate dimensions, e.g.: { "bar", "foo" } will have null[] type, { null, { null, 5, 5L } } will have null[][] type.
UnresolvedType getUnresolvedType()