Class Is
java.lang.Object
org.projog.core.predicate.AbstractSingleResultPredicate
org.projog.core.predicate.builtin.compare.Is
- All Implemented Interfaces:
KnowledgeBaseConsumer, PredicateFactory, PreprocessablePredicateFactory
public final class Is
extends AbstractSingleResultPredicate
implements PreprocessablePredicateFactory
X is Y - evaluate arithmetic expression.
Firstly structure Y is evaluated as an arithmetic expression to give a number. Secondly an attempt is
made to match the number to X. The goal succeeds or fails based on the match.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static final classprivate static final class -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class AbstractSingleResultPredicate
evaluate, evaluate, evaluate, evaluate, evaluate, getArithmeticOperators, getFileHandles, getKnowledgeBase, getOperands, getPredicate, getPredicates, getProjogListeners, getSpyPoints, getTermFormatter, init, isRetryable, setKnowledgeBaseMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface PredicateFactory
getPredicate, isAlwaysCutOnBacktrack, isRetryable
-
Constructor Details
-
Is
public Is()
-
-
Method Details
-
evaluate
- Overrides:
evaluatein classAbstractSingleResultPredicate
-
preprocess
- Specified by:
preprocessin interfacePreprocessablePredicateFactory
-