Package org.codehaus.janino
Class Java.InterfaceDeclaration
- java.lang.Object
-
- org.codehaus.janino.Java.AbstractTypeDeclaration
-
- org.codehaus.janino.Java.InterfaceDeclaration
-
- All Implemented Interfaces:
Java.Annotatable,Java.DocCommentable,Java.Locatable,Java.NamedTypeDeclaration,Java.Scope,Java.TypeDeclaration
- Direct Known Subclasses:
Java.MemberInterfaceDeclaration,Java.PackageMemberInterfaceDeclaration
- Enclosing class:
- Java
public abstract static class Java.InterfaceDeclaration extends Java.AbstractTypeDeclaration implements Java.NamedTypeDeclaration, Java.DocCommentable
Base for the various interface declaration kinds.
-
-
Field Summary
Fields Modifier and Type Field Description java.util.List<Java.FieldDeclaration>constantDeclarationsThe constants that this interface declares.Java.Type[]extendedTypesThe types of the interfaces that this interface extends.java.lang.StringnameThe simple name of the interface.-
Fields inherited from class org.codehaus.janino.Java.AbstractTypeDeclaration
anonymousClassCount, localClassCount
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedInterfaceDeclaration(Location location, java.lang.String docComment, Java.Modifier[] modifiers, java.lang.String name, Java.TypeParameter[] typeParameters, Java.Type[] extendedTypes)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddConstantDeclaration(Java.FieldDeclaration fd)Adds one constant declaration to this interface declaration.java.lang.StringgetDocComment()java.lang.StringgetName()booleanhasDeprecatedDocTag()Returnstrueif the object has a doc comment and the@deprecatedtag appears in the doc comment.java.lang.StringtoString()-
Methods inherited from class org.codehaus.janino.Java.AbstractTypeDeclaration
addDeclaredMethod, addMemberTypeDeclaration, createAnonymousClassName, createLocalTypeName, getAnnotations, getEnclosingScope, getLocation, getMemberTypeDeclaration, getMemberTypeDeclarations, getMethodDeclaration, getMethodDeclarations, getModifiers, getOptionalTypeParameters, invalidateMethodCaches, setEnclosingScope, throwCompileException
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.codehaus.janino.Java.Annotatable
getAnnotations
-
Methods inherited from interface org.codehaus.janino.Java.Locatable
getLocation, throwCompileException
-
Methods inherited from interface org.codehaus.janino.Java.NamedTypeDeclaration
getOptionalTypeParameters
-
Methods inherited from interface org.codehaus.janino.Java.Scope
getEnclosingScope
-
Methods inherited from interface org.codehaus.janino.Java.TypeDeclaration
accept, createAnonymousClassName, createLocalTypeName, getClassName, getMemberTypeDeclaration, getMemberTypeDeclarations, getMethodDeclaration, getMethodDeclarations
-
-
-
-
Field Detail
-
name
public final java.lang.String name
The simple name of the interface.
-
extendedTypes
public final Java.Type[] extendedTypes
The types of the interfaces that this interface extends.
-
constantDeclarations
public final java.util.List<Java.FieldDeclaration> constantDeclarations
The constants that this interface declares.
-
-
Constructor Detail
-
InterfaceDeclaration
protected InterfaceDeclaration(Location location, @Nullable java.lang.String docComment, Java.Modifier[] modifiers, java.lang.String name, @Nullable Java.TypeParameter[] typeParameters, Java.Type[] extendedTypes)
-
-
Method Detail
-
toString
public java.lang.String toString()
- Specified by:
toStringin classJava.AbstractTypeDeclaration
-
addConstantDeclaration
public void addConstantDeclaration(Java.FieldDeclaration fd)
Adds one constant declaration to this interface declaration.
-
getName
public java.lang.String getName()
- Specified by:
getNamein interfaceJava.NamedTypeDeclaration- Returns:
- The declared (not the fully qualified) name of the class or interface
-
getDocComment
@Nullable public java.lang.String getDocComment()
- Specified by:
getDocCommentin interfaceJava.DocCommentable- Returns:
- The doc comment of the object or
null
-
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
-
-