public interface JavaParameter extends JavaAnnotatedElement, JavaType
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getCanonicalName()
Equivalent of (@link
Class.getCanonicalName() . |
JavaClass |
getDeclaringClass()
The declaring class of the declaring method of this parameter.
|
JavaExecutable |
getExecutable()
Returns the declaring method or constructor of this parameter
|
java.lang.String |
getFullyQualifiedName()
Every primitive type, named package, top level class, and top level interface has a fully qualified name:
The fully qualified name of a primitive type is the keyword for that primitive type, namely byte, short, char, int, long, float, double, or boolean.
|
JavaClass |
getJavaClass() |
java.lang.String |
getName() |
java.lang.String |
getResolvedFullyQualifiedName() |
java.lang.String |
getResolvedGenericFullyQualifiedName() |
java.lang.String |
getResolvedGenericValue() |
java.lang.String |
getResolvedValue() |
JavaType |
getType() |
java.lang.String |
getValue()
If there's a reference to this class, use the value used in the code.
|
boolean |
isVarArgs()
Is this a Java 5 var args type specified using three dots. e.g.
|
getAnnotations, getComment, getNamedParameter, getTagByName, getTags, getTagsByName
getCodeBlock, getLineNumber
getBinaryName, getGenericCanonicalName, getGenericFullyQualifiedName, getGenericValue, toGenericString
java.lang.String getName()
JavaType getType()
JavaClass getJavaClass()
JavaExecutable getExecutable()
JavaClass getDeclaringClass()
boolean isVarArgs()
void doStuff(Object... thing)
true
if this parameter is a varArg, otherwise false
java.lang.String getValue()
JavaType
private String fieldA; // getValue() will return "String" private java.lang.String fieldA; // getValue() will return "java.lang.String" private List>String> aList; // getValue() will return "List"
java.lang.String getFullyQualifiedName()
JavaType
Every primitive type, named package, top level class, and top level interface has a fully qualified name:Some examples how names will be translatedEach member class, member interface, and array type may have a fully qualified name:
- The fully qualified name of a primitive type is the keyword for that primitive type, namely byte, short, char, int, long, float, double, or boolean.
- The fully qualified name of a named package that is not a subpackage of a named package is its simple name.
- The fully qualified name of a named package that is a subpackage of another named package consists of the fully qualified name of the containing package, followed by ".", followed by the simple (member) name of the subpackage.
- The fully qualified name of a top level class or top level interface that is declared in an unnamed package is the simple name of the class or interface.
- The fully qualified name of a top level class or top level interface that is declared in a named package consists of the fully qualified name of the package, followed by ".", followed by the simple name of the class or interface.
- A member class or member interface M of another class or interface C has a fully qualified name if and only if C has a fully qualified name.
- In that case, the fully qualified name of M consists of the fully qualified name of C, followed by ".", followed by the simple name of M.
- An array type has a fully qualified name if and only if its element type has a fully qualified name.
- In that case, the fully qualified name of an array type consists of the fully qualified name of the component type of the array type followed by "[]".
Object > java.lang.Object java.util.List > java.util.List ? > ? T > T anypackage.Outer.Inner > anypackage.Outer.Inner String[][] > java.lang.String[][]
getFullyQualifiedName
in interface JavaType
null
JavaClass.getComponentType()
,
JavaType.getBinaryName()
,
https://docs.oracle.com/javase/specs/jls/se8/html/jls-6.html#jls-6.7java.lang.String getCanonicalName()
JavaType
Class.getCanonicalName()
.getCanonicalName
in interface JavaType
null
java.lang.String getResolvedValue()
java.lang.String getResolvedGenericValue()
null
java.lang.String getResolvedFullyQualifiedName()
null
java.lang.String getResolvedGenericFullyQualifiedName()
null
Copyright © 2002-2021. All Rights Reserved.