• Post Reply Bookmark Topic Watch Topic
  • New Topic

SCWCD Question

 
Benedikt Sattler
Greenhorn
Posts: 16
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have a question.
Am I right that if the web.xml file is validated with a XML Scheme instead of a DTD file, the ordering of the elements in the tags does not matter.
For example:
With a scheme the following would be valid:
<servlet>
<servlet-class></servlet-class>
<servlet-name> </servlet-name>
</servlet>
With a DTD this will not be valid, because the ordering of the elements does matter.

If I am right, what version is asked in the 1.4 exam, the DTD or the Scheme.

regards
Benedikt
 
Phani Burra
Ranch Hand
Posts: 52
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Benedikt,

Prior to the J2EE 1.4 specifications, each Deployment Descriptor must be valid with respect to a specific DTD that describes the Deployment Descriptor. Starting with the J2EE 1.4 specification, each specification requires its Deployment Descriptor be validated with respect to an XML Schema. As Sun would still support the code written using previous I think the validation of DD with a corresponding DTD is still supported. I hope this info helps.
 
Gravity is a harsh mistress. But this tiny ad is pretty easy to deal with:
the new thread boost feature: great for the advertiser and smooth for the coderanch user
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!