title: Getting individual properties with owl api
body: <p>I'm trying to read the information stored in an ontology. The XML binding (of the part I'm working in) is: </p>
  
  <pre><code>&lt;!-- hasPrevious and hasNext are defined at the imported ontology --&gt;
  &lt;owl:NamedIndividual   rdf:about="http://www.myexampledomain.com/myExample.owl#one_relationship"&gt;
      &lt;rdf:type rdf:resource="http://www.myexampledomain.com/myExample.owl#typeA"/&gt;
      &lt;intui_PO:hasPrevious rdf:resource="http://www.myexampledomain.com/myExample.owl#element01"/&gt;
      &lt;intui_PO:hasNext rdf:resource="http://www.myexampledomain.com/myExample.owl#element02"/&gt;
  &lt;/owl:NamedIndividual&gt;
  </code></pre>
  
  <p>I use the following Java code: </p>
  
  <pre><code>//Create factories that will produce the objects
  OWLReasonerFactory reasonerFactory = new StructuralReasonerFactory();
  OWLDataFactory fac = man.getOWLDataFactory();
  
  //Get a reasoner, to query the ontology
  OWLReasonerConfiguration config = new SimpleConfiguration();
  OWLReasoner reasoner = reasonerFactory.createReasoner(owlOnt, config);
  
  //Get relations. Their properties are the related individuals
  OWLClass myclass = fac.getOWLClass(IRI.create("http://www.myexampledomain.com/myExample.owl#RelationClass"));
  NodeSet&lt;OWLNamedIndividual&gt; individualsRelationNodeSet = reasoner.getInstances(myclass,false);
  Set&lt;OWLNamedIndividual&gt; relations = individualsRelationNodeSet.getFlattened();
  </code></pre>
  
  <p>With this, I have NamedIndividuals that are the relations found. I want to read their  properties with: </p>
  
  <pre><code>Map&lt;OWLObjectPropertyExpression,Set&lt;OWLIndividual&gt;&gt; properties = oneRelation.getObjectPropertyValues(owlOnt);
  </code></pre>
  
  <p>But I get an empty Map. I cannot find the solution, can anyone help me?</p>