org.aspectj.ajdt.internal.compiler.lookup
Class EclipseScope
java.lang.Object
org.aspectj.ajdt.internal.compiler.lookup.EclipseScope
- All Implemented Interfaces:
- IScope
public class EclipseScope
- extends java.lang.Object
- implements IScope
Adaptor from org.eclipse.jdt.internal.compiler.lookup.Scope to
org.aspectj.weaver.IScope
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
EclipseScope
public EclipseScope(FormalBinding[] bindings,
Scope scope)
lookupType
public UnresolvedType lookupType(java.lang.String name,
IHasPosition location)
- Specified by:
lookupType
in interface IScope
- Returns:
- the type corresponding to the name in this scope, or ResolvedType.MISSING if no such type exists
getImportedNames
public java.lang.String[] getImportedNames()
- Specified by:
getImportedNames
in interface IScope
getImportedPrefixes
public java.lang.String[] getImportedPrefixes()
- Specified by:
getImportedPrefixes
in interface IScope
lookupFormal
public FormalBinding lookupFormal(java.lang.String name)
- Specified by:
lookupFormal
in interface IScope
- Returns:
- the formal associated with the name, or null if no such formal exists
getFormal
public FormalBinding getFormal(int i)
- Specified by:
getFormal
in interface IScope
- Returns:
- the formal with the index. Throws ArrayOutOfBounds exception if out of bounds
getFormalCount
public int getFormalCount()
- Specified by:
getFormalCount
in interface IScope
makeSourceLocation
public ISourceLocation makeSourceLocation(IHasPosition location)
getMessageHandler
public IMessageHandler getMessageHandler()
- Specified by:
getMessageHandler
in interface IScope
message
public void message(IMessage.Kind kind,
IHasPosition location1,
IHasPosition location2,
java.lang.String message)
- Specified by:
message
in interface IScope
message
public void message(IMessage.Kind kind,
IHasPosition location,
java.lang.String message)
- Specified by:
message
in interface IScope
message
public void message(IMessage aMessage)
- Specified by:
message
in interface IScope
getWorld
public World getWorld()
- Specified by:
getWorld
in interface IScope
getEnclosingType
public ResolvedType getEnclosingType()
- Specified by:
getEnclosingType
in interface IScope
setLimitedImports
public void setLimitedImports(char[] validPackage)
- Mark this scope as only allowing limited support for imports. This is to
ensure that references in annotation style pointcuts are accidentally
resolved against import statements. They won't be if javac is used (and
the resulting .class file will contain 'bad pointcuts') so this method
enables it to also be policed when compiling with ajc.
- Parameters:
validPackage
- unqualified references can be resolved if the type is
in the same package as the type containing the pointcut
declaration.