Thanks, Anne. I will try your suggestions. Is it necessary to set the
resultType for my my call? Should I do something like this:
QName qnSearchResponse=new QName("urn:ifis-wsdl", "SearchResponseType");
callSearch.setReturnType(qnSearchResponse);
Or is that wrong or unncessary?
Anne Thomas Manes <[EMAIL PROTECTED]> wrote:
Lindsey,
First issue: You've imported your schema namespace incorrectly. You
can't use the to import a schema. You must use
instead. must appear within the
definition.
Second issue: Based on your current WSDL, your method signature looks like this:
searchResponse search(searchRequest);
If you want your method signature to accept and return parameters
rather than value objects, then you must define the WSDL using the
"wrapped" convention (see [1]), and in your WSDD you should define the
service thus:
Third issue: Remove the "namespace" attribute from your
and definitions. (The namespace attribute should be used
only with style="rpc".) They should be defined thus:
and
I've also seen a recurring problem with schemas that have a namespace
URI that ends with "#". If you fix the issues above and still have
this problem, I suggest your try removing the "#" from the namespace.
Anne
On 2/12/07, Lindsey Hess
wrote:
> Hi Anne,
>
> Attached is the WSDL.
>
> From my client code, I'm doing this:
>
> Object[] opParamsSearch=(new PostiveInteger(m_Timeout), queryType);
> //queryType is a complex type
>
> SearchResponseType searchResponse;
> try{
>
> searchResponse=(SearchResponseType)callSearch.invoke(opParamsSearch);
> }catch(Exception e)
> {
> e.printStackTrace();
> }
>
>
> It may not be apparent from the WSDL, but SearchResponseType returns an id
> and a result of type ResultType. ResultType is a complex type. It contains
> a number of required parameters, included a complex type called metadata.
> Metadata is essentially an array. So, every search response will contain an
> id, results, and an array of metadata.
>
> I should note that in my server-config.wsdd file I have all of the necessary
> serializes/deserializers listed (WSDL2Java created them). I'm also defining
> my service as follows:
>
>
>
> Thank you!
>
> Lindsey
>
> Anne Thomas Manes wrote:
> Can you post the WSDL please?
>
> On 2/12/07, Lindsey Hess wrote:
> > Hi,
> >
> > I've run Axis 1.4's WSDL2Java against my WSDL and associated schemas, and
> > generated a number of classes. My WSDL contains a number of complex types.
> >
> > When I invoke a web service from some client code, I get the following
> > exception:
> >
> > "simpledeserializer encountered a child element, which is NOT expected, in
> > something it was trying to deserialize"
> >
> > I don't understand why I'm getting this, as I'm setting the required
> > parameters in my server code as specified in my WSDL. Does anyone have any
> > suggestions?
> >
> > Thank you,
> >
> > Lindsey
> >
> > ________________________________
> > Everyone is raving about the all-new Yahoo! Mail beta.
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>
>
> ________________________________
> Any questions? Get answers on any topic at Yahoo! Answers. Try it now.
> --0-1514824370-1171307635=:47831--
>
>
>
---------------------------------
Get your own web address.
Have a HUGE year through Yahoo! Small Business.