Class Compare
- java.lang.Object
-
- org.projog.core.predicate.AbstractSingleResultPredicate
-
- org.projog.core.predicate.builtin.compare.Compare
-
- All Implemented Interfaces:
KnowledgeBaseConsumer,PredicateFactory
public final class Compare extends AbstractSingleResultPredicate
compare(X,Y,Z)- compares arguments.Compares the second and third arguments.
- If second is greater than third then attempts to unify first argument with
> - If second is less than third then attempts to unify first argument with
< - If second is equal to third then attempts to unify first argument with
=
-
-
Constructor Summary
Constructors Constructor Description Compare()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected booleanevaluate(Term result, Term t1, Term t2)-
Methods inherited from class org.projog.core.predicate.AbstractSingleResultPredicate
evaluate, evaluate, evaluate, evaluate, evaluate, getArithmeticOperators, getFileHandles, getKnowledgeBase, getOperands, getPredicate, getPredicates, getProjogListeners, getSpyPoints, getTermFormatter, init, isRetryable, setKnowledgeBase
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.projog.core.predicate.PredicateFactory
isAlwaysCutOnBacktrack
-
-
-
-
Method Detail
-
evaluate
protected boolean evaluate(Term result, Term t1, Term t2)
- Overrides:
evaluatein classAbstractSingleResultPredicate
-
-