public abstract class AbstractJavaScope extends AbstractScope
| Constructor and Description |
|---|
AbstractJavaScope() |
| Modifier and Type | Method and Description |
|---|---|
void |
addDeclaration(NameDeclaration declaration)
Adds a new declaration to this scope.
|
protected void |
checkForDuplicatedNameDeclaration(NameDeclaration declaration) |
boolean |
contains(NameOccurrence occurrence)
Tests whether or not a
NameOccurrence is directly contained in the scope. |
protected abstract NameDeclaration |
findVariableHere(JavaNameOccurrence occurrence) |
protected <T> String |
glomNames(Set<T> s) |
addNameOccurrence, getDeclarations, getDeclarations, getEnclosingScope, getParent, setParentpublic void addDeclaration(NameDeclaration declaration)
ScopeScope.contains(NameOccurrence) and Scope.addNameOccurrence(NameOccurrence) can
be used correctly.addDeclaration in interface ScopeaddDeclaration in class AbstractScopedeclaration - the declaration to addprotected void checkForDuplicatedNameDeclaration(NameDeclaration declaration)
public boolean contains(NameOccurrence occurrence)
ScopeNameOccurrence is directly contained in the scope.
This means, whether the given NameOccurrence references a declaration, that has been
declared within this scope.
Note that this search is just for this scope - it doesn't go diving into any
parent scopes.contains in interface Scopecontains in class AbstractScopeprotected abstract NameDeclaration findVariableHere(JavaNameOccurrence occurrence)
Copyright © 2002-2014 InfoEther. All Rights Reserved.