public static class JCTree.JCMethodDecl extends JCTree implements MethodTree
JCTree.Factory, JCTree.JCAnnotatedType, JCTree.JCAnnotation, JCTree.JCArrayAccess, JCTree.JCArrayTypeTree, JCTree.JCAssert, JCTree.JCAssign, JCTree.JCAssignOp, JCTree.JCBinary, JCTree.JCBlock, JCTree.JCBreak, JCTree.JCCase, JCTree.JCCatch, JCTree.JCClassDecl, JCTree.JCCompilationUnit, JCTree.JCConditional, JCTree.JCContinue, JCTree.JCDoWhileLoop, JCTree.JCEnhancedForLoop, JCTree.JCErroneous, JCTree.JCExpression, JCTree.JCExpressionStatement, JCTree.JCFieldAccess, JCTree.JCForLoop, JCTree.JCFunctionalExpression, JCTree.JCIdent, JCTree.JCIf, JCTree.JCImport, JCTree.JCInstanceOf, JCTree.JCLabeledStatement, JCTree.JCLambda, JCTree.JCLiteral, JCTree.JCMemberReference, JCTree.JCMethodDecl, JCTree.JCMethodInvocation, JCTree.JCModifiers, JCTree.JCNewArray, JCTree.JCNewClass, JCTree.JCParens, JCTree.JCPolyExpression, JCTree.JCPrimitiveTypeTree, JCTree.JCReturn, JCTree.JCSkip, JCTree.JCStatement, JCTree.JCSwitch, JCTree.JCSynchronized, JCTree.JCThrow, JCTree.JCTry, JCTree.JCTypeApply, JCTree.JCTypeCast, JCTree.JCTypeIntersection, JCTree.JCTypeParameter, JCTree.JCTypeUnion, JCTree.JCUnary, JCTree.JCVariableDecl, JCTree.JCWhileLoop, JCTree.JCWildcard, JCTree.LetExpr, JCTree.Tag, JCTree.TypeBoundKind, JCTree.Visitor
Modifier and Type | Field and Description |
---|---|
JCTree.JCBlock |
body
statements in the method
|
JCTree.JCExpression |
defaultValue
default value, for annotation types
|
JCTree.JCModifiers |
mods
method modifiers
|
Name |
name
method name
|
List<JCTree.JCVariableDecl> |
params
value parameters
|
JCTree.JCVariableDecl |
recvparam
receiver parameter
|
JCTree.JCExpression |
restype
type of method return value
|
Symbol.MethodSymbol |
sym
method symbol
|
List<JCTree.JCExpression> |
thrown
exceptions thrown by this method
|
List<JCTree.JCTypeParameter> |
typarams
type parameters
|
Modifier | Constructor and Description |
---|---|
protected |
JCMethodDecl(JCTree.JCModifiers mods,
Name name,
JCTree.JCExpression restype,
List<JCTree.JCTypeParameter> typarams,
JCTree.JCVariableDecl recvparam,
List<JCTree.JCVariableDecl> params,
List<JCTree.JCExpression> thrown,
JCTree.JCBlock body,
JCTree.JCExpression defaultValue,
Symbol.MethodSymbol sym) |
Modifier and Type | Method and Description |
---|---|
void |
accept(JCTree.Visitor v)
Visit this tree with a given visitor.
|
<R,D> R |
accept(TreeVisitor<R,D> v,
D d)
Accept method used to implement the visitor pattern.
|
JCTree.JCBlock |
getBody() |
JCTree |
getDefaultValue() |
Tree.Kind |
getKind()
Gets the kind of this tree.
|
JCTree.JCModifiers |
getModifiers() |
Name |
getName() |
List<JCTree.JCVariableDecl> |
getParameters() |
JCTree.JCVariableDecl |
getReceiverParameter()
Return an explicit receiver parameter ("this" parameter).
|
JCTree |
getReturnType() |
JCTree.Tag |
getTag() |
List<JCTree.JCExpression> |
getThrows() |
List<JCTree.JCTypeParameter> |
getTypeParameters() |
clone, getEndPosition, getPreferredPosition, getStartPosition, getTree, hasTag, pos, setPos, setType, toString
public JCTree.JCModifiers mods
public Name name
public JCTree.JCExpression restype
public List<JCTree.JCTypeParameter> typarams
public JCTree.JCVariableDecl recvparam
public List<JCTree.JCVariableDecl> params
public List<JCTree.JCExpression> thrown
public JCTree.JCBlock body
public JCTree.JCExpression defaultValue
public Symbol.MethodSymbol sym
protected JCMethodDecl(JCTree.JCModifiers mods, Name name, JCTree.JCExpression restype, List<JCTree.JCTypeParameter> typarams, JCTree.JCVariableDecl recvparam, List<JCTree.JCVariableDecl> params, List<JCTree.JCExpression> thrown, JCTree.JCBlock body, JCTree.JCExpression defaultValue, Symbol.MethodSymbol sym)
public void accept(JCTree.Visitor v)
JCTree
public Tree.Kind getKind()
Tree
public JCTree.JCModifiers getModifiers()
getModifiers
in interface MethodTree
public Name getName()
getName
in interface MethodTree
public JCTree getReturnType()
getReturnType
in interface MethodTree
public List<JCTree.JCTypeParameter> getTypeParameters()
getTypeParameters
in interface MethodTree
public List<JCTree.JCVariableDecl> getParameters()
getParameters
in interface MethodTree
public JCTree.JCVariableDecl getReceiverParameter()
MethodTree
getReceiverParameter
in interface MethodTree
public List<JCTree.JCExpression> getThrows()
getThrows
in interface MethodTree
public JCTree.JCBlock getBody()
getBody
in interface MethodTree
public JCTree getDefaultValue()
getDefaultValue
in interface MethodTree
public <R,D> R accept(TreeVisitor<R,D> v, D d)
Tree
public JCTree.Tag getTag()
Copyright © 2017 earcam. All rights reserved.