I am using RDF lib to retrieve values from an online triple store.
I was wondering whats the ideal way of turning URIRef and Literals to plain string objects?
For example :
value = g.value(s,FOAF.page)
Should I be using value.n3()
, or value.__str__()
? Is there any difference ? On my tests, both return a sting that looks the same.
Initially I was just storing the value, but turns out it causes problems during String comparisons, so I would like to just store a string, as there is no rdf-related processing after the extraction.