Hello Dave,
Thanks for the prompt reply, but i have tried this approach but i only get the
Super classes inferred.I can't get the subclass which i was expecting jena to
infer based on data property restriction.
Kind regards,Olatunde
On Thursday, 26 January 2017, 20:32, Dave Reynolds
<[email protected]> wrote:
On 26/01/2017 15:20, tina sani wrote:
> How can I get all the classes of which an individual is a type? After Jena
> rules executed, my individual has multiple class like:
> Employee001 is of type: Worker, Programmer, Manager.
>
> So can I get all these three classes in Jena ? I have read somewhere that
> getOntClass() only return one class at a time and that is on random basis.
>
See OntResource#listRDFTypes or, if you just have a Resource then
Resource#listProperties(RDF.type) or, as Charles says, use SPARQL.
Dave
---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus