File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Making Webmethod parameters mandatory?

 
Sree SaiRam
Greenhorn
Posts: 1
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

I am working on webservice bottom up approach on IRAD 7 with jaxws 2.1.and jaxb

I want to make webmethod parameters mandatory,I tried using @Xmlelement(required=true)
but it is not updating my XSd.

Can you suggest a suitable approach to make my webmethod parameters mandatory


Thanks in Advance.
rama.
 
joy lobo
Greenhorn
Posts: 1
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I have WebService (C#) with one WebMethod that takes 4 parameters, as below:

<s:element minOccurs="0" maxOccurs="1" name="requestedBy" type="s:string" />
<s:element minOccurs="1" maxOccurs="1" name="submissionDateTime" type="s:dateTime" />
<s:element minOccurs="0" maxOccurs="1" name="orderReference" type="s:string" />
<s:element minOccurs="0" maxOccurs="1" name="currentState" type="s:string" />

My problem is that I would like every one of these arguments to be mandatory when being call by the client i.e.

<s:element minOccurs="1" maxOccurs="1" name="requestedBy" type="s:string" />
<s:element minOccurs="1" maxOccurs="1" name="submissionDateTime" type="s:dateTime" />
<s:element minOccurs="1" maxOccurs="1" name="orderReference" type="s:string" />
<s:element minOccurs="1" maxOccurs="1" name="currentState" type="s:string" />

If it is not clear what my problem is from this then please let me know and I will try to clarify.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic