aspose file tools*
The moose likes Web Services and the fly likes How to set minOccurs= Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Web Services
Bookmark "How to set minOccurs="1" in wsdl for an input parameter to web service method." Watch "How to set minOccurs="1" in wsdl for an input parameter to web service method." New topic
Author

How to set minOccurs="1" in wsdl for an input parameter to web service method.

Kavita Mohite
Greenhorn

Joined: Jun 15, 2011
Posts: 1
Hi,

I have a web service implemented with apache cxf and spring. I have one web method which takes String argument as the input parameter. When I check the wsdl for this web method I see that the occurrence indicator minOccurs is set to 0 for the String input parameter. Here I want to set both minOccurs and maxOccurs to 1 to indicate that the input parameter is mandatory and singleton. To do this I used the annotation @Xmlelement and set its property required=true for the string input parameter, but this is not getting reflected in the wsdl. Am I doing something wrong here ? How do I get this right ?

Here is the code :


Thanks
Kavita
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to set minOccurs="1" in wsdl for an input parameter to web service method.