|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--se.sics.jasper.PrologEngine
Objects of this class represent a Prolog engine running in a separate process.
Constructor Summary | |
PrologEngine(java.lang.String[] cmdarray)
Starts a new Prolog process on the local machine |
|
PrologEngine(java.lang.String machine,
int portNum)
Connect to a running Prolog process on 'machine:portNum'. |
Method Summary | |
static int |
cbTestMethod(int x,
double y)
|
static java.lang.Object |
cbTestMethod(java.lang.Integer obj,
int x,
double y)
|
boolean |
compile(java.lang.String filename)
Instruct the Prolog engine to compile a file. |
boolean |
consult(java.lang.String filename)
Instruct the Prolog engine to consult a file. |
protected void |
finalize()
|
static java.lang.String |
getNextLine(java.io.BufferedReader reader)
Returns next non-empty line from 'reader' which does not start with '#'. |
void |
halt()
|
static void |
main(java.lang.String[] argv)
|
boolean |
query(java.lang.Object[] querySpec)
Ask a Prolog query given an array of Java objects. |
boolean |
query(java.lang.String query)
Ask a query to the Prolog engine |
boolean |
restore(java.lang.String filename)
Instruct the Prolog engine to restore a saved state. |
static void |
writeLine(java.io.BufferedWriter writer,
java.lang.String str)
Writes a string to a BufferedWriter, adds a newline and flushes the stream |
Methods inherited from class java.lang.Object |
clone,
equals,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Constructor Detail |
public PrologEngine(java.lang.String[] cmdarray) throws java.io.IOException, ConnectionFailedException, PrologException
public PrologEngine(java.lang.String machine, int portNum) throws java.io.IOException, ConnectionFailedException, PrologException
Method Detail |
public static int cbTestMethod(int x, double y)
public static java.lang.Object cbTestMethod(java.lang.Integer obj, int x, double y)
public static java.lang.String getNextLine(java.io.BufferedReader reader) throws java.io.IOException
public static void writeLine(java.io.BufferedWriter writer, java.lang.String str) throws java.io.IOException
protected void finalize() throws java.io.IOException, java.lang.InterruptedException
public void halt() throws java.io.IOException, java.lang.InterruptedException
public boolean query(java.lang.String query) throws java.io.IOException, PrologException
public boolean query(java.lang.Object[] querySpec) throws java.io.IOException, PrologException
public boolean consult(java.lang.String filename) throws java.io.IOException, PrologException
public boolean compile(java.lang.String filename) throws java.io.IOException, PrologException
public boolean restore(java.lang.String filename) throws java.io.IOException, PrologException
public static void main(java.lang.String[] argv)
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |