net.ontopia.topicmaps.query.parser
Class PredicateClause

java.lang.Object
  extended by net.ontopia.topicmaps.query.parser.AbstractClause
      extended by net.ontopia.topicmaps.query.parser.PredicateClause
Direct Known Subclasses:
QueryOptimizer.PumpClause

public class PredicateClause
extends AbstractClause

INTERNAL: Used to represent clauses in tolog queries.


Field Summary
protected  java.util.List arguments
           
protected  PredicateIF predicate
           
 
Constructor Summary
PredicateClause()
           
PredicateClause(PredicateIF predicate)
           
PredicateClause(PredicateIF predicate, java.util.List arguments)
           
 
Method Summary
 void addArgument(java.lang.Object object)
           
 java.util.Collection getAllLiterals()
          INTERNAL: Returns all the literals used by this clause as parameters.
 java.util.Collection getAllVariables()
          INTERNAL: Returns all the variables bound by this clause when it is satisfied.
 java.util.List getArguments()
          INTERNAL: Returns the arguments of this clause.
 PredicateIF getPredicate()
           
 PredicateClause getReplacement()
          INTERNAL: Returns an equivalent, but more efficient, clause, if such a clause is possible; if not returns itself.
 void setPredicate(PredicateIF predicate)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

predicate

protected PredicateIF predicate

arguments

protected java.util.List arguments
Constructor Detail

PredicateClause

public PredicateClause()

PredicateClause

public PredicateClause(PredicateIF predicate)

PredicateClause

public PredicateClause(PredicateIF predicate,
                       java.util.List arguments)
Method Detail

getArguments

public java.util.List getArguments()
Description copied from class: AbstractClause
INTERNAL: Returns the arguments of this clause. For OrClause this is the list of all arguments to all the subclauses in the OrClause. Likewise for NotClause.

Specified by:
getArguments in class AbstractClause

getPredicate

public PredicateIF getPredicate()

setPredicate

public void setPredicate(PredicateIF predicate)

addArgument

public void addArgument(java.lang.Object object)

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

getAllVariables

public java.util.Collection getAllVariables()
Description copied from class: AbstractClause
INTERNAL: Returns all the variables bound by this clause when it is satisfied.

Specified by:
getAllVariables in class AbstractClause

getAllLiterals

public java.util.Collection getAllLiterals()
Description copied from class: AbstractClause
INTERNAL: Returns all the literals used by this clause as parameters. (Literals in the second half of pair arguments are ignored.)

Specified by:
getAllLiterals in class AbstractClause

getReplacement

public PredicateClause getReplacement()
INTERNAL: Returns an equivalent, but more efficient, clause, if such a clause is possible; if not returns itself. Used by the optimizer to optimize queries.



Copyright © 2000-2012 Ontopia.