This week's book giveaway is in the Jython/Python forum.
We're giving away four copies of Hands On Software Engineering with Python and have Brian Allbey on-line!
See this thread for details.
Win a copy of Hands On Software Engineering with Python this week in the Jython/Python forum!
  • 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 all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Bear Bibeault
  • Knute Snortum
  • Liutauras Vilda
  • Tim Cooke
  • Devaka Cooray
  • Paul Clapham
Saloon Keepers:
  • Tim Moores
  • Frits Walraven
  • Ron McLeod
  • Ganesh Patekar
  • salvin francis
  • Tim Holloway
  • Carey Brown
  • Stephan van Hulst

web service function parameter format limitation and validatioin question  RSS feed

Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

I am building a document/literal webservice in websphere. The WSDL is generated from exsting java bean.

in the java bean there is a function requesting passing in the social security number. In the generated WSDL it defines this part as:

<element name="findBySSN">
<element name="SSN" nillable="true" type="xsd:string"/>

My questions are:

1. How could I modify the WSDL and make it more restricted on the SSN number? - say it has to be 9 digit number without '-'. I saw some example using simple typed element and restrict on base string, but I tried on the above complex type, it has error.

2. Even I modifed the above wsdl and restrict the SSN format, then should my service also need to check the format of client passed in SSN parameter and throw user defined exception and map it to the WSDL as fault?

If someone can give me some help and advise, I would highly appreciate.

Story like this gets better after being told a few times. Or maybe it's just a tiny ad:
RavenDB is an Open Source NoSQL Database that’s fully transactional (ACID) across your database
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!