[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: XML Literalist
Hi Roger, > [Definition] Literalist: A person who adheres to the literal > representation of a statement or law; a person who translates text > literally. An unfortunate possible association with 'literalism' is that of narrow-mindedness: "what I perceive as the literal interpretation is the only possible interpretation and furthermore no additional considerations coming from the context of use and the nature of the object being described may be added to this interpretation". I do hope you are aware of this danger and as usual, are somewhat teasing in order to get a range of responses from the community. Also in your statement that > XML literalism makes XML usage objective. -- because the statement is rather subjective ('literalism' being in essence a subjective exercise, an exercise in how many interpretations I can eliminate in order to arrive at the one that I like most^H^H^H^H^H^H^H^H^H^H^His true and intended by the Maker). Much has already been said on this in the previous thread, so I will only address one more point: > A non-Literalist will say things like "attribute values provide > metadata". What does that mean? What is metadata? One man's metadata > is another man's data. Does anyone debate that? It's part of the charm of the entire enterprise. I use XML to describe language, but at the moment I begin, I also create an interpretation of it. Then I can study this interpretation. When I provide (meta)data about individual words (and how I decide what "words" are is a big unsettled business in the first place), I can then study the metadata and (a) draw conclusions from in on the nature of the language/dialect being described, and (b) compare it with others' descriptions and conclusions. That is, I create metadata over metadata, and I am very happy about that :-) I realise that the above paragraph is removed from the very source of the discussion, but it looks like part of the method is similar: don't objectivise your subjective choices. And one more remark: if I hadn't been late to notice your first message in the previous thread, my response would have involved a question: "have you made XML your religion?" Your apparently uncritical approach to what the XML Bib^H^H^HSpec says may suggest so to an untrained eye :-) (also the assumption that someone may seriously want to argue about non-existence from the absence of evidence is kind of similar in spirit). Although I believe it should best be interpreted as an attempt to elicit a strong response, at which you were again successful. > You make decisions on whether to use an element or attribute based on > technical reasons. There are overlay specs, and the XML spec provides only a basic data model that is overlaid with more specific data models, some of which require (or at least permit) such-and-such serializations, sometimes independent of purely technical considerations. (Unless you extend your definition of "technical reasons", but then we'd make a circle, I'm afraid.) Best regards, and keep up your teasing, it's been fruitful :-) Piotr On 20.03.2011 14:43, Costello, Roger L. wrote: > Hi Folks, > > [Definition] Literalist: A person who adheres to the literal representation of a statement or law; a person who translates text literally. > > > The XML specification defines an attribute as follows: > > Attributes are used to associate name-value pairs with elements. > > The specification states where attributes are to be positioned: > > Attribute specifications MUST NOT appear outside of start-tags > and empty-element tags > > And it specifies the format of attributes: > > name = delimiter value delimiter > > > The specification says that elements may have attributes: > > Each element ... may have a set of attribute specifications > > The specification says that elements are boundaries: > > Each XML document contains one or more elements, the boundaries of which > are either delimited by start-tags and end-tags, or, for empty elements, > by an empty-element tag. > > It defines what occurs between the start-tag and end-tag boundaries: > > The text between the start-tag and end-tag is called the element's content > > > XML Literalist Axioms: > > 1. Attributes are name-value pairs > 2. Elements are boundaries for the content between the start-tag and end-tag > 3. Aside from (1) and (2), no further meaning is ascribed to attributes or elements. > > Thus, attributes can be used wherever name-value pairs are desired and elements can be used wherever boundaries are desired. > > > XML literalism is freeing. XML literalism makes XML usage objective. Here's why: > > XML literalism is freeing: > > - You make decisions on whether to use an element or attribute based on technical reasons. You are not restricted to making decisions based on vague pseudo-semantic reasons. Here's an example of making a decision to use attributes based on technical reasons: Andrew Welch states that when doing SAX processing of XML documents there are technical reasons for using attributes: > >> If you are sax parsing and have to switch processing based on some value, then > it's far easier to do that if it's an attribute than a child element. For >> example: >> >> <product type="A" name="blah"> >> <stuff/> >> >> vs >> >> <product> >> <name>blah</name> >> <type>A</type> >> <stuff/> >> >> In the former case you can easily process <product> based on its type attribute > at the time <product> is reported. >> >> In the latter case, you have to push the events onto a stack, or recursive peek > ahead until you discover the type. > > > XML literalism makes XML usage objective: > > A non-Literalist will say things like "attribute values provide metadata". What does that mean? What is metadata? One man's metadata is another man's data. Metadata is vague and prone to much misinterpretation. For instance, are these attributes providing metadata: > > <Book category="fiction" inStock="true"> > ... > </Book> > > Non-Literalists will spend countless hours debating whether category and inStock are providing metadata. > > An XML Literalist says that an attribute is a name-value pair. Period. No other semantics are ascribed to attributes. Thus, there are no discussions on whether category and inStock provide metadata. Instead, a Literalist shifts the discussion to technical issues such as: > > - Are we going to use SAX to process the <Book>? > - Will descendants of <Book> need to make validation decisions based on category and inStock? (If yes, better make them attributes and declare them inheritable) > > Comments? > > /Roger > > _______________________________________________________________________ > > XML-DEV is a publicly archived, unmoderated list hosted by OASIS > to support XML implementation and development. To minimize > spam in the archives, you must subscribe before posting. > > [Un]Subscribe/change address: http://www.oasis-open.org/mlmanage/ > Or unsubscribe: xml-dev-unsubscribe@lists.xml.org > subscribe: xml-dev-subscribe@lists.xml.org > List archive: http://lists.xml.org/archives/xml-dev/ > List Guidelines: http://www.oasis-open.org/maillists/guidelines.php > >
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] |
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|