|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object | +--com.sri.oaa2.icl.IclDb
DataBase class for OAA V2.0
| Constructor Summary | |
IclDb()
IclDb() |
|
| Method Summary | |
IclTerm |
asserta(IclTerm inTerm)
Asserts a new term at the beginning of the table |
IclTerm |
assertz(IclTerm inTerm)
Asserts a new term at the end of the table |
boolean |
db_Assert(IclTerm term,
IclTerm params)
Asserts a new term in the database. |
boolean |
db_Contains(IclTerm term)
Checks if a term is stored in the database. |
boolean |
db_getRef(IclTerm inTerm,
IclList inParams,
IclList references)
Fills the incoming list with all internal references of the terms that unify with the incoming one. |
void |
db_PrintDB()
Writes out the entire database |
boolean |
db_Replace(IclTerm newTerm,
IclTerm oldTerm,
IclTerm params)
Replaces an ICL term from the database by another one. |
boolean |
db_Retract(IclTerm term,
IclTerm params)
db_Retract(IclTerm term, IclTerm params) |
boolean |
db_Retract(IclTerm term,
IclTerm params,
boolean inDebug)
Removes an ICL term from the database. |
boolean |
db_Solve(IclTerm term,
IclList params,
IclList answer)
db_Solve(IclTerm term, IclList params, IclList answer) |
boolean |
db_Solve(IclTerm term,
IclList params,
IclList answer,
boolean getUniqueReferences)
Searches the database for matches to term. |
boolean |
db_SolveDebug(IclTerm term,
IclList params,
IclList answer,
boolean getUniqueReferences)
|
boolean |
erase(IclTerm inRef)
Erases the term that is bound to the incoming reference |
boolean |
replace_all(IclTerm newTerm,
IclTerm oldTerm)
Replaces all occurences that match with oldTerm by newTerm |
boolean |
retract_all(IclTerm inTerm)
Removes all terms that unify with inTerm |
boolean |
retract(IclTerm inTerm)
Removes the first term that unifies with inTerm |
boolean |
retract(IclTerm inTerm,
boolean inDebug)
|
java.lang.String |
toString()
toString() |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public IclDb()
| Method Detail |
public boolean db_Assert(IclTerm term,
IclTerm params)
parameters may include "at_beginning" (boolean parameter)
db_Assert(my_pred(a,B),[at_begining(true)])
public boolean db_Solve(IclTerm term,
IclList params,
IclList answer,
boolean getUniqueReferences)
Parameters may include "solution_limit" (integer parameter)
Example: db_Solve(my_pred(a,B),[solution_limit(10)])
public boolean db_SolveDebug(IclTerm term,
IclList params,
IclList answer,
boolean getUniqueReferences)
public boolean db_Solve(IclTerm term,
IclList params,
IclList answer)
public boolean db_Contains(IclTerm term)
public boolean db_Retract(IclTerm term,
IclTerm params,
boolean inDebug)
examples : db_Retract(my_pred(a,B),[do_all(true)])
public boolean db_Replace(IclTerm newTerm,
IclTerm oldTerm,
IclTerm params)
examples : db_Replace(old_pred(a,B), new_pred(X), [do_all(true)])
public boolean db_Retract(IclTerm term,
IclTerm params)
public void db_PrintDB()
public java.lang.String toString()
toString in class java.lang.Objectpublic IclTerm asserta(IclTerm inTerm)
public IclTerm assertz(IclTerm inTerm)
public boolean retract(IclTerm inTerm)
public boolean retract(IclTerm inTerm,
boolean inDebug)
public boolean retract_all(IclTerm inTerm)
public boolean replace_all(IclTerm newTerm,
IclTerm oldTerm)
public boolean db_getRef(IclTerm inTerm,
IclList inParams,
IclList references)
Note : Based on db_Solve Searches the database for matches to term and returns the corresponding unique reference remarks: parameters may include "solution_limit" (integer parameter) returns the answer as an IclTerm, null if fail. db_getRef(my_pred(a,B),[solution_limit(10)])
public boolean erase(IclTerm inRef)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||