View Javadoc

1   /**
2    * BSD-style license; for more info see http://pmd.sourceforge.net/license.html
3    */
4   
5   /* Generated By:JJTree: Do not edit this line. ASTMethodDeclaration.java Version 4.1 */
6   /* JavaCCOptions:MULTI=true,NODE_USES_PARSER=true,VISITOR=true,TRACK_TOKENS=true,NODE_PREFIX=AST,NODE_EXTENDS=,NODE_FACTORY= */
7   package net.sourceforge.pmd.lang.plsql.ast;
8   
9   
10  public class ASTMethodDeclaration extends AbstractPLSQLNode implements ExecutableCode {
11    public ASTMethodDeclaration(int id) {
12      super(id);
13    }
14  
15    public ASTMethodDeclaration(PLSQLParser p, int id) {
16      super(p, id);
17    }
18  
19  
20    /** Accept the visitor. **/
21    public Object jjtAccept(PLSQLParserVisitor visitor, Object data) {
22      return visitor.visit(this, data);
23    }
24  
25    /**
26     * Gets the name of the method.
27     *
28     * @return a String representing the name of the method
29     */
30    @Override
31    public String getMethodName() {
32      ASTMethodDeclarator md = getFirstDescendantOfType(ASTMethodDeclarator.class);
33      if (md != null) {
34        return md.getImage();
35      }
36      return null;
37    }
38  }
39  /* JavaCC - OriginalChecksum=f4e143bd15adcb918d9ecd2757108a24 (do not edit this line) */