public class RelExpr extends BinaryStructure implements LogicalFormula
Literal =.. [functor, list of terms, list of annots]
Examples:
Modifier and Type | Class and Description |
---|---|
static class |
RelExpr.RelationalOp |
emptyTermArray, emptyTermList
LFalse, LNeg, LPos, LTrue, predicateIndicatorCache
hashCodeCache, srcInfo
Constructor and Description |
---|
RelExpr(Term t1,
RelExpr.RelationalOp oper,
Term t2) |
Modifier and Type | Method and Description |
---|---|
Term |
capply(Unifier u)
clone and applies together (and faster than clone and then apply)
|
LogicalFormula |
clone()
make a hard copy of the terms
|
org.w3c.dom.Element |
getAsDOM(org.w3c.dom.Document document)
get as XML
|
RelExpr.RelationalOp |
getOp()
gets the Operation of this Expression
|
java.util.Iterator<Unifier> |
logicalConsequence(Agent ag,
Unifier un)
logicalConsequence checks whether one particular predicate
is a logical consequence of the belief base.
|
static LogicalFormula |
parseExpr(java.lang.String sExpr)
returns some LogicalFormula that can be evaluated
|
getLHS, getRHS, toString
addTerm, addTerms, addTerms, calcHashCode, compareTo, countVars, delTerm, equals, getArity, getSingletonVars, getTerm, getTerms, getTermsSize, hasTerm, hasVar, isAtom, isGround, isStructure, isUnary, makeTermsAnnon, makeVarsAnnon, makeVarsAnnon, parse, setTerm, setTerms, subsumes, varToReplace
getFunctor
addAnnot, addAnnots, addAnnots, addSource, canBeAddedInBB, clearAnnots, copy, delAnnot, delAnnots, delSource, delSources, equalsAsStructure, forceFullLiteralImpl, getAnnot, getAnnots, getAnnots, getAsListOfTerms, getPredicateIndicator, getSources, getTermsArray, hasAnnot, hasAnnot, hasSource, hasSource, hasSubsetAnnot, hasSubsetAnnot, importAnnots, isLiteral, negated, newFromListOfTerms, parseLiteral, setAnnots, setNegated
getCyclicVar, getErrorMsg, getSrcInfo, hashCode, isArithExpr, isCyclicTerm, isInternalAction, isList, isNumeric, isPlanBody, isPred, isRule, isString, isUnnamedVar, isVar, resetHashCodeCache, setSrcInfo
finalize, getClass, notify, notifyAll, wait, wait, wait
countVars, equals, getCyclicVar, getSrcInfo, hasVar, isArithExpr, isAtom, isCyclicTerm, isGround, isInternalAction, isList, isLiteral, isNumeric, isPlanBody, isPred, isRule, isString, isStructure, isUnnamedVar, isVar, setSrcInfo, subsumes
public RelExpr(Term t1, RelExpr.RelationalOp oper, Term t2)
public java.util.Iterator<Unifier> logicalConsequence(Agent ag, Unifier un)
Literal
logicalConsequence
in interface LogicalFormula
logicalConsequence
in class Literal
public static LogicalFormula parseExpr(java.lang.String sExpr)
public Term capply(Unifier u)
Term
public LogicalFormula clone()
public RelExpr.RelationalOp getOp()
public org.w3c.dom.Element getAsDOM(org.w3c.dom.Document document)
getAsDOM
in interface ToDOM
getAsDOM
in class BinaryStructure