All Packages Class Hierarchy This Package Previous Next Index
Class PrologParse.ClauseList
java.lang.Object
|
+----java.util.Vector
|
+----PrologParse.ClauseList
- public class ClauseList
- extends Vector
A Class representing a Vector of Clauses.
The ClassList also keeps a Hashtable of Vectors that point
to the definitions of any defined predicates, accessed by the
appropriate predicate symbols.
- See Also:
- Clause, PrologParser
-
ClauseList()
- Basic constructor.
-
addDefinition(String)
- Add an empty definition to the definition Hashtable.
-
addElement(Clause)
- Add a Clause to the ClauseList.
-
definition(String)
-
-
definitions()
-
-
listDefinition(String, List)
- Fills the given GUI List with the String representaion
of the definition of the given predicate symbol.
-
removeAll()
- Clears the ClauseList.
-
removeDefinition(String)
- Remove the entire definition of the given predicate symbol.
-
removeDefinitionAt(String, int)
- Remove the clause at a specific position in the
Vector of clauses that defines the given predicate symbol.
-
removeElement(Clause)
- Remove a Clause from the ClauseList.
ClauseList
public ClauseList()
- Basic constructor.
Initializes the definitions hashtable.
addElement
public final void addElement(Clause cl)
- Add a Clause to the ClauseList.
Also updates the definitions table.
- Parameters:
- cl - A Clause.
removeElement
public final void removeElement(Clause cl)
- Remove a Clause from the ClauseList.
Also updates the definitions table.
- Parameters:
- cl - A Clause.
removeAll
public final void removeAll()
- Clears the ClauseList.
Also clears the definitions table.
definitions
public final Hashtable definitions()
- Returns:
- the Hashtable of definitions in this ClauseList.
definition
public final Vector definition(String sym)
- Parameters:
- sym - A predicate symbol.
- Returns:
- the definition of the given predicate symbol.
listDefinition
public final void listDefinition(String sym,
List list)
- Fills the given GUI List with the String representaion
of the definition of the given predicate symbol.
- Parameters:
- sym - A predicate symbol.
- list - A java.awt.List.
- See Also:
- List
addDefinition
public final void addDefinition(String sym)
- Add an empty definition to the definition Hashtable.
- Parameters:
- sym - A predicate symbol.
removeDefinitionAt
public final void removeDefinitionAt(String sym,
int pos)
- Remove the clause at a specific position in the
Vector of clauses that defines the given predicate symbol.
- Parameters:
- sym - A predicate symbol.
- pos - The position in the Vector.
removeDefinition
public final void removeDefinition(String sym)
- Remove the entire definition of the given predicate symbol.
- Parameters:
- sym - A predicate symbol.
All Packages Class Hierarchy This Package Previous Next Index