I have previously asked this question here, but I was asked to post the question on this forum.
I have an .owl
file which has an entitiy something like this:
<owl:NamedIndividual rdf:about="http://example.org/kb/object_test.owl#obj_1234_pose">
<rdf:type rdf:resource="http://example.org/kb/example.owl#Transform"/>
<example:quaternion rdf:datatype="http://example.org/kb/example.owl#vec4">0.0 0.0 1.0 0.0</example:quaternion>
<example:translation rdf:datatype="http://www.w3.org/2001/XMLSchema#vec3">0.0 0.5 0.2</example:translation>
</owl:NamedIndividual>
When I do a prolog
query (triple
is part of the framework’s query language):
triple('http://example.org/kb/object_test.owl#obj_1234_pose', 'http://example.org/kb/example.owl#translation', A).
I get the response:
type('http://www.w3.org/2001/XMLSchema#vec3','0.0 0.5 0.2').
Firstly, I do not get type
in the response when rdf:datatype
is a string
. In case of a &xsd;string
, I get the result as (for example): 0.0 0.5 0.2
Why is that so?
Secondly, is there any way to extract the value from the type
? Or do I need to treat it a string manipulation?