01: /*
02: * Author: Mike Atkinson
03: *
04: * This software has been developed under the copyleft
05: * rules of the GNU General Public License. Please
06: * consult the GNU General Public License for more
07: * details about use and distribution of this software.
08: */
09: package net.sourceforge.jrefactory.ast;
10:
11: import java.util.*;
12: import net.sourceforge.jrefactory.ast.Node;
13: import net.sourceforge.jrefactory.parser.JavaParser;
14: import net.sourceforge.jrefactory.parser.JavaParserTreeConstants;
15: import net.sourceforge.jrefactory.parser.JavaParserVisitor;
16: import net.sourceforge.jrefactory.parser.NamedToken;
17: import net.sourceforge.jrefactory.parser.Token;
18:
19: /**
20: * This holds an element of an enumeration. Enumerations are new to JDK 1.5.
21: *
22: * @author Mike Atkinson
23: * @since jRefactory 2.9.0, created October 16, 2003
24: */
25: public class ASTEnumElement extends ASTLiteral {
26: /**
27: * Constructor for the ASTEnumElement node.
28: *
29: * @param identifier The id of this node (JJTENUMELEMENT).
30: */
31: public ASTEnumElement(int identifier) {
32: super (identifier);
33: }
34:
35: /**
36: * Constructor for the ASTEnumElement node.
37: *
38: * @param parser The JavaParser that created this ASTEnumElement node.
39: * @param identifier The id of this node (JJTENUMELEMENT).
40: */
41: public ASTEnumElement(JavaParser parser, int identifier) {
42: super (parser, identifier);
43: }
44:
45: /**
46: * Accept the visitor. *
47: *
48: * @param visitor An implementation of JavaParserVisitor that processes the ASTEnumElement node.
49: * @param data Some data being passed between the visitor methods.
50: * @return Usually the data parameter (possibly modified).
51: */
52: public Object jjtAccept(JavaParserVisitor visitor, Object data) {
53: return visitor.visit(this, data);
54: }
55: }
|