|
JACK 5.4 Application Interface | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectaos.jack.jak.util.Watchable
aos.jack.jak.beliefset.BeliefSet
aos.jack.jak.beliefset.ClosedWorld
Base class for closed world relations. Closed World relations only store true facts. Anything not stored is assumed to be false.
| Constructor Summary | |
ClosedWorld()
|
|
| Method Summary | |
void |
addfact(Tuple t,
BeliefState d)
Callback invoked when a fact is asserted. |
void |
assertTuple(Tuple t,
BeliefState d)
Asserts a fact. |
void |
delfact(Tuple t,
BeliefState d)
Callback invoked when a fact is retracted. |
void |
endfact(Tuple t,
BeliefState d,
BeliefState newst)
Callback invoked when a fact retraction changes the database. |
protected void |
fixSizes()
|
void |
moddb()
Callback invoked when a fact assertion or retraction changes the database. |
void |
modfact(Tuple newf,
BeliefState d,
Tuple oldtrue,
Tuple oldfalse)
Callback invoked when a fact assertion changes the database. |
void |
newfact(Tuple t,
BeliefState d,
BeliefState prevst)
Callback invoked when a fact assertion changes the database. |
int |
nFacts()
Returns the number of positive facts stored. |
int |
read(aos.apib.InStream is)
Method to read facts from an InStream. |
void |
reset()
Reinitialize the beliefset to an empty state. |
void |
retractTuple(Tuple t,
BeliefState d)
Retracts a fact. |
int |
write(aos.apib.OutStream s)
Method to write facts to an OutStream. |
| Methods inherited from class aos.jack.jak.beliefset.BeliefSet |
dump, getArrSize, getHandler, getTuple, invokeAssertListener, invokeRetractListener, newArr, nIndexes, postEvent, read, read, registerOpListener, requireNextOpNotification, resetNextOpNotification, toString, write, write |
| Methods inherited from class aos.jack.jak.util.Watchable |
addObserver, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public ClosedWorld()
| Method Detail |
public int nFacts()
nFacts in class BeliefSet
public void addfact(Tuple t,
BeliefState d)
public void newfact(Tuple t,
BeliefState d,
BeliefState prevst)
public void endfact(Tuple t,
BeliefState d,
BeliefState newst)
public void delfact(Tuple t,
BeliefState d)
public void modfact(Tuple newf,
BeliefState d,
Tuple oldtrue,
Tuple oldfalse)
public void moddb()
public void reset()
public void assertTuple(Tuple t,
BeliefState d)
assertTuple in class BeliefSet
public void retractTuple(Tuple t,
BeliefState d)
retractTuple in class BeliefSetprotected void fixSizes()
public int read(aos.apib.InStream is)
<TupleTable
:tuples (
... // individual tuples
)
>
Individual tuple
formats are derived from the actual tuples,
and are generated by the JACK compiler.
NOTE: This does not go throughb assertTuple. This has 2 major
affects
+ no user notification occurs (Possibly ok)
+ no key constraint management occurs (BUG) which can result
in an inconsistent state
read in class BeliefSetis - The Jacob Stream to read from.
public int write(aos.apib.OutStream s)
write in class BeliefSets - the OutStream to write to.
|
JACK 5.4 Application Interface | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
US Government Restricted Rights
The JACK Modules and relevant Software Material have been developed entirely at private expense and are accordingly provided with RESTRICTED RIGHTS. Use, duplication, or disclosure by Government is subject to restrictions as set forth in subparagraph (c)(1)(ii) of DFARS 252.227-7013 or subparagraph (c)(1) and (2) of the Commercial Computer Software Restricted Rights and 48 CFR 52.2270-19, as applicable.