For correct doc-literal, you cannot use 'type' in your
part definiton. Try changing your message definition
to contain a single part element with an element
attribute (instead of a type attribute). 

E.g.
      <xsd:complexType name="testTwoInType">
        <xsd:all>
          <xsd:element name="foo" type="xsd:string"/>
          <xsd:element name="bar" type="xsd:string"/>
        </xsd:all>
      </xsd:complexType>
      <xsd:element name="testTwoInMsg"
type="<your_namespace>:testTwoInType"/> 

<message name="testTwoIn">
  <part name="input"  
element="<your_namespace>:testTwoInMsg" /> 
</message>

This should cause axis' wsdl2java to use the wrapped
mode.

Shantanu
--- Kartik <[EMAIL PROTECTED]> wrote:
> I can't do that as I am using doc-literal format and
> not the rpc-encoded format.  Correct me if I am
> wrong,
> but in doc-literal, the only way I can correspond a
> message part to a type is by re-routing the types as
> elements.
> 
> Thanks.
> Kartik
> 
> --- [EMAIL PROTECTED] wrote:
> > Hi,
> > 
> > 
> > Don't define elements named foo bar and wow.
> > 
> > In your message just change the types of f b and w
> > to xsd:string and instead of 
> > using element use type
> > 
> > i.e. 
> > 
> > <message name="testTwoIn">
> >   <part name="foo" type="xsd:string" /> 
> >   <part name="bar" type="xsd:string" /> 
> > </message>
> > <message name="testTwoOut">
> >   <part name="wow" type="xsd:string" /> 
> > </message>
> > 
> > 
> > 
> > Regards
> > 
> > Steve
> > 
> > Quoting Kartik <[EMAIL PROTECTED]>:
> > 
> > > Hi Folks.
> > > 
> > > I have attached the very simple WSDL
> > (paramtest.wsdl)
> > > that I am testing with.  I have a couple of
> issues
> > and
> > > it would be great if someone can point some
> > > solutions/references.
> > > 
> > > In my WSDL, I have a single operation as shown
> > belo
> > > (java mapping):
> > > 
> > > String testTwo(String f, String b);
> > > 
> > > The operation takes two Strings and returns the
> > > "hello" back.
> > > 
> > > I run a simple C#.NET client (I also tried IONA
> > Artix
> > > C++ clients with the same results) which creates
> a
> > > proxy and calls:
> > > 
> > >   ParamTestService service = new
> > ParamTestService();
> > >   string result = service.testTwo("abcd",
> "wxyz");
> > > 
> > > When I try to invoke on the operation, I can see
> > on
> > > the Tomcat console, that only the first argument
> > > ("abcd") reaches the service.  The second
> argument
> > > never reaches the service!  If I do a
> > > System.out.println on f and b in my operation
> > > implementation, I see "abcd" for f (first arg),
> > but I
> > > see 'null' for b (second arg)!
> > > 
> > > Does anyone know of any such issues or if you
> can
> > find
> > > a problem in my WSDL, that would be too good. 
> But
> > I
> > > think my WSDL looks okay, because other
> WebService
> > > tool-kits to build my service and tested the
> > > interoperability (.NET (C#), Artix (C++), XMLBus
> > > (Java)), the same WSDL can generate the servers
> > and
> > > clients fine with correct invocations on all
> > > cross-combinations.  It seems that only Axis is
> > having
> > > some problems :(
> > > 
> > > PS: I looked at the request SOAP message
> received
> > by
> > > Axis, and it DOES have the second argument's
> value
> > -
> > > but somewhere in reading the incoming message or
> > > parsing it, it loses the second argument.
> > > 
> > > Please try out the service - it will not take
> more
> > > than 10 minutes ... See steps below:
> > > 
> > > - Copy the WSDL to a temp location
> > > - Generate the server side code:
> > > java org.apache.axis.wsdl.WSDL2Java -s -a
> > > paramtest.wsdl
> > > - Provides a sample implementation of the
> > > org/apache/ka/ParamTestImpl.java methods.
> > > - Build and deploy the service on Tomcat.
> > > - Generate client code using the local/deployed
> > WSDL.
> > > - Build and run the client to invoke the method
> > > testTwo().
> > > - See the SOAP messages and the behavior or the
> > > service
> > > 
> > > Thank you ...
> > > Kartik
> > > 
> > > __________________________________
> > > Do you Yahoo!?
> > > Yahoo! Search - Find what you’re looking for
> > faster
> > > http://search.yahoo.com
> > 
> > 
> > 
> > 
> >
> ---------------------------------------------------
> > This message was sent using Spansurf Web Mail
> > Internet access in Spain -
> http://www.spansurf.com/
> > 
> 
> 
> __________________________________
> Do you Yahoo!?
> Yahoo! Search - Find what you’re looking for faster
> http://search.yahoo.com

Reply via email to