W3C home > Mailing lists > Public > www-archive@w3.org > September 2002

Re: [security-services] Why use name-value pairs for modeling attributes?

From: Joseph Reagle <reagle@w3.org>
Date: Mon, 16 Sep 2002 15:28:31 -0400
To: "Eve L. Maler" <eve.maler@sun.com>, "'security-services@lists.oasis-open.org'" <security-services@lists.oasis-open.org>, "'saml-dev@lists.oasis-open.org'" <saml-dev@lists.oasis-open.org>
Cc: www-archive@w3.org
Message-Id: <200209161528.31668.reagle@w3.org>

[Thanks Prateek, I feared you forgot me! <smile/> Also, I fear this message 
will be bounced by Oasis, so I'm cc:ing the w3c archive...]

On Monday 16 September 2002 09:51 am, Eve L. Maler wrote:
> (Note that the first example below should look more like this:
> <Attribute
>    AttributeNamespace="http://www.finance.org/V1"
>    AttributeName="CreditRating">
>    <AttributeValue>Good</AttributeValue>
> </Attribute>

Right, this struck me as very odd because there's no "normal" Infoset item 
for this information, the namespace declaration is verbose (though I'm glad 
you didn't stick only a prefix in there!), it's difficult to write a schema 
to validate it, and  there's no other parameters that I can associate with 
it. If it was XML, I could have a nested/parameterized structure, validate 
it, extend it, query it with XPath or forthcoming XQuery, etc. Now that I 
understand the way in which you are attempting to query it I see the 
motivation at least...

> There are a number of other ways we could have done it; one would be (a
> well-formed version of) the one apparently suggested by Joseph:
>
> <finance:CreditRating
>    xmlns:finance="http://www.finance.org/V1">
> Good
> </finance:CreditRating>
>
> I don't know if we really considered this option seriously.

Yep! I can then get at it with XPath or XSLT, don't need a special query 
thingy.

> We should probably consider what our true stance is on "QNames in
> content", since currently we're inconsistent and this doesn't offer a
> lot of guidance as to future design.

I'd avoid it if I could. (I have in the specs I've authored, and I've 
recommended it to others with mixed success and in the end it will be their 
headache...)
Received on Monday, 16 September 2002 15:35:06 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 7 November 2012 14:17:22 GMT