org.media.mn8
Class Scope
java.lang.Object
|
+--org.media.mn8.Scope
- All Implemented Interfaces:
- java.lang.Cloneable
- Direct Known Subclasses:
- GlobalScope
- public class Scope
- extends java.lang.Object
- implements java.lang.Cloneable
The base implementation of a Scope.
- Version:
- $Revision: 1.14 $ $Date: 2002/06/05 14:31:36 $
- Author:
- Remus Pereni
Field Summary |
protected Scope |
_prev
The upper (in hierarchy) scope. |
Constructor Summary |
Scope(Scope prev)
The default constructor. |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
_prev
protected Scope _prev
- The upper (in hierarchy) scope.
Scope
public Scope(Scope prev)
- The default constructor. It is protected since there will
be specific implementations of this class.
- Parameters:
prev
- The outer scope, in which this one is situated
clear
public void clear()
insertInstance
public void insertInstance(java.lang.String variable_name,
Concept variable)
- Inserts a variable into the local scope.
- Parameters:
variable_name
- The name of the variablevariable
- The variable
getInstance
public Concept getInstance(java.lang.String variable_name)
- Returns a variable from the local scope.
- Parameters:
variable_name
- The name of the wanted variable- Returns:
- the variable
isInstance
public boolean isInstance(java.lang.String instanceName)
isForcedInstance
public boolean isForcedInstance(java.lang.String instanceName)
getForcedType
public java.lang.String getForcedType(java.lang.String instanceName)
setForcedType
public void setForcedType(java.lang.String instanceName,
java.lang.String forcedType)
getPrevScope
public Scope getPrevScope()
- Returns the previous (upper in hierarchy) scope.
- Returns:
- The upper scope.
clone
public java.lang.Object clone()
- Overrides:
clone
in class java.lang.Object
"Copyright © 2001 Internet Multicasting Services & media.org. All Rights Reserved."