public abstract static class Java.AbstractTypeDeclaration extends Object implements Java.TypeDeclaration
Java.TypeDeclaration.| Modifier and Type | Field and Description |
|---|---|
int |
anonymousClassCount
For naming anonymous classes.
|
int |
localClassCount
For naming local classes.
|
| Constructor and Description |
|---|
AbstractTypeDeclaration(Location location,
Java.Modifiers modifiers,
Java.TypeParameter[] optionalTypeParameters) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitaccept, getClassNamepublic int anonymousClassCount
public int localClassCount
public AbstractTypeDeclaration(Location location, Java.Modifiers modifiers, @Nullable Java.TypeParameter[] optionalTypeParameters)
public short getModifierFlags()
getModifierFlags in interface Java.TypeDeclarationModpublic Java.Annotation[] getAnnotations()
getAnnotations in interface Java.AnnotatableJava.TypeDeclaration, Java.FieldDeclaration, Java.MethodDeclarator
or Java.ConstructorDeclaratorpublic void setEnclosingScope(Java.Scope enclosingScope)
Java.TypeDeclaration.@Nullable public Java.TypeParameter[] getOptionalTypeParameters()
public Java.Scope getEnclosingScope()
getEnclosingScope in interface Java.Scopenullpublic void invalidateMethodCaches()
resolvedType. This is necessary when methods are added
during compilationpublic void addMemberTypeDeclaration(Java.MemberTypeDeclaration mcoid)
Java.MemberTypeDeclaration to this type.public void addDeclaredMethod(Java.MethodDeclarator method)
Java.MethodDeclarator to this type.public Collection<Java.MemberTypeDeclaration> getMemberTypeDeclarations()
getMemberTypeDeclarations in interface Java.TypeDeclarationJava.TypeDeclaration@Nullable public Java.MemberTypeDeclaration getMemberTypeDeclaration(String name)
Java.TypeDeclarationgetMemberTypeDeclaration in interface Java.TypeDeclarationnull if a member type with that name is not declared@Nullable public Java.MethodDeclarator getMethodDeclaration(String name)
Java.TypeDeclarationgetMethodDeclaration in interface Java.TypeDeclarationnull if a method with this name is not declaredpublic List<Java.MethodDeclarator> getMethodDeclarations()
getMethodDeclarations in interface Java.TypeDeclarationJava.TypeDeclaration, not including methods declared in
supertypespublic String createLocalTypeName(String localTypeName)
Java.TypeDeclarationcreateLocalTypeName in interface Java.TypeDeclarationpublic String createAnonymousClassName()
Java.TypeDeclarationcreateAnonymousClassName in interface Java.TypeDeclarationpublic Location getLocation()
getLocation in interface Java.Locatablepublic void throwCompileException(String message) throws CompileException
Java.LocatableCompileException with the given message and this object's location.throwCompileException in interface Java.Locatablemessage - The message to reportCompileExceptionCopyright © 2019. All rights reserved.