|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.deri.wsml.reasoner.flora.Reasoner
public class Reasoner
Flora2 reasoner connector for WSML. With this class you can convert WSML ontologies and WSML conjunctive queries to Flora2 ontologies and Flora2 queries, respectively. Furthermore, you can connect to an Flora2 instance and execute the query against the given ontology. The reasoner depends on WSMO4J for the parsing of WSML documents and for internal representation of WSML. At the current stage, the reasoner only supports the logical expressions in an ontology, since WSMO4J has not yet been sufficiently updated. If several instances of this class work on the same Flora2, problems may arise, because there is no locking mechanism.
| Constructor Summary | |
|---|---|
Reasoner()
|
|
| Method Summary | |
|---|---|
void |
connectFlora(java.lang.String floraDirectory,
java.lang.String xsbDirectory)
Connects to Flora2 given the XSB and Flora2 directories |
void |
connectToFlora2()
Connects to Flora2 |
java.lang.String |
convertQuery(java.lang.String wsmlQuery)
Convert a given WSML conjunctive query to an Flora2 query |
java.lang.String |
convertWSML(java.io.PushbackReader wsmlDocument)
Converts a WSML document (in human-readable syntax) to Flora2 F-Logic currently, only the logical expressions are converted |
void |
loadOntology(java.io.PushbackReader wsmlOntology)
Loads the given ontology into the reasoner and checks the constraints |
java.lang.Object[] |
processCommand(java.lang.String command)
|
java.lang.String |
query(java.io.PushbackReader wsmlOntology,
java.lang.String wsmlQuery)
Queries a given WSML ontology using a given conjunctive query |
java.lang.String |
query(java.lang.String wsmlQuery)
Queries the reasoner |
java.lang.String |
queryOntology(java.lang.String wsmlOntology,
java.lang.String wsmlQuery)
Queries a given WSML ontology using a given conjunctive query using the Flora2 running on the local machine |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Reasoner()
| Method Detail |
|---|
public void connectFlora(java.lang.String floraDirectory,
java.lang.String xsbDirectory)
floraDirectory - xsbDirectory - public void connectToFlora2()
public java.lang.Object[] processCommand(java.lang.String command)
public java.lang.String queryOntology(java.lang.String wsmlOntology,
java.lang.String wsmlQuery)
throws java.lang.Exception
wsmlOntology - wsmlQuery -
java.lang.Exception
public java.lang.String query(java.io.PushbackReader wsmlOntology,
java.lang.String wsmlQuery)
throws java.lang.Exception
wsmlOntology - wsmlQuery -
java.lang.Exception
public java.lang.String query(java.lang.String wsmlQuery)
throws java.lang.Exception
wsmlQuery -
java.lang.Exception
public void loadOntology(java.io.PushbackReader wsmlOntology)
throws java.lang.Exception
wsmlOntology -
java.lang.Exceptionpublic java.lang.String convertQuery(java.lang.String wsmlQuery)
wsmlQuery -
public java.lang.String convertWSML(java.io.PushbackReader wsmlDocument)
wsmlDocument - A WSML document in human-readable syntax
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||