Note that there are some explanatory texts on larger screens.

plurals
  1. PORowlex - Getting only "root" individuals of a document
    text
    copied!<p>here is my rdf document which is generated by the rowlex library : </p> <pre><code>&lt;rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:ns="http://xmlns.com/foaf/0.1/" xmlns:privateinfos="http://domain/privateinfos/"&gt; &lt;ns:Person rdf:about="Node 1"&gt; &lt;ns:depiction rdf:resource="Default.png" /&gt; &lt;privateinfos:description rdf:datatype="http://www.w3.org/2001/XMLSchema#string"&gt;Description&lt;/privateinfos:description&gt; &lt;ns:knows&gt; &lt;ns:Person rdf:about="6779ac10-210b-40d2-8111-711db6988bb9" /&gt; &lt;/ns:knows&gt; &lt;/ns:Person&gt; &lt;ns:Person rdf:about="Node 2"&gt; &lt;ns:depiction rdf:resource="Default.png" /&gt; &lt;privateinfos:description rdf:datatype="http://www.w3.org/2001/XMLSchema#string"&gt;Description 2&lt;/privateinfos:description&gt; &lt;/ns:Person&gt; &lt;/rdf:RDF&gt; </code></pre> <p>And I am trying to retrieve the Node 1 and Node 2 individuals with this code :</p> <pre><code>List&lt;Person&gt; person_list = new List&lt;Document&gt;(); OwlThing[] Persons = _rdfDocument.GetIndividuals(Person.Uri, true); foreach (Person item_found in Persons) { person_list.Add(item_found); } return person_list; </code></pre> <p>unfortunatly person_list returns with the following data :</p> <pre><code>[0] : Node 1 [1] : 6779ac10-210b-40d2-8111-711db6988bb9 [2] : Node 2 </code></pre> <p>So is there a way/methode to get only the node 1 and 2 without their sub elements in the list ? (of courses the individuals ID's are dynamically generated so i can't search for a specific ID)</p> <p>Thanks.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload