Package org.codehaus.janino
Class Java.AbstractTypeBodyDeclaration
- java.lang.Object
-
- org.codehaus.janino.Java.Located
-
- org.codehaus.janino.Java.AbstractTypeBodyDeclaration
-
- All Implemented Interfaces:
Java.Locatable,Java.Scope,Java.TypeBodyDeclaration
- Direct Known Subclasses:
Java.FunctionDeclarator,Java.Initializer
- Enclosing class:
- Java
public abstract static class Java.AbstractTypeBodyDeclaration extends Java.Located implements Java.TypeBodyDeclaration
Abstract implementation ofJava.TypeBodyDeclaration.
-
-
Field Summary
Fields Modifier and Type Field Description private Java.TypeDeclarationdeclaringTypeJava.Modifier[]modifiersTheJava.Modifiers of this declaration.-
Fields inherited from class org.codehaus.janino.Java.Located
NOWHERE
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedAbstractTypeBodyDeclaration(Location location, Java.Modifier[] modifiers)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Java.Annotation[]getAnnotations()Java.TypeDeclarationgetDeclaringType()Java.ScopegetEnclosingScope()Java.Modifier[]getModifiers()voidsetDeclaringType(Java.TypeDeclaration declaringType)Sets the type declaration that this declaration belongs to.voidsetEnclosingScope(Java.Scope enclosingScope)Forward-implementsJava.BlockStatement.setEnclosingScope(Java.Scope).-
Methods inherited from class org.codehaus.janino.Java.Located
getLocation, throwCompileException
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.codehaus.janino.Java.Locatable
getLocation, throwCompileException
-
Methods inherited from interface org.codehaus.janino.Java.TypeBodyDeclaration
accept
-
-
-
-
Field Detail
-
declaringType
@Nullable private Java.TypeDeclaration declaringType
-
modifiers
public final Java.Modifier[] modifiers
TheJava.Modifiers of this declaration.
-
-
Constructor Detail
-
AbstractTypeBodyDeclaration
protected AbstractTypeBodyDeclaration(Location location, Java.Modifier[] modifiers)
-
-
Method Detail
-
setDeclaringType
public void setDeclaringType(Java.TypeDeclaration declaringType)
Description copied from interface:Java.TypeBodyDeclarationSets the type declaration that this declaration belongs to.- Specified by:
setDeclaringTypein interfaceJava.TypeBodyDeclaration
-
getDeclaringType
public Java.TypeDeclaration getDeclaringType()
- Specified by:
getDeclaringTypein interfaceJava.TypeBodyDeclaration- Returns:
- The type declaration that this declaration belongs to.
-
getModifiers
public Java.Modifier[] getModifiers()
- Specified by:
getModifiersin interfaceJava.TypeBodyDeclaration- Returns:
- The
Java.Modifiers of this declaration
-
getAnnotations
public Java.Annotation[] getAnnotations()
- Returns:
- The annotations of this function
-
setEnclosingScope
public void setEnclosingScope(Java.Scope enclosingScope)
Forward-implementsJava.BlockStatement.setEnclosingScope(Java.Scope).
-
getEnclosingScope
public Java.Scope getEnclosingScope()
- Specified by:
getEnclosingScopein interfaceJava.Scope- Returns:
- The scope that encloses this scope, or
null
-
-