Hi,

Thanks for quick response.
But as I have mentioned , my method signature is like this .

public float method1(String str, int count, Integer size)


As per ur explaination, with current mapping inside SOAPMappingRegistry,
both arguments will be converted to int and we will get a intDeserializer.

Hence argumets for invoke will be (String,int,int) and not (String, int ,
Integer).

Hence it is failing.

I am using plain java class as client.
According to Scott, we can change in the mapping registry by invoking
mapTypes() method of SMR to take Integer.

But that time no int parameter is accepted.

So handling both in a single method still is a question.

Any suggestions from developer group will be appreciated


----- Original Message -----
From: "Neha Srivastava" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, October 03, 2002 6:50 PM
Subject: Re: Silly Error


> hi,
>
> change
> >     params.addElement(new Parameter("p", Integer.class, p, null));
>  to-
> >     params.addElement(new Parameter("p", Integer.class, new Integer(p),
> null));
>
>  u r using servlet client or simple java class client?
>
> regards
> neha
>
> ----- Original Message -----
> From: "Tanmay Kumar" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Thursday, October 03, 2002 3:05 PM
> Subject: Fw: Silly Error
>
>
> > Hi all,
> >
> > There is very poor response today. Scott have answered to my question .
> > But today due to his absence in mailing list, no reply has yet come.
> >
> > I hope u all have a solution for my question as u might have faced this
> > before.
> > Please answer as I am unable to proceed. Pls. read the below mentioned
> > paragraph.
> >
> > Tans
> >
> > ----- Original Message -----
> > From: "Tanmay Kumar" <[EMAIL PROTECTED]>
> > To: <[EMAIL PROTECTED]>
> > Sent: Thursday, October 03, 2002 10:37 AM
> > Subject: Re: Silly Error
> >
> >
> > > Hi Scott,
> > >
> > > From your answer, It is not very clear what we should do.
> > > If a method is having a signature like this
> > > public float method1(String str, int count, Integer size) , which is
> very
> > > much possible,
> > > according to you both count and size variable will be converted to
> xsd:int
> > > in SOAP message.
> > >
> > > Then the method invokation will fail as it will try to invoke with
> > > (String,int,int).
> > > You all must have solved these things long before.
> > >
> > > It might be an inane question from my side.
> > > But please reply with the exact solution as I am not able to proceed
> > > further.
> > >
> > > thanks,
> > > Tans
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > > ----- Original Message -----
> > > From: "Scott Nichol" <[EMAIL PROTECTED]>
> > > To: <[EMAIL PROTECTED]>
> > > Sent: Wednesday, October 02, 2002 10:46 PM
> > > Subject: Re: Silly Error
> > >
> > >
> > > > Both Integer and int are serialized as xsd:int.  By default, xsd:int
> is
> > > > deserialized to int.  For your particular method, you need to
> > > > deserialize to Integer, which you can do with a custom mapping.  Of
> > > > course, this means all xsd:int will be deserialized to Integer,
which
> > > > probably breaks any method that has an int parameter.
> > > >
> > > > Scott Nichol
> > > >
> > > > ----- Original Message -----
> > > > From: "Tanmay Kumar" <[EMAIL PROTECTED]>
> > > > To: <[EMAIL PROTECTED]>
> > > > Sent: Wednesday, October 02, 2002 9:21 AM
> > > > Subject: Silly Error
> > > >
> > > >
> > > > > Hi all,
> > > > >
> > > > > I am getting an strange error of no such method with the following
> > > > code.
> > > > >
> > > > >
> > > > > My method signature for Webservice is
> > > > > public float testMethod(String city, Integer p)
> > > > >
> > > > > The parameter setting part of Client code is like this:
> > > > >
> > > > >
> > > > >   Vector params = new Vector();
> > > > >     params.addElement(new Parameter("city", String.class, "Tokyo",
> > > > null));
> > > > >      Integer  p = new Integer(44);
> > > > >     params.addElement(new Parameter("p", Integer.class, p, null));
> > > > >     call.setParams (params);
> > > > >
> > > > > Exception says "java.lang.NoSuchMethodException:
> > > > > TanWS.testMethod(java.lang.String,int)"
> > > > > Basically it converts the Integer wrapper class to prinmitive int.
> > > > >
> > > > > DO I need to do something special in SOAPMappingRegistry class for
> > > > this.
> > > > > I am using SOAP-2_3_1 and Tomcat 4.0.
> > > > >
> > > > > Please response to this.
> > > > >
> > > > > TAI,
> > > > > Tans
> > > > >
> > > > >
> > > > > --
> > > > > To unsubscribe, e-mail:
> > > > <mailto:[EMAIL PROTECTED]>
> > > > > For additional commands, e-mail:
> > > > <mailto:[EMAIL PROTECTED]>
> > > > >
> > > > >
> > > >
> > > >
> > > > --
> > > > To unsubscribe, e-mail:
> <mailto:[EMAIL PROTECTED]>
> > > > For additional commands, e-mail:
> <mailto:[EMAIL PROTECTED]>
> > > >
> > > >
> > >
> > >
> > > --
> > > To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
> > > For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>
> > >
> > >
> >
> >
> > --
> > To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
> > For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
> >
>
>


----------------------------------------------------------------------------
----


> --
> To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to