• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

XML natural order for multiple occurence elements

 
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Does the specification say anything about the natural order in xml? Means, when an element which has multiple occurence gets parsed is it guaranteed across parsers that we will get the elements in the same order in the parsed tree? Or do we need to define an attribute to indicate order?
 
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
http://www.ibm.com/developerworks/xml/library/x-eleord.html
 
Greg Parker
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

David Newton wrote:http://www.ibm.com/developerworks/xml/library/x-eleord.html



Does this mean just by introducing a schema, and having a maxOccurs="unbounded" will make the parser bound to report the elements in the document order?
 
David Newton
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I don't know why it would, or how that's related--is there something you've read that makes you think it's relevant?
 
Greg Parker
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

David Newton wrote:I don't know why it would, or how that's related--is there something you've read that makes you think it's relevant?


From reading the article. This is what I got.
Normal xml specification doesn't say anything about order or any other processing instructions.
Processing instructions follow a separate specification which usually refers to XML info set specification.
So might get the order?

Also please help me with why we have XML infoset specification?
 
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
1. Infoset provides a clear set of definitions for talking about parts of an XML document.

2. Infoset provides a way to state whether or not some process handles all of the information in an XML document.

I suspect that the W3C thought Infoset became necessary as the number of tools for manipulation of XML grew and grew.

Bill
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic