public static final class Java.EnumConstant extends Java.AbstractClassDeclaration implements Java.DocCommentable
| Modifier and Type | Field and Description |
|---|---|
List<Java.Annotation> |
annotations
The (often empty) list of annotations on this enum constant declaration.
|
String |
name
The name of the declared enum constant.
|
Java.Rvalue[] |
optionalArguments
The optional arguments that appear after the enum constant name iff the enum declares constructors with
one or more parameters.
|
String |
optionalDocComment
The optional "doc comment" that appeared in the compilation unit immediately before this enum constant
declaration.
|
constructors, variableDeclaratorsAndInitializersanonymousClassCount, localClassCount| Constructor and Description |
|---|
EnumConstant(Location location,
String optionalDocComment,
List<Java.Annotation> annotations,
String name,
Java.Rvalue[] optionalArguments) |
| Modifier and Type | Method and Description |
|---|---|
<R,EX extends Throwable> |
accept(Visitor.TypeDeclarationVisitor<R,EX> visitor)
Invokes the "
visit...()" method of Visitor.TypeDeclarationVisitor for the concrete Java.TypeDeclaration type. |
Java.Annotation[] |
getAnnotations() |
String |
getClassName()
Determines the effective class name, e.g.
|
String |
getDocComment() |
boolean |
hasDeprecatedDocTag()
Returns
true if the object has a doc comment and the @deprecated tag appears in the doc
comment. |
String |
toString() |
addConstructor, addFieldDeclaration, addInitializer, defineSyntheticField, getSyntheticFields, getVariableDeclaratorsAndInitializersaddDeclaredMethod, addMemberTypeDeclaration, createAnonymousClassName, createLocalTypeName, getEnclosingScope, getLocation, getMemberTypeDeclaration, getMemberTypeDeclarations, getMethodDeclaration, getMethodDeclarations, getModifierFlags, getOptionalTypeParameters, invalidateMethodCaches, setEnclosingScope, throwCompileExceptionclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitcreateAnonymousClassName, createLocalTypeName, getMemberTypeDeclaration, getMemberTypeDeclarations, getMethodDeclaration, getMethodDeclarations, getModifierFlagsgetLocation, throwCompileExceptiongetEnclosingScope@Nullable public final String optionalDocComment
public final List<Java.Annotation> annotations
public final String name
@Nullable public final Java.Rvalue[] optionalArguments
public EnumConstant(Location location, @Nullable String optionalDocComment, List<Java.Annotation> annotations, String name, @Nullable Java.Rvalue[] optionalArguments)
public String getClassName()
Java.TypeDeclarationgetClassName in interface Java.TypeDeclarationpublic Java.Annotation[] getAnnotations()
getAnnotations in interface Java.AnnotatablegetAnnotations in class Java.AbstractTypeDeclarationJava.TypeDeclaration, Java.FieldDeclaration, Java.MethodDeclarator
or Java.ConstructorDeclarator@Nullable public String getDocComment()
getDocComment in interface Java.DocCommentablenullpublic boolean hasDeprecatedDocTag()
Java.DocCommentabletrue if the object has a doc comment and the @deprecated tag appears in the doc
comment.hasDeprecatedDocTag in interface Java.DocCommentable@Nullable public <R,EX extends Throwable> R accept(Visitor.TypeDeclarationVisitor<R,EX> visitor) throws EX extends Throwable
Java.TypeDeclarationvisit...()" method of Visitor.TypeDeclarationVisitor for the concrete Java.TypeDeclaration type.accept in interface Java.TypeDeclarationEX extends Throwablepublic String toString()
toString in class Java.AbstractTypeDeclarationCopyright © 2019. All rights reserved.