W3C home > Mailing lists > Public > public-rif-wg@w3.org > July 2009

Re: Version 0 of the 'RIF+XML data' document "nouvelle maniere"

From: Gary Hallmark <gary.hallmark@oracle.com>
Date: Mon, 27 Jul 2009 15:14:05 -0700
Message-ID: <4A6E26AD.4000407@oracle.com>
To: Christian De Sainte Marie <csma@fr.ibm.com>
CC: Dave Reynolds <der@hplb.hpl.hp.com>, RIF <public-rif-wg@w3.org>

>
> That is right, indeed. The only place where the fact that everything 
> in XDM is a sequence would be used is if multiple element children 
> with the same name were retrieved as a list (preserving the document 
> order). But that would be contradictory with frame slots being 
> multi-valued.
It's not contradictory. You simply have a choice to import the multiple 
child elements as a multi-valued slot or a single list-valued slot. This 
is similar to rdf:parseType=collection and rif:ordered="yes". This 
suggests some kind of extra metadata argument to the Import directive to 
guide which representation to use.

One high-level comment is that because RIF Frames are almost exactly the 
same as RDF triples, probably all the issues in Importing XML to RIF 
have already been investigated in the guise of XML<->RDF translation. 
Sandro knows a lot about this.

We have never discussed an alternative: Import XML documents as 
Predicate/function terms. E.g.

<shiporder orderid="889923"
           xmlns="http://example.org"
           orderperson="John Smith">
  <shipto>
    <name>Ola Nordmann</name>
    <address>Langgt 23</address>
    <city>4000 Stavanger</city>
    <country>Norway</country>
  </shipto>
  <item>
    <title>Empire Burlesque</title>
    <note>Special Edition</note>
    <quantity>1</quantity>
    <price>10.90</price>
  </item>
  <item>
    <title>Hide your heart</title>
    <quantity>1</quantity>
    <price>9.90</price>
  </item>
</shiporder> 

Import (embed in RIF) as follows:

Prefix(ns, <http://example.org/>
ns:shiporder(orderid(88923), orderperson("John Smith"),
  ns:shipto(ns:name("Ola Nordmann"), ns:address("Langgt 23"), 
ns:city("4000 Stavanger"), ns:country("Norway"))
  ns:item(ns:title("Empire Burlesque"), ...)
  ns:item(...)
)

Yes, I know this comes with a different set of issues, not the least of 
which is that it isn't Core. But for many applications I can imagine 
that it is a more natural mapping than frames. E.g. it preserves 
document order. Again, some extra argument to Import might guide the 
mapping toward using this style.
Received on Monday, 27 July 2009 22:15:46 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 July 2009 22:15:47 GMT