public abstract static class Java.FunctionDeclarator extends Java.AbstractTypeBodyDeclaration implements Java.DocCommentable
Java.ConstructorDeclarator and Java.MethodDeclarator.| Modifier and Type | Class and Description |
|---|---|
static class |
Java.FunctionDeclarator.FormalParameter
Representation of a (formal) function parameter.
|
static class |
Java.FunctionDeclarator.FormalParameters
Representation of the (formal) function parameters.
|
| Modifier and Type | Field and Description |
|---|---|
Java.FunctionDeclarator.FormalParameters |
formalParameters
The parameters of the function.
|
Map<String,Java.LocalVariable> |
localVariables
Mapping of variable names to
Java.LocalVariables. |
Java.Modifiers |
modifiers
The
Java.Modifiers of this declarator. |
String |
name
The name of the function ("
|
List<? extends Java.BlockStatement> |
optionalStatements
The statements that comprise the function;
null for abstract method declarations. |
Java.Type[] |
thrownExceptions
The types of the declared exceptions.
|
Java.Type |
type
The return type of the function (VOID for constructors).
|
statiCNOWHERE| Constructor and Description |
|---|
FunctionDeclarator(Location location,
String optionalDocComment,
Java.Modifiers modifiers,
Java.Type type,
String name,
Java.FunctionDeclarator.FormalParameters parameters,
Java.Type[] thrownExceptions,
List<? extends Java.BlockStatement> optionalStatements) |
| Modifier and Type | Method and Description |
|---|---|
abstract void |
accept(Visitor.FunctionDeclaratorVisitor visitor)
Invokes the '
visit...()' method of Visitor.FunctionDeclaratorVisitor for the concrete
Java.FunctionDeclarator type. |
Java.Annotation[] |
getAnnotations() |
String |
getDocComment() |
Java.Scope |
getEnclosingScope() |
boolean |
hasDeprecatedDocTag()
Returns
true if the object has a doc comment and
the @deprecated tag appears in the doc
comment. |
void |
setDeclaringType(Java.TypeDeclaration declaringType)
Sets the type declaration that this declaration belongs to.
|
getDeclaringType, isStatic, setEnclosingScopegetLocation, throwCompileExceptionclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitacceptgetLocation, throwCompileExceptionpublic final Java.Modifiers modifiers
Java.Modifiers of this declarator.public final Java.Type type
public final String name
public final Java.FunctionDeclarator.FormalParameters formalParameters
public final Java.Type[] thrownExceptions
public final List<? extends Java.BlockStatement> optionalStatements
null for abstract method declarations.public Map<String,Java.LocalVariable> localVariables
Java.LocalVariables.public FunctionDeclarator(Location location, String optionalDocComment, Java.Modifiers modifiers, Java.Type type, String name, Java.FunctionDeclarator.FormalParameters parameters, Java.Type[] thrownExceptions, List<? extends Java.BlockStatement> optionalStatements)
public Java.Annotation[] getAnnotations()
public abstract void accept(Visitor.FunctionDeclaratorVisitor visitor)
visit...()' method of Visitor.FunctionDeclaratorVisitor for the concrete
Java.FunctionDeclarator type.public void setDeclaringType(Java.TypeDeclaration declaringType)
Java.TypeBodyDeclarationsetDeclaringType in interface Java.TypeBodyDeclarationsetDeclaringType in class Java.AbstractTypeBodyDeclarationpublic Java.Scope getEnclosingScope()
getEnclosingScope in interface Java.ScopegetEnclosingScope in class Java.AbstractTypeBodyDeclarationnullpublic String getDocComment()
getDocComment in interface Java.DocCommentablenullpublic boolean hasDeprecatedDocTag()
Java.DocCommentabletrue if the object has a doc comment and
the @deprecated tag appears in the doc
comment.hasDeprecatedDocTag in interface Java.DocCommentableCopyright © 2001–2025. All rights reserved.