A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Win a copy of
Refactoring for Software Design Smells: Managing Technical Debt
this week in the
OO, Patterns, UML and Refactoring
Generated WSDL with schema validation
Joined: Nov 14, 2008
Mar 23, 2011 10:53:58
Is it possible to add schema restrictions to parameters via JAX-WS annotations?
I have a method
@WebMethod ReturnContainer<List<Street>> getStreets(@WebParam(name = "streetname")String streetname);
The parameter streetname should always be longer then 3 characters, to avoid gigantic result lists. I would like this to be a restriction in the schema like
<xs:element name="streename"> <xs:simpleType> <xs:restriction base="xs:string"> <xs:minLength value="3"/> </xs:restriction> </xs:simpleType> </xs:element>
How can I make sure that the generated WSDL file includes such a restriction on the parameter?
I agree. Here's the link:
subject: Generated WSDL with schema validation
Invalid type (xsi:type) is set when XML request is generated from web service client
Axis 1.4 throwing org.xml.sax.SAXException: Invalid element
in Schema Dynamic value for maxLength - help
Annotation for regular expression.
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2015