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. ASTTypeMethod.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   import net.sourceforge.pmd.lang.dfa.DFAGraphMethod;
10  
11  public class ASTTypeMethod extends AbstractPLSQLNode implements ExecutableCode, DFAGraphMethod {
12    public ASTTypeMethod(int id) {
13      super(id);
14    }
15  
16    public ASTTypeMethod(PLSQLParser p, int id) {
17      super(p, id);
18    }
19  
20  
21    /** Accept the visitor. **/
22    public Object jjtAccept(PLSQLParserVisitor visitor, Object data) {
23      return visitor.visit(this, data);
24    }
25  
26    /**
27     * Gets the name of the method.
28     *
29     * @return a String representing the name of the method
30     */
31    public String getMethodName() {
32      ASTMethodDeclarator md = getFirstChildOfType(ASTMethodDeclarator.class);
33      if (md != null) {
34        return md.getImage();
35      }
36      return null;
37    }
38  
39    @Override
40    public String getName() {
41        return getMethodName();
42    }
43  }
44  /* JavaCC - OriginalChecksum=657963d26263c637fa18391bce82f1c1 (do not edit this line) */