On 20/08/2011 19:20, Maatary Daniel OKOUYA wrote:
Hi All,


I'm trying to walk through an RDF Graph following a certain order. Like
with graph algorithm i would to control the way i go through the graph.

For instance, like in graph algorithm, i get the children of the top
most node, then treat this level and then using a First in first out
structure and i can go down level by level by repeating the same thing
on each node, that is ,putting there children in the first in first out
structure.

It seams that there is no way to do that with jena using the jena RDF
API, is that right ?

Yes, indeed from an RDF point of view there is no order to the properties from a node so there is no notion of LIFO. The ordering in the source file is irrelevant and not preserved.

If you want some notion of fixed order of leaves you should probably be using XML and not RDF. If you want to use RDF then use collections or containers rather than trying to change the interpretation of the serialization.

The problem i have with the listing of statement, is that, i'm not
interested in each specific statement. I want to get a node and deal
with each statement of that node, as i have to make a java
representation of it in another representation format.

That's easy. The node corresponds to a Resource so Resource.listProperties lists all the statements from that node.

To be more precise, my RDF file contain some action and some time it may
be that there is two action, knowing that the class action is defined in
an RDFS, including the domain specific action used in my RDF file.

The problem that i have with getting the resource, it seams it could be
ressource at any level.

I can't follow this. If you have a reference to the RDFS then you have a URI for the resource and so can immediately find all statements about that resource.

I'm feeling like i'm not taking the problem the right way, can any give
me an advise on it.

Not without a clearer description of what you are trying to do.

Dave

Reply via email to