pengines

Prolog files

pengines.pl  -- Pengines: Web Logic Programming Made EasyShow source
add_error_details/3Add format error code and location information to an error.Source
authentication_hook/3This hook is called from the =/pengine/create= HTTP handler to discover whether the server is accessed by an authorized user.Source
current_pengine_application/1True when Application is a currently defined application.Source
event_to_json/3Hook that translates a Pengine event structure into a term suitable for reply_json/1, according to the language specification Lang.Source
not_sandboxed/2This hook is called to see whether the Pengine must be executed in a protected environment.Source
output/2Hook to handle pengine_output/1 from the remote pengine.Source
pengine_abort/1Aborts the running query.Source
pengine_application/1Directive that must be used to declare a pengine application module.Source
pengine_ask/3Asks pengine NameOrID a query Query.Source
pengine_create/1Creates a new pengine.Source
pengine_debug/2Create a message using format/3 from Format and Args and send this to the client.Source
pengine_destroy/1Destroys the pengine NameOrID.Source
pengine_destroy/2Destroys the pengine NameOrID.Source
pengine_done/0Called from the pengine thread at_exit option.Source
pengine_event/2Examines the pengine's event queue and if necessary blocks execution until a term that unifies to Term arrives in the queue.Source
pengine_event_loop/2Starts an event loop accepting event terms sent to the current pengine or thread.Source
pengine_input/2Sends Prompt to the master (parent) pengine and waits for input.Source
pengine_next/2Asks pengine NameOrID for the next solution to a query started by pengine_ask/3.Source
pengine_output/1Sends Term to the parent pengine or thread.Source
pengine_property/2True when Property is a property of the given Pengine.Source
pengine_pull_response/2Pulls a response (an event term) from the slave Pengine if Pengine is a remote process, else does nothing at all.Source
pengine_respond/3Sends a response in the form of the term Input to a slave (child) pengine that has prompted its master (parent) for input.Source
pengine_rpc/2Semantically equivalent to the sequence below, except that the query is executed in (and in the Prolog context of) the pengine server referred to by URL, rather than locally.Source
pengine_rpc/3Semantically equivalent to the sequence below, except that the query is executed in (and in the Prolog context of) the pengine server referred to by URL, rather than locally.Source
pengine_self/1True if the current thread is a pengine with Id.Source
pengine_stop/2Tells pengine NameOrID to stop looking for more solutions to a query started by pengine_ask/3.Source
pengine_user/1True when the pengine was create by an HTTP request that authorized User.Source
portray_blob/2Portray non-text blobs that may appear in output terms.Source
prepare_goal/3Pre-preparation hook for running Goal0.Source
prepare_module/3Hook, called to initialize the temporary private module that provides the working context of a pengine.Source
prompt/3Hook to handle pengine_input/2 from the remote pengine.Source
write_result/3Hook that allows for different output formats.Source
create_pool/1On demand creation of a thread pool for a pengine application.Source
pengines_io.pl  -- Provide Prolog I/O for HTML clientsShow source
binding_term/5Hook to render a Prolog result term as HTML.Source
message_lines_to_html/3Helper that translates the Lines argument from user:message_hook/3 into an HTML string.Source
pengine_bind_io_to_html/1Redefine the built-in predicates for IO to send HTML messages using pengine_output/1.Source
pengine_display/1Redirect the corresponding Prolog output predicates.Source
pengine_flush_output/0No-op.Source
pengine_format/1As format/1,2.Source
pengine_format/2As format/1,2.Source
pengine_io_predicate/1True when Head describes the head of a (system) IO predicate that is redefined by the HTML binding.Source
pengine_listing/0List the content of the current pengine or a specified predicate in the pengine.Source
pengine_listing/1List the content of the current pengine or a specified predicate in the pengine.Source
pengine_nl/0Emit a <br/> to the pengine.Source
pengine_print/1Redirect the corresponding Prolog output predicates.Source
pengine_tab/1Emit N spaces.Source
pengine_write/1Redirect the corresponding Prolog output predicates.Source
pengine_write_canonical/1Redirect the corresponding Prolog output predicates.Source
pengine_write_term/2Writes term as <span class=Class>Term</span>.Source
pengine_writeln/1Emit Term as <span class=writeln>Term<br></span>.Source
pengine_writeq/1Redirect the corresponding Prolog output predicates.Source
send_html/1Convert html//1 term into a string and send it to the client using pengine_output/1.Source
show_html_hook/1Hook into help/1 to render the help output in the SWISH console.Source
message_hook/3Send output from print_message/2 to the pengine.Source
term_to_json.plShow source
term_to_json/2Convert any general Prolog term into a JSON term.Source
term_to_json/3Convert any general Prolog term into a JSON term.Source