I have a ODF document where I have applied RDF metadata (using the UNO
API) to a textsection which looks like this :

(met/meta.rdf)

<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#";>
  <rdf:Description rdf:about="../content.xml#id276852556">
    <ns1:sectionType
xmlns:ns1="http://anx.bungeni.org/1.0/";>Clause</ns1:sectionType>
    <ns2:sectionUUID
xmlns:ns2="http://anx.bungeni.org/1.0/";>1723-18388-38383-38383</ns2:sectionUUID>
  </rdf:Description>
</rdf:RDF>

I am unable to read it back --

e.g. [1]
<code>
....
Dim rdfRepo
rdfRepo = thisComponent.getRDFRepository()
Dim arrGraphs
arrGraphs = rdfRepo.getGraphNames()

</code>

In the above case ... getGraphNames() always returns an empty array !

e.g. [2]
<code>
Dim uriAnx
uriAnx = UriService.create("http://anx.bungeni.org/1.0"; )
Dim uriGraphs
uriGraphs = thisComponent.getMetadataGraphsWithType(uriAnx)
</code>

In the above case too .... getMetadataGraphsWithType() returns a empty
array ...but the document has the metadata.

What am i doing wrong ? Is this not the way to retrieve the metadata graph ?

Just for reference -- this is what the manifest.rdf looks like ----

<?xml version="1.0" encoding="utf-8"?>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#";>
  <ns1:Document
xmlns:ns1="http://docs.oasis-open.org/ns/office/1.2/meta/pkg#";
rdf:about="">
    <ns1:hasPart rdf:resource="content.xml"/>
    <ns1:hasPart rdf:resource="meta/meta.rdf"/>
    <ns1:hasPart rdf:resource="styles.xml"/>
  </ns1:Document>
  <ns2:StylesFile
xmlns:ns2="http://docs.oasis-open.org/ns/office/1.2/meta/odf#";
rdf:about="styles.xml"/>
  <ns3:ContentFile
xmlns:ns3="http://docs.oasis-open.org/ns/office/1.2/meta/odf#";
rdf:about="content.xml"/>
</rdf:RDF>

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to