public abstract class AbstractStaticScope<T> extends Object implements StaticScope<T>
Constructor and Description |
---|
AbstractStaticScope() |
Modifier and Type | Method and Description |
---|---|
StaticSlot<T> |
getOwnSlot(String name)
Like
getSlot but does not recurse into parent scopes. |
StaticScope<T> |
getParentScope()
Returns the scope enclosing this one or null if none.
|
Node |
getRootNode()
Returns the root node associated with this scope.
|
abstract StaticSlot<T> |
getSlot(String name)
Returns any defined slot within this scope for this name.
|
T |
getTypeOfThis()
Returns the expected type of
this in the current scope. |
public Node getRootNode()
StaticScope
getRootNode
in interface StaticScope<T>
public StaticScope<T> getParentScope()
StaticScope
getParentScope
in interface StaticScope<T>
public abstract StaticSlot<T> getSlot(String name)
StaticScope
getSlot
in interface StaticScope<T>
name
- The name of the variable slot to look up.null
if no
definition exists.public StaticSlot<T> getOwnSlot(String name)
StaticScope
getSlot
but does not recurse into parent scopes.getOwnSlot
in interface StaticScope<T>
public T getTypeOfThis()
StaticScope
this
in the current scope.getTypeOfThis
in interface StaticScope<T>