xmlurlrdfrdf-xml

Is it possible to abbreviate URLs in RDF/XML attribute values?


I found the following XML snippet:

<structMap xmlns:np="urn:library-of-congress:ndnp:mets:newspaper">
    <div TYPE="np:issue" DMDID="issueModsBib">

In short: Does np:issue resolve to urn:library-of-congress:ndnp:mets:newspaper:issue, or not?

More formally: Does the above XML, converted to some kind of triple representation, contain the triple (let $ be referencing the anonymous node representing the <div> element)

〈$, http://www.loc.gov/METS/TYPE, urn:library-of-congress:ndnp:mets:newspaper:issue〉

or does it contain the triple

〈$, http://www.loc.gov/METS/TYPE, "np:issue"〉

with "np:issue" being a plain literal?

I believe to remember that URLs in XML attribute values cannot be abbreviated using namespaces, but it was years ago I learned that. I read about the proposal to use := assignment syntax (would be <div TYPE:="np:issue">) to tell the parser that the value is abbreviated by a namespace, but that (afaik) never made it to a standard. Maybe there is some new convention or even spec that I am not aware of? Or does the above, from a mechanically-semantically point of view, just not express what I believe it was intended to?


Solution

  • No they can't be abbreviated using namespace prefixes. The most that can be done is to use relative URIs in attributes and set an xml:base. See the RDF 1.1 XML Syntax specification for more details.