All Downloads are FREE. Search and download functionalities are using the official Maven repository.

net.sourceforge.pmd.lang.java.ast.ASTEnumDeclaration Maven / Gradle / Ivy

There is a newer version: 7.7.0
Show newest version
/**
 * BSD-style license; for more info see http://pmd.sourceforge.net/license.html
 */

package net.sourceforge.pmd.lang.java.ast;

import net.sourceforge.pmd.lang.ast.Node;

/**
 * Represents an enum declaration.
 * This is a {@linkplain Node#isFindBoundary() find boundary} for tree traversal methods.
 *
 * 

An enum declaration is implicitly final unless it contains at * least one enum constant that has a class body. A nested enum type * is implicitly static. * *

 *
 * EnumDeclaration ::= {@link ASTModifierList ModifierList}
 *                     "enum"
 *                     <IDENTIFIER>
 *                     {@linkplain ASTImplementsList ImplementsList}?
 *                     {@link ASTEnumBody EnumBody}
 *
 * 
*/ public final class ASTEnumDeclaration extends AbstractAnyTypeDeclaration { ASTEnumDeclaration(int id) { super(id); } @Override protected R acceptVisitor(JavaVisitor visitor, P data) { return visitor.visit(this, data); } @Override public ASTEnumBody getBody() { return (ASTEnumBody) getLastChild(); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy