|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object edu.isi.stella.Stella_Object edu.isi.stella.StandardObject edu.isi.stella.AbstractIterator edu.isi.stella.Iterator edu.isi.powerloom.logic.QueryIterator
public class QueryIterator
A query iterator points to a query environment representing the initial or intermediate state of a query. The iterator's 'value' is a vector representing a satisfying set bindings of the query's output variables. Each call to the iterator writes a new set of bindings into the vector.
Fields inherited from class edu.isi.stella.Iterator |
---|
value |
Fields inherited from class edu.isi.stella.AbstractIterator |
---|
firstIterationP |
Constructor Summary | |
---|---|
QueryIterator()
|
Method Summary | |
---|---|
static Stella_Object |
accessQueryIteratorSlotValue(QueryIterator self,
Symbol slotname,
Stella_Object value,
boolean setvalueP)
|
BooleanWrapper |
badP()
|
List |
bestGoalSequence()
|
Cons |
consify()
Generate all solutions for the query self, and collect them into a cons list of result tuples. |
Cons |
consifyCurrentSolutions()
Collect the current solutions of self into a cons list
of result tuples. |
static Cons |
consifyQuery(QueryIterator self)
|
static void |
cutoffSimilarWhynotProofs(QueryIterator query)
|
boolean |
deletedP()
Default deletedP method which always returns FALSE. |
boolean |
deletedPSetter(boolean value)
|
static QueryIterator |
deriveJustifiedPartialQuery(QueryIterator query)
|
static List |
deriveQueryJustifications(QueryIterator query,
Stella_Object options,
int solutionindex,
int maxjustifications)
|
static boolean |
executeBackwardChainingProofP(QueryIterator query)
|
void |
free()
Default method. |
static void |
freeCachedQuery(QueryIterator query,
Symbol queryid)
|
static void |
freeQueryIterator(QueryIterator self)
|
static List |
getQueryJustifications(QueryIterator query,
int solutionindex,
int maxjustifications,
boolean createP)
|
static List |
getWhynotJustifications(QueryIterator query,
java.lang.String label,
KeyValueList mapping)
Programmer's interface to WHYNOT function. |
static void |
initializePartialQuery(QueryIterator query)
|
static QueryIterator |
initializeQueryIterator(QueryIterator queryiterator,
Description description,
Vector outsidebindings,
java.lang.String debugid)
|
List |
listify()
Just like QUERY_ITERATORDconsify but return a LIST instead. |
static PartialMatchFrame |
makePartialMatchFrame(QueryIterator query)
|
static QueryIterator |
newQueryIterator()
|
boolean |
nextP()
|
Surrogate |
primaryType()
Returns the primary type of self . |
void |
printObject(java.io.PrintStream stream)
|
static void |
printQueryIterator(QueryIterator self,
java.io.PrintStream stream)
|
static void |
printQueryIteratorOrnately(QueryIterator self,
java.io.PrintStream stream)
|
static void |
printQueryIteratorReadably(QueryIterator self,
java.io.PrintStream stream)
|
static void |
printQueryIteratorSolutionOrnately(QueryIterator self,
QuerySolution solution,
int solutionnumber,
java.io.PrintStream stream)
|
static void |
processQueryOptions(QueryIterator query,
Stella_Object options)
|
Description |
queryDescription()
|
boolean |
queryIsPartialP()
|
boolean |
queryIsTrueFalseP()
|
Proposition |
queryProposition()
|
boolean |
querySucceededP()
|
void |
reset()
|
List |
residueGoals()
|
static double |
returnPartialTruth(QueryIterator query,
boolean topP)
|
static BooleanWrapper |
runYesOrNoQueryP(QueryIterator query)
|
static void |
sortSolutionsByScore(QueryIterator query)
|
static void |
traceSolution(QueryIterator self,
QuerySolution solution,
int solutionnumber)
|
static boolean |
tryToDefeatLastAnswerP(QueryIterator self,
java.lang.Object[] MV_returnarray)
|
static Cons |
updatePropositionsFromQuery(QueryIterator query,
Description description,
Module module,
Keyword updatemode,
boolean recordjustificationsP)
|
Methods inherited from class edu.isi.stella.Iterator |
---|
advance, concatenate, emptyP, memberP, pop, printClassList |
Methods inherited from class edu.isi.stella.AbstractIterator |
---|
accessAbstractIteratorSlotValue, allocateIterator, length |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public Vector externalVariables
public boolean exhaustedP
public PropertyList options
public QuerySolutionTable solutions
public java.lang.String debugId
public Context queryContext
public ControlFrame baseControlFrame
public ControlFrame currentControlFrame
public PatternRecord currentPatternRecord
public ParallelThread currentParallelThread
public ControlFramePriorityQueue controlFramePriorityQueue
public boolean augmentedGoalCacheP
public List activeGoalCaches
public boolean triggeredDepthCutoffP
public boolean failedToFindDuplicateSubgoalP
public boolean foundAtLeastOneSolutionP
public int timestamp
public PartialMatchFrame partialMatchStrategy
public InferenceLevel inferenceLevel
public int currentDepthCutoff
public int maximumDepth
public double allottedTime
public int allottedClockTicks
public int currentClockTicks
public boolean timeoutP
public boolean depthCutoffsP
public KeyValueList dynamicSlots
Constructor Detail |
---|
public QueryIterator()
Method Detail |
---|
public static QueryIterator newQueryIterator()
public static List getWhynotJustifications(QueryIterator query, java.lang.String label, KeyValueList mapping)
query
failed, or, if label
was supplied as non-NULL,
lookup its justification relative to mapping
and return the result.
query
- label
- mapping
-
public static QueryIterator deriveJustifiedPartialQuery(QueryIterator query)
public static void cutoffSimilarWhynotProofs(QueryIterator query)
public static List deriveQueryJustifications(QueryIterator query, Stella_Object options, int solutionindex, int maxjustifications)
public static List getQueryJustifications(QueryIterator query, int solutionindex, int maxjustifications, boolean createP)
public static double returnPartialTruth(QueryIterator query, boolean topP)
public static void sortSolutionsByScore(QueryIterator query)
public static void initializePartialQuery(QueryIterator query)
public static PartialMatchFrame makePartialMatchFrame(QueryIterator query)
public static Cons updatePropositionsFromQuery(QueryIterator query, Description description, Module module, Keyword updatemode, boolean recordjustificationsP)
public static void freeCachedQuery(QueryIterator query, Symbol queryid)
public List listify()
QUERY_ITERATORDconsify
but return a LIST instead.
listify
in class Iterator
public static Cons consifyQuery(QueryIterator self)
public Cons consify()
CSINGLETONSP_TRUE
, collect a list of atoms rather than a
list of lists for tuples of arity=1.
consify
in class Iterator
public Cons consifyCurrentSolutions()
self
into a cons list
of result tuples. If CSINGLETONSP_TRUE
, collect a list of atoms rather than a
list of lists for tuples of arity=1.
public static BooleanWrapper runYesOrNoQueryP(QueryIterator query)
public static void processQueryOptions(QueryIterator query, Stella_Object options)
public void reset()
public static boolean tryToDefeatLastAnswerP(QueryIterator self, java.lang.Object[] MV_returnarray)
public boolean nextP()
nextP
in class AbstractIterator
public boolean querySucceededP()
public boolean queryIsPartialP()
public boolean queryIsTrueFalseP()
public Description queryDescription()
public Proposition queryProposition()
public static QueryIterator initializeQueryIterator(QueryIterator queryiterator, Description description, Vector outsidebindings, java.lang.String debugid)
public static void freeQueryIterator(QueryIterator self)
public void free()
Stella_Object
self
.
free
in class Stella_Object
public static void printQueryIteratorReadably(QueryIterator self, java.io.PrintStream stream)
public static void traceSolution(QueryIterator self, QuerySolution solution, int solutionnumber)
public static void printQueryIteratorSolutionOrnately(QueryIterator self, QuerySolution solution, int solutionnumber, java.io.PrintStream stream)
public static void printQueryIteratorOrnately(QueryIterator self, java.io.PrintStream stream)
public static void printQueryIterator(QueryIterator self, java.io.PrintStream stream)
public static boolean executeBackwardChainingProofP(QueryIterator query)
public void printObject(java.io.PrintStream stream)
printObject
in class Stella_Object
public boolean deletedPSetter(boolean value)
public boolean deletedP()
Stella_Object
deletedP
method which always returns FALSE. Objects
that inherit DYNAMIC-SLOTS-MIXIN also inherit the dynamically-allocated slot
deletedObjectP
which is read/writable with specializations of this method.
deletedP
in class Stella_Object
public static Stella_Object accessQueryIteratorSlotValue(QueryIterator self, Symbol slotname, Stella_Object value, boolean setvalueP)
public BooleanWrapper badP()
public List bestGoalSequence()
public List residueGoals()
public Surrogate primaryType()
Stella_Object
self
.
Gets defined automatically for every non-abstract subclass of OBJECT.
primaryType
in class Stella_Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |