how to create a rdf List

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

how to create a rdf List

houzw
Hi, is there any way to create a rdf list using owlready2?

I found that rdflib can do this job(as below), but how to link it to owlready2 created individuals?
Thanks!

```
listName =  BNode()
g =Graph()
c = collection.Collection(g, listName, [Literal(1), Literal(2)])
```
Reply | Threaded
Open this post in threaded view
|

Re: how to create a rdf List

Jiba
Administrator
Hi,

Owlready has internal functions for manipulating RDF lists, but RDF list are not OWL instances or classes, so it does not provide an easy way to manipulate lists.

I think you need a library at the RDF level for that (e.g. RDFlib).

Jiba