Re: D:href as a property?

Helge Hess wrote:

> Hi,
> 
> is it allowed to use <D:href xmlns:D="DAV:"> as a regular WebDAV property?

No (not until it becomes a standard WebDAV property, that is).

> ---snip---
> <D:response>
>   <D:href>http://abc:8050/zidestore/so/x/IPM/Enterprises/34390</D:href>
>   <D:propstat>
>     <D:status>HTTP/1.1 200 OK</D:status>
>     <D:prop>
>       <D:href>http://abc:8050/zidestore/so/x/IPM/Enterprises/34390</D:href>
> ---snap---
> 
> I would assume yes. The D:href is part of the WebDAV protocol header 
> while the contained D:href is a property being transported by WebDAV.

It could be, but as no standards-track spec defines it, and it resides 
in the DAV: namespace, it's invalid.

Anyway: I've seen servers implementing this because the Microsoft 
Webfolder client indeed asks for it. But, surprise, it doesn't use it.

> Two relevant snippets from the spec:
> 
> ---snip(section 4.5)---
> Finally, it is not possible to define the same property twice on a 
> single resource, as this would cause a collision in the resource's 
> property namespace.
> ---snap---
> I guess this one is pretty clear, the response/href element is not a 
> property and therefore doesn't clash with the prop/href XML element.
> The thing I miss in the spec is a statement that only direct <prop> 
> children are considered properties in a <response> payload.

Why would that need to be stated?

> This one is a bit harder:
> ---snip(section 12.9.1)---
> A particular href MUST NOT appear more than once as the child of a 
> response XML element
> ---snap---
> I suppose the intention was to forbid multiple href elements directly 
> below <response>. But the text isn't clear whether MOST NOT applies to 
> direct children or to deep children as well. The latter would include 
> children of <prop> and therefore forbid D:href being exposed as a 
> regular property.

It applies to children in the sense of XML, thus direct children. So 
this restricts the multistatus response body not to have multiple 
response elements for the same href. It doesn't say anything at all 
about DAV:href elements that appear somewhere else (such as inside 
DAV:lockinfo).

> It would be great if someone could put some light on this.

Hope this helps,

Julian
-- 
<green/>bytes GmbH -- http://www.greenbytes.de -- tel:+492512807760

Received on Wednesday, 29 September 2004 14:13:37 UTC