• 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

order of elements in web.xml - DD

 
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Is there a restriction on order of elements in web.xml deployement descriptor.

an excerpt from servlet spec: " The sub elements under web-app can be in an arbitrary order in this version of the specification."

so there is no order rule in 2.4 spec.

correct me if i am wrong.
 
Ranch Hand
Posts: 136
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

so there is no order rule in 2.4 spec.


yes ,u r right... there is no order rule in 2.4 specs

regards
-santosh
 
Author
Posts: 836
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It depends on whether you're using the DTD or the XML Schema when applying a schema to your deployment descriptor. In DTDs, the order of elements is important, but in Schemas this is less strict (provided sub-elements appear in the right places etc.).

You'll know which you're using because you'll have used a DOCTYPE declaration if you're using a DTD, and some xsl: namespace attributes on the root element if you're using an XML Schema.

XML Schemas are much more flexible and therefore are replacing DTDs, and as a result, all Server 2.4+ specifications incorporate a Schema in preference to the DTD (however, there is still a DTD available for 2.4).
 
Think of how dumb the average person is. Mathematically, half of them are EVEN DUMBER. Smart tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic