Reputation: 11
I've just built a new OWL ontology in protege (classes, properties and individuals). My problem is: How can I access (query) the individuals to use it in a program written in Java under Eclipse.
I've tried the following:
Thus what is the proper method for accessing (Querying) the OWL individuals from protege in a Java program written under Eclipse.
Upvotes: 1
Views: 5389
Reputation: 4886
You should use a Java library for RDF. You mention Jena, but there's also Sesame. Or if you want something OWL specific, you could try the OWLAPI.
There's nothing fancy you need to do to use your ontology in an application. Any of the aforementioned libraries can read it in, it's just RDF after all, and provide programmatic access directly such as iterating over the triples, or via queries or other lookup mechanisms.
All three libraries have good documentation to get you started on how you'd read in and use your ontology. You might stick with the OWLAPI if you want to use a reasoner, or want to do OWL-specific manipulations of the data.
Upvotes: 3