public class JTMSBeliefSetImpl extends LinkedList implements JTMSBeliefSet
Modifier and Type | Class and Description |
---|---|
static class |
JTMSBeliefSetImpl.MODE |
LinkedList.JavaUtilIterator<T extends LinkedListNode<T>>, LinkedList.LinkedListFastIterator, LinkedList.LinkedListIterator<T extends LinkedListNode<T>>
fastIterator
Constructor and Description |
---|
JTMSBeliefSetImpl(BeliefSystem beliefSystem,
InternalFactHandle rootHandle) |
Modifier and Type | Method and Description |
---|---|
void |
add(LinkedListNode node)
Add a
LinkedListNode to the list. |
void |
cancel(PropagationContext context)
This will remove all entries and do clean up, like retract FHs.
|
void |
clear(PropagationContext context)
This will remove all entries, but not do cleanup, the FH is most likely needed else where
|
BeliefSystem |
getBeliefSystem() |
InternalFactHandle |
getFactHandle() |
InternalFactHandle |
getNegativeFactHandle() |
InternalFactHandle |
getPositiveFactHandle() |
WorkingMemoryAction |
getWorkingMemoryAction() |
boolean |
isNegated() |
boolean |
isPositive() |
boolean |
isUndecided() |
void |
remove(LinkedListNode node)
Removes a
LinkedListNode from the list. |
void |
setNegativeFactHandle(InternalFactHandle negativeFactHandle) |
void |
setPositiveFactHandle(InternalFactHandle positiveFactHandle) |
void |
setWorkingMemoryAction(WorkingMemoryAction wmAction) |
addFirst, addLast, clear, equals, fastIterator, get, getFirst, getLast, hashCode, insertAfter, isEmpty, iterator, javaUtilIterator, readExternal, removeFirst, removeLast, size, writeExternal
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
getLast
public JTMSBeliefSetImpl(BeliefSystem beliefSystem, InternalFactHandle rootHandle)
public InternalFactHandle getPositiveFactHandle()
getPositiveFactHandle
in interface JTMSBeliefSet
public void setPositiveFactHandle(InternalFactHandle positiveFactHandle)
setPositiveFactHandle
in interface JTMSBeliefSet
public InternalFactHandle getNegativeFactHandle()
getNegativeFactHandle
in interface JTMSBeliefSet
public void setNegativeFactHandle(InternalFactHandle negativeFactHandle)
setNegativeFactHandle
in interface JTMSBeliefSet
public void add(LinkedListNode node)
LinkedList
LinkedListNode
to the list. If the LinkedList
is empty then the first and
last nodes are set to the added node.add
in interface BeliefSet
add
in class LinkedList
node
- The LinkedListNode
to be addedpublic void remove(LinkedListNode node)
LinkedList
LinkedListNode
from the list. This works by attach the previous reference to the child reference.
When the node to be removed is the first node it calls removeFirst()
. When the node to be removed is the last node
it calls removeLast()
.remove
in interface BeliefSet
remove
in class LinkedList
node
- The LinkedListNode
to be removed.public BeliefSystem getBeliefSystem()
getBeliefSystem
in interface BeliefSet
public InternalFactHandle getFactHandle()
getFactHandle
in interface BeliefSet
public boolean isNegated()
isNegated
in interface JTMSBeliefSet
public boolean isUndecided()
isUndecided
in interface JTMSBeliefSet
public boolean isPositive()
isPositive
in interface JTMSBeliefSet
public void cancel(PropagationContext context)
BeliefSet
public void clear(PropagationContext context)
BeliefSet
public void setWorkingMemoryAction(WorkingMemoryAction wmAction)
setWorkingMemoryAction
in interface BeliefSet
public WorkingMemoryAction getWorkingMemoryAction()
Copyright © 2001-2014 JBoss by Red Hat. All Rights Reserved.