XML.orgXML.org
FOCUS AREAS |XML-DEV |XML.org DAILY NEWSLINK |REGISTRY |RESOURCES |ABOUT
OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]
Re: [xml-dev] Why does XML call them "attributes" and not name-value pairs?



On Sat, 15 Jan 2022 at 19:58, Roger L Costello <costello@mitre.org> wrote:
Liam wrote:

> they represent attributes (properties) of that element.

But, but, but, ...

In the past I made the mistake on this list of calling attributes 'metadata' (a.k.a. properties) and was subsequently scolded (paraphrasing):

        Attributes are not metadata. Look in the XML specification,
        there is not a single mention of the word 'metadata.' (Nor
        does the XML specification refer to attributes as properties.)
        Attributes are merely syntax. Attributes are merely an alternate
        syntax to the <element>value</element> syntax. Attributes
        have no relationship, meaning, affinity, context-sensitivity,
        or anything with elements or anything else.

Did I misunderstand my scolding?

These sure look to me like whitespace-separated name-value pairs:

    name="John Doe" employer="Acme Inc." age="30"

That is because name-value pairs in most settings represent attributes of some (real or data artifact) thing being described, where the name is the name of a property. 

You can get here by asking "name of what", "value of what"? From where I stand the notion of attributes and properties is more strongly established than "name-value pair", and provides the context for understanding how the "value" encodes a claim about an attribute of something.

Dan

/Roger


[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]


News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 1993-2007 XML.org. This site is hosted by OASIS