Kernel Prolog with Fluent based Builtins

Package tarau.jinni

Interface Summary
IOPeer  
 

Class Summary
answer_source When called as answer_source(X,G,R), it builds a new clause and maps it to an AnswerSource LD-resolution interpreter which will return one answer at a time of the form "the(X)" using G as initial resolvent and "no" when no more answers are available.
arg arg(I,Term,X) unifies X with the I-the argument of functor T
at_key collects all matching terms in a (possibly empty) list
barToken  
BBoardEnumerator Generates an Enumeration view of the blackboard
BlackBoard This class implementes generic multiple tuples by key operations for use by the PrologBlackBoard class implementing Linda operations on Prolog terms.
Builtins This class contains a dictionary of all builtins i.e.
char_file_writer opens a writer which puts characters to a file one by one
CharReader Builds Jinni Fluents from Java Streams
chars_to_name converts a name to a list of chars
CharWriter Writer
Clause Datatype for a Prolog clause (H:-B) having a head H and a body b
clause_file_writer opens a writer which puts characters to a file one by one
ClauseReader Builds Jinni Fluents from Java Streams
ClauseWriter Writer
collect Collects a reference to or the content of a Sink
commaToken  
compute Performs simple arithmetic operations like compute('+',1,2,Result)
Conj  
Cons List Constructor.
Const Symbolic constant, of arity 0.
ConstBuiltin Template for builtins of arity 0
constToken  
consult consults a file of clauses while adding clauses to existing predicate definitions
Copier Term Copier agent.
ctime returns the real time spent up to now
DataBase Implements a Term and Clause objects based blackboard (database).
db_add Puts a term on the local blackboard
db_collect collects all matching terms in a (possibly empty) list
db_remove removes a matching term if available, fails otherwise
db_source Maps a DataBase to a Source enumerating its elements
db_to_string lists all the local blackboard to a string (Linda terms + clauses)
def def(Var,Val) Initializes a Multi_Variable Var to a value Val.
discharge Flushes to a Sink the content of a Source Fluent
eocToken  
eofToken  
fail_ Always fails
file_char_reader opens a reader returning the content of a file char by char
file_clause_reader opens a reader returning clauses from a file
Fluent A Fluent is a Jinni Object which has its own state, subject to changes over time.
Fun Implements compound terms
FunBuiltin Template for builtins of arity >0
funToken  
get generic Source advancement step, similar to an iterator's nextElement operation, gets one element from the Source
get_arity gets an arity for any term: n>0 for f(A1,...,An) 0 for a constant like a -1 for a variable like X -2 for an integer like 13 -3 for real like 3.14 -4 for a wrapped JavaObject;
get_default_db gets default database
get_persistent Gets the yes/no persistentcy value of a Fluent.
get_stdin get the standard output (a reader)
get_stdout get standard output (a writer)
halt does its best to halt the program:-) to be thoroughly tested with Applets
HashDict General purpose dictionary
iffToken  
Init Initializes Jinni.
Int  
integer_source Creates an Integer Source which advances at most Fuel (infinite if Fule==0) Steps computing each time x:= a*x+b.
IntegerSource creates a source of integers based on x=a*x+b formula
intToken  
IO  
is_builtin checks if something is a builtin
JavaObject A JavaObject is a Jinni SystemObject with a val slot which containing a wrapped Java object
JavaSource Builds Jinni Iterators from Java Sequences and Iterator type classes
lazy_head returns the first element of a lazy list
lazy_tail returns the tail if a lazy list after making it grow, if possible
LazyList Lazy List: produces Cons-like sequences, based on a Source.
lbraToken  
Lexer Lexicographic analyser reading from a stream
list_source maps a List to a Source
ListSource Builds an iterator from a list
lparToken  
merge_sources Merges all Sources contained in a List into one Source.
MultiVar Varable-like entity, with a multiple values, in stack order.
name_to_chars converts a name to a list of chars
new_db creates new database
new_fun new_fun(F,N,T) creates a term T based on functor F with arity N and new free varables as arguments
Nil Special constant terminating a list
Nonvar Part of the Prolog Term hierarchy
Num Abstract numeric class, part of the Term hierarchy
numbervars returns a copy of a Term with variables uniformly replaced with constants
Parser Simplified Prolog parser: Synatax supported: a0:-a1,...,an.
pred_to_string Returns a representation of predicate as a string constant
Prog Basic toplevel Prolog Engine.
PseudoVar Special constants, used to Name variables
put generic Sink advancement step, sends one element to the Sink
Queue Generic dynamic Queeue with (amortized) O(1) enq/deq (add and remove) operations
rbraToken  
Real Part of the Term hierarchy, implementing double float point numbers.
realToken  
reconsult reconsults a file of clauses while overwriting old predicate definitions
reconsult_again shorthand for reconsulting the last file
rparToken  
set set(Var,Val) Sets a Multi_Variable Var to a value Val.
set_max_answers sets max answer counter for toplevel query if == 0, it will prompt the user for more answers if > 0 it will not print more than IO.maxAnswers if < 0 it will print them out all
set_persistent set_persistent(Fluent,yes) makes a Fluent persistent - i.e.
set_trace controls trace levels for debugging
Sink  
Source  
source_lazy_list Converts Source into a Lazy List which will memorize its elements as it grows.
source_list Explores a finite iterator and return its successive values as a list.
source_loop Builds a Looping Source from a Source.
source_term Builds a Source from a Term
SourceLoop An Infinite Source.
SourceMerger Merges a List of Sources into a new Source which (fairly) iterates over them breadth first.
split_source Splits a (finite) Source in two new ones which inherit the current state of the parent.
stack_dump Dumps the current Java Stack
stop frees a Fluent's resources and ensures it cannot produce/consume any new values
string_char_reader Creates a char reader from a String.
string_clause_reader Creates a clause reader from a String.
StringSink Builds Jinni Fluents from Java Streams
stringToken  
system Calls an external program
SystemObject A SystemObject is a Jinni Nonvar with system assigned name
Term Top element of the Prolog term hierarchy.
term_collector Builds a TermCollector Sink which accumulates Terms with put/1 and the return them with collect/1
term_source maps a Term to a Source
term_string_collector Builds a StringSink which concatenates String representations of Terms with put/1 and the return their concatenation with collect/1
TermCollector Builds Jinni Fluents from Java Streams
TermSource Maps a Term to an Source for iterating over its arguments
Token  
Trail Implements a stack of undo actions for backtracking, and in particular, resetting a Var's val fiels to unbound (i.e.
true_ Always succeeds
Unfolder For a given clause g= A0:-,A1,A2...,An, used as resolvent iterates over its possible unfoldings (LD-resolution steps) with clauses of the form B0:-B1,...,Bm in the default database.
unfolder_source Builds a new clause H:-B and maps it to an iterator
val val(Var,Val) gets the value Val of Multi_Variable Var.
Var Part of the Term hierarchy implmenting logical variables.
VarNumberer Used in implementing uniform replacement of variables with new constants.
varToken  
 

Exception Summary
ParserException  
 


Kernel Prolog with Fluent based Builtins