File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Web Services Certification (SCDJWS/OCPJWSD) and the fly likes Request xml validation Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Professional Certification » Web Services Certification (SCDJWS/OCPJWSD)
Reply Bookmark "Request xml validation" Watch "Request xml validation" New topic
Author

Request xml validation

Poornima Sharma
Ranch Hand

Joined: Sep 09, 2008
Posts: 102
Hi Friends,

How can we ensure that our request xml does not have any unwanted tags. As per my current implementation the unwanted tags are simply ignored by the webservice, how can we mandate that the request xml has only the necessary tags.

Thanks,


Poornima Sharma
SCJP 6.0
Ivan Krizsan
Bartender

Joined: Oct 04, 2006
Posts: 2186
Hi!
Add a web service handler that validates incoming and/or outgoing messages.
An example on how to develop a web service handler can be found in section 9.5 of this document: http://www.slideshare.net/krizsan/scdjws-5-study-notes-3085287
There are also examples on how to perform validation of XML against a XML schema elsewhere in the same document.
Best wishes!


My free books and tutorials: http://www.slideshare.net/krizsan
 
 
subject: Request xml validation
 
Threads others viewed
how to redirect url to the login page?
WA #1.....word association
Strange error with Apache POI
Using XML for string message
XML Escape Newline Characters
developer file tools