• 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 Validation and capturing response

 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi All,

I am having 2 types of messages 1) Request and 2) Response.
.
I need to write a dummy application inorder to accpte the XML and validate the contents of both Request and Response.I have constructed a Response.xml which is of generic type and also an input file passing the requeste message details. I need to validate the input.xml and capture the response.

Can any one suggest me a route hou to go ahead.

Thanks in Advance!!

 
Bartender
Posts: 1051
5
Hibernate Eclipse IDE Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
By validate, do you mean well formed? Or do you mean against a defined XSD or DTD?
 
Minni Rose
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks for your quick response.

not in both formats infact.
let's say for a field ex:login field , they might send a response or they might send some code so we need to validate that.

We can get the output with the help https or anything else but we need to validate the data like we will send the expected response data and compare to the actual data.
 
Minni Rose
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
My generic response xml will be in this form:

<response>
<command type="@@entityType@@" name="@@eventName@@">
<entityresponse>
<faultcode></faultcode>
<faultstring></faultstring>
</entityresponse>
<entitydata entitytype="">
<datafield datatype="">
<name></name>
<value></value>
</datafield>
</command>
</response>


and Input.xml is:

<header>
<authinfo>
<username></username>
<password>s0n*l1Nk!</password>
</authinfo>
</header>
<body>
<request>
---some values ---
</request>
<response>
---some values ---

</response>
</request>
</body>
 
James Boswell
Bartender
Posts: 1051
5
Hibernate Eclipse IDE Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Minni

I think you need to provide a simple example to make it clear what you are trying to achieve. Remember to use the appropriate tags when you do.
 
Minni Rose
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
James,

Infact I didnt develop anything as of now need some guidance in gng ahead. I need to validate some data passed thru xml and chk whether the contents in response are proper or not for the values passed.
 
What kind of corn soldier are you? And don't say "kernel" - that's only for this tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic