Package org.codehaus.janino
Class Java.FieldDeclaration
java.lang.Object
org.codehaus.janino.Java.Located
org.codehaus.janino.Java.Statement
org.codehaus.janino.Java.FieldDeclaration
- All Implemented Interfaces:
Java.BlockStatement,Java.DocCommentable,Java.Locatable,Java.Scope,Java.TypeBodyDeclaration
- Enclosing class:
Java
public static final class Java.FieldDeclaration
extends Java.Statement
implements Java.TypeBodyDeclaration, Java.DocCommentable
This class is derived from "Statement", because it provides for the
initialization of the field. In other words, "compile()" generates the
code that initializes the field.
-
Field Summary
FieldsFields inherited from class org.codehaus.janino.Java.Statement
localVariablesFields inherited from class org.codehaus.janino.Java.Located
NOWHERE -
Constructor Summary
ConstructorsConstructorDescriptionFieldDeclaration(Location location, String optionalDocComment, Java.ModifiersAndAnnotations modifiersAndAnnotations, Java.Type type, Java.VariableDeclarator[] variableDeclarators) -
Method Summary
Modifier and TypeMethodDescriptionvoidaccept(Visitor.BlockStatementVisitor visitor) voidaccept(Visitor.TypeBodyDeclarationVisitor visitor) Returns the doc comment of the object ornull.booleanReturnstrueif the object has a doc comment and the@deprecatedtag appears in the doc comment.booleanisStatic()voidsetDeclaringType(Java.TypeDeclaration declaringType) toString()Methods inherited from class org.codehaus.janino.Java.Statement
findLocalVariable, getEnclosingScope, setEnclosingScopeMethods inherited from class org.codehaus.janino.Java.Located
getLocation, throwCompileExceptionMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.codehaus.janino.Java.Locatable
getLocation, throwCompileException
-
Field Details
-
modifiersAndAnnotations
-
type
-
variableDeclarators
-
-
Constructor Details
-
FieldDeclaration
public FieldDeclaration(Location location, String optionalDocComment, Java.ModifiersAndAnnotations modifiersAndAnnotations, Java.Type type, Java.VariableDeclarator[] variableDeclarators)
-
-
Method Details
-
setDeclaringType
- Specified by:
setDeclaringTypein interfaceJava.TypeBodyDeclaration
-
getDeclaringType
- Specified by:
getDeclaringTypein interfaceJava.TypeBodyDeclaration
-
isStatic
public boolean isStatic()- Specified by:
isStaticin interfaceJava.TypeBodyDeclaration
-
toString
-
accept
- Specified by:
acceptin interfaceJava.TypeBodyDeclaration
-
accept
- Specified by:
acceptin interfaceJava.BlockStatement
-
getDocComment
Description copied from interface:Java.DocCommentableReturns the doc comment of the object ornull.- Specified by:
getDocCommentin interfaceJava.DocCommentable
-
hasDeprecatedDocTag
public boolean hasDeprecatedDocTag()Description copied from interface:Java.DocCommentableReturnstrueif the object has a doc comment and the@deprecatedtag appears in the doc comment.- Specified by:
hasDeprecatedDocTagin interfaceJava.DocCommentable
-