Declarativa Declarativa
 

 

Entrada

Produtos

Serviços

Inquiridor
Aplicações internet à medida
Auditoria informática
Subcontratação para I&D

Plataforma de conteúdos

Tecnologia

Web Information Systems
Web Application Maker
InterProlog

A empresa

Apresentação institucional

com.xsb.interprolog
Class AbstractNativeEngine

java.lang.Object
  extended bycom.declarativa.interprolog.AbstractPrologEngine
      extended bycom.xsb.interprolog.AbstractNativeEngine
All Implemented Interfaces:
PrologEngine
Direct Known Subclasses:
NativeEngine

public abstract class AbstractNativeEngine
extends AbstractPrologEngine

A PrologEngine implemented using the Java Native Interface. This class depends on interprolog_callback.c and other files, that are included in the emu directory of XSB Prolog 2.5 and later


Field Summary
 
Fields inherited from class com.declarativa.interprolog.AbstractPrologEngine
firstJavaMessageName, interrupting, nl, prologBinDirectoryOrCommand
 
Fields inherited from interface com.declarativa.interprolog.PrologEngine
MAX_INT_VALUE, MIN_INT_VALUE, version
 
Constructor Summary
AbstractNativeEngine(String XSB_BIN_DIR, boolean debug, boolean loadFromJar)
           
 
Method Summary
 Object[] deterministicGoal(String G, String OVar, Object[] objectsP, String RVars)
          Synchronously calls a Prolog goal.
 
Methods inherited from class com.declarativa.interprolog.AbstractPrologEngine
abortTasks, assignableType, command, consultAbsolute, consultFromPackage, consultRelative, deterministicGoal, deterministicGoal, deterministicGoal, deterministicGoal, doCallback, endAllTasks, findConstructor, findMethod, firstJavaMessage, getImplementationPeer, getJarDirectory, getJarDirectory, getLoadFromJar, getPrologBaseDirectory, getPrologNumericVersion, getPrologVersion, getRealJavaObject, getRealJavaObject, getRealJavaObject, handleCallback, interrupt, interruptTasks, isAvailable, isDebug, isIdle, isMacOS, isShutingDown, isWindowsOS, load_dynRelative, makeInvisible, printBindings, progressMessage, prologBinToBaseDirectory, realCommand, registerJavaObject, setDebug, setThreadedCallbacks, shortClassName, shutdown, teachMoreObjects, teachMoreObjects, teachMoreObjects, teachOneObject, unescapedFilePath, unregisterJavaObject, unregisterJavaObject, unregisterJavaObjects, waitUntilAvailable, waitUntilIdle
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractNativeEngine

public AbstractNativeEngine(String XSB_BIN_DIR,
                            boolean debug,
                            boolean loadFromJar)
Method Detail

deterministicGoal

public Object[] deterministicGoal(String G,
                                  String OVar,
                                  Object[] objectsP,
                                  String RVars)
Description copied from class: AbstractPrologEngine
Synchronously calls a Prolog goal. Only the first solution is considered. G should contain a syntactically correct Prolog term, without the trailing dot (.). Throws an IPAbortedException if a Prolog abort happens, and an IPInterruptedException if the interrupt() method was invoked.

Specified by:
deterministicGoal in interface PrologEngine
Overrides:
deterministicGoal in class AbstractPrologEngine
Parameters:
G - Prolog goal term
OVar - Prolog variable that will be bound to objectsP array
objectsP - Array of Java objects to pass to Prolog goal
RVars - Prolog list with object specifications, typically containing variables occurring in g. If null a single binding will be returned, containing a TermModel object representing the goal term solution
Returns:
a new array containing an object for each term in the rVars list, or null if goal fails
See Also:
AbstractPrologEngine.deterministicGoal(String), AbstractPrologEngine.deterministicGoal(String,String), AbstractPrologEngine.deterministicGoal(String,String,Object[])



 Declarativa - Serviços de Informática, Lda.
  www.declarativa.com, info@declarativa.com  fax: +351-22-030-1511  tel: +351-22-030-1580
UPTEC - Parque de Ciência e Tecnologia da Universidade do Porto (GoogleMap)
Rua Actor Ferreira da Silva 100 4200-298 Porto Portugal