I suggest you use minOccurs="0" rather than nillable="true".
.NET is a little tempermental about nil.

Anne

On 11/12/05, Davanum Srinivas <[EMAIL PROTECTED]> wrote:
Jerry,

recommendation is to use Java2WSDL once, use the wsdl as a starting
point, check it into your cvs/svn repo. Make any modifications if
necessary incrementally and use the WSDL2Java on the wsdl. (In other
words, Don't keep regenerating the wsdl from Java2WSDL). Basically you
should use Java2WSDL as a bootstrap thing to get something quick and
dirty and from then on stick to the WSDL.

-- dims

On 11/10/05, Jalenak, Jerry < [EMAIL PROTECTED]> wrote:
> Thanks for the reply.  I guess I'm not clear on how to code up an 'extra' class for this purpose.  The 'generated' classes are coming from the method signatures of my class - i.e., if I have
>
>    public String getAbc(ComplexObject1 co1, ComplexObject2 co2) { .... }
>
> I get a new class called GetAbc.java which looks like this -
>
>    public class GetAbc implements java.io.Serializable {
>       private ComplexObject1 in0;
>       private ComplexObject2 in1;
>
>       public GetAbc() {}
>       public GetAbc(ComplexObject1 in0, ComplexObject2 in1) {
>          this.in0 = in0;
>          this.in1 = in1;
>       }
>
>       .... a bunch of other methods ....
>    }
>
> And in the WSDL I get
>
>    <element name="getAbc">
>       <complexType>
>          <sequence>
>             <element name="in0" type="impl:ComplexObject1"/>
>             <element name="in1" type="impl:ComplexObject2"/>
>          </sequence>
>       </complexType>
>     </element>
>
> All I need to be able to do is add 'nillable="true"' to the <element />s above.  It would be nice if, instead of apply this to everything, that I could specify some sort of attribute so I could control which method attributes get the 'nillable="true"' option.
>
> Thanks.
>
> Jerry Jalenak
> Software Engineer
> Netopia, Inc.
> -----Original Message-----
> From: BASNARY Olivier [mailto: [EMAIL PROTECTED]]
> Sent: Thursday, November 10, 2005 4:37 PM
> To: [email protected]
> Subject: RE: Forcing nillable=true with Document Literal Wrapped
>
> I depends a lot on which parameters you ar using with
> java2WSDL.
>
> You should check for extraclasses parameter.
>
> For instance, I use ant task with these params :
> <target name="java2wsdl">
>     <axis-java2wsdl classname="${appClassName}"
> classpath="${build.dir}" // this is very important
>                 methods=<My service operations>                         extraClasses
> ="${appExtraclass}" // Beans describing complex types
> output="${appOutputWSDL}" // Name of output WSDL
> location="${appLocation}" // Service URL : http://...
> namespace="${appNamespace}" //
> namespaceImpl="${appNamespaceImpl}" //urn:..
> style="WRAPPED"/>
> </target>
>
> And all my attributes are nillable='true'.
>
> You should check in Axis ejb samples for a build.xml
> containing a j2w ant task and change it to your
> convenience (by adding style parameter).
>
> --- "Jalenak, Jerry" < [EMAIL PROTECTED]> a écrit :
>
> > I'm wrapping an existing class and exposing it as a
> > Document Literal
> > Wrapped webservice.  When I generate the WSDL with
> > Java2WSDL, the
> > generated WSDL contains 'created' class definitions
> > for the new object
> > that 'wraps' my input attributes.  Is there a way to
> > force
> > 'nillable=true' to be added to these definitions?
> >
> >
> >
> > i.e., I get this -
> >
> >
> >
> >    <element name="replaceCPE">
> >
> >     <complexType>
> >
> >      <sequence>
> >
> >       <element name="in0"
> > type="impl:CpeIdentifier"/>
> >
> >       <element name="in1"
> > type="impl:CpeProperties"/>
> >
> >       <element name="in2" type="impl:EventSink"/>
> >
> >      </sequence>
> >
> >     </complexType>
> >
> >    </element>
> >
> >
> >
> > But I want this -
> >
> >
> >
> >    <element name="replaceCPE">
> >
> >     <complexType>
> >
> >      <sequence>
> >
> >       <element name="in0" nillable="true"
> > type="impl:CpeIdentifier"/>
> >
> >       <element name="in1" nillable="true"
> > type="impl:CpeProperties"/>
> >
> >       <element name="in2" nillable="true"
> > type="impl:EventSink"/>
> >
> >      </sequence>
> >
> >     </complexType>
> >
> >    </element>
> >
> >
> >
> > Thanks!
> >
> >
> >
> > Jerry Jalenak
> >
> > Software Engineer
> >
> > Netopia, Inc.
> >
> >
> >
> >
>
>
>
>
>
>
>
> ___________________________________________________________________________
> Appel audio GRATUIT partout dans le monde avec le nouveau Yahoo! Messenger
> Téléchargez cette version sur http://fr.messenger.yahoo.com
>


--
Davanum Srinivas : http://wso2.com/blogs/

Reply via email to