|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.cs.ai.kreator.logic.VariableFactory
public class VariableFactory
An instance of this class is responsible for maintaining a unique object status of variables within the scope of variables, e.g. within clauses. Every such scope should provide for an instance of VariableFactory.
Field Summary | |
---|---|
static org.apache.log4j.Logger |
LOG
|
Constructor Summary | |
---|---|
VariableFactory()
Default constructor. |
Method Summary | |
---|---|
java.lang.Object |
clone()
Deprecated. |
boolean |
contains(Variable var)
Checks if the given variables is contained in this factory. |
boolean |
containsAll(java.util.Collection<Variable> objects)
Checks if all elements of the given list are contained in this language. |
boolean |
containsVariable(java.lang.String varName)
Checks if a Variable with the given name is contained in this factory. |
boolean |
containsVariable(java.lang.String variableName,
Sort sort)
Checks if a variable with the given name and sort is contained in this language. |
java.util.List<Variable> |
getAllVariables()
Returns a list of all variables in this factory. |
Variable |
getExistingVariable(java.lang.String varName)
Return the variable with the given name if it exists, else return null |
boolean |
isValid(java.util.Collection<Literal> literals)
Checks if the variables of each Literal in the collection are members of this VariableFactory |
boolean |
isValid(Literal lit)
Checks if the variables of a given literal are members of this VariableFactory |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final org.apache.log4j.Logger LOG
Constructor Detail |
---|
public VariableFactory()
Method Detail |
---|
public java.util.List<Variable> getAllVariables()
public Variable getExistingVariable(java.lang.String varName)
varName
- the name of the requested variable
public boolean containsVariable(java.lang.String varName)
varName
- the requested variable name
public boolean containsVariable(java.lang.String variableName, Sort sort)
variableName
- sort
-
public boolean contains(Variable var)
variable
- a variable.
public boolean containsAll(java.util.Collection<Variable> objects)
objects
- a list of objects.
public boolean isValid(Literal lit)
VariableFactory
lit
- the literal
public boolean isValid(java.util.Collection<Literal> literals)
VariableFactory
literals
-
@Deprecated public java.lang.Object clone()
clone
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |