W3C home > Mailing lists > Public > w3c-dist-auth@w3.org > October to December 2001

RE: content type for WebDAV request/response bodies, was: [ACL] Access Control Protocol -07 submitted

From: Lisa Dusseault <lisa@xythos.com>
Date: Tue, 20 Nov 2001 22:35:18 -0800
To: "Julian Reschke" <julian.reschke@gmx.de>, <mtimmerm@opentext.com>, "'WebDAV'" <w3c-dist-auth@w3.org>
Message-ID: <HPELJFCBPHIPBEJDHKGKOEHBDBAA.lisa@xythos.com>
> > To get the namespace URI and local name from a property URI, just scan
> > backwards for the last '#', '/', or ':', and split the URI.  If the left
> > part ends in #, then remove it.
>
> That doesn't give you a one-to-one mapping.
>
> For instance:
>
> <foo xmlns="http://a.b.c/d#"/> and <foo xmlns="http://a.b.c/d"/>
>
> would map to the same URI.
>
> How would you map
>
> <foo xmlns="http://a.b.c/d#e"/>

I've seen this done before.  MTimmerman's rules for undoing the
concatenation were correct as I recall, but he didn't put the rules for
concatenation in, which would have cleared things up.
 - If the namespace ends in '/' or ':', concatenate.
 - If the namespace ends in anything else, add a '#' and concatenate.

Thus, you'd transform <foo xmlns="http://a.b.c/d#"/> to
"http://a.b.c/d##foo".  Clearly different than "http://a.b.c/d#foo" since
you only remove the last '#' when un-concatenating.

You ask how to map <foo xmlns="http://a.b.c/d#e"/>: since it ends in 'e',
add a '#', and it becomes "http://a.b.c/d#e#foo".  When going back to real
XML form, scan backward from the end for the last '#', remove it.


Lisa
Received on Wednesday, 21 November 2001 13:37:37 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 2 June 2009 18:43:59 GMT