Package jason.asSemantics
Class Unifier
java.lang.Object
jason.asSemantics.Unifier
- All Implemented Interfaces:
ToDOM
,Serializable
,Cloneable
,Iterable<VarTerm>
- See Also:
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
void
void
clear()
clone()
void
add all unifications from uboolean
gets the value for a Var, if it is unified with another var, gets this other's valuegets the value for a Var, if it is unified with another var, gets this other's valueget as XMLgetVarFromValue
(Term vl) int
hashCode()
iterator()
void
changes the implementation of Var/Value mapping -- should be used carefullyint
size()
toString()
boolean
this version of unifies undo the variables' mapping if the unification fails.boolean
boolean
unifiesNoUndo
(Term t1g, Term t2g) this version of unifies does not undo the variables' mapping in case of failure.boolean
unifiesNoUndo
(Trigger te1, Trigger te2) protected boolean
unifyTerms
(Term t1g, Term t2g) Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Field Details
-
function
-
-
Constructor Details
-
Unifier
public Unifier()
-
-
Method Details
-
get
gets the value for a Var, if it is unified with another var, gets this other's value -
remove
-
iterator
-
get
gets the value for a Var, if it is unified with another var, gets this other's value -
getVarFromValue
-
unifies
-
unifiesNoUndo
-
unifies
this version of unifies undo the variables' mapping if the unification fails. E.g. u.unifier( a(X,10), a(1,1) ); does not change u, i.e., u = {} -
unifiesNoUndo
this version of unifies does not undo the variables' mapping in case of failure. It is however faster than the version with undo. E.g. u.unifier( a(X,10), a(1,1) ); fails, but changes u to {X = 10} -
unifyTerms
-
deref
-
bind
-
bind
-
clear
public void clear() -
toString
-
getAsTerm
-
size
public int size() -
compose
add all unifications from u -
clone
-
hashCode
public int hashCode() -
equals
-
getAsDOM
get as XML -
setMap
changes the implementation of Var/Value mapping -- should be used carefully
-