You are viewing a plain text version of this content. The canonical link for it is here.
Posted to soap-dev@ws.apache.org by Yasunori KASAI <ka...@nexs.nec.co.jp> on 2001/12/28 01:39:05 UTC

Please Help Me!!

Assume there is a class shown below.
This class has a method 'appendTest()'.This method has no return value,
and appends a 'Hello',and a String received with same parameter to a
received
field of StringBuffer.

**************************************************************
public class StringBufferTest{

 /** appends a 'Hello' at the head of receied String Buffer
*/
 public void appendTest(StringBuffer a, String b){

  a.append("Hello ");
  a.append(b);
 }

 /**
*Main
 */
 public static void main(String args[]){

  StringBuffer strBuff = new StringBuffer();
  StringBufferTest tes = new StringBufferTest();
  tes.appendTest(strBuff, args[0]);

  System.out.println(strBuff.toString());
 }
}
****************************************************************

Example of a run and an output is as shown below.

****************************************************************
>java StringBufferTest World
Hello World
****************************************************************

Question:
 Is it possible to register the append Test
of this cass as a Web Service, and implement this
by SOAP communication?

We tried by using Apache SOAP, but it doesn't work.

Is it impossible to implement a service by SOAP,
which 'let cliant arrange an empty parameter and
let server put a value in parameter'?

Thank you.


Re: Please Help Me!!

Posted by Scott Nichol <sn...@computer.org>.
Apache SOAP does not support "output" parameters, so it does not support a
method with the signature you show.  Some people (myself included) have
changed the source to add support.  It is not particularly difficult.  You
may want to see whether Axis (the next generation of Apache SOAP) supports
this.

Scott

----- Original Message -----
From: "Yasunori KASAI" <ka...@nexs.nec.co.jp>
To: <so...@xml.apache.org>
Sent: Thursday, December 27, 2001 7:39 PM
Subject: Please Help Me!!


> Assume there is a class shown below.
> This class has a method 'appendTest()'.This method has no return value,
> and appends a 'Hello',and a String received with same parameter to a
> received
> field of StringBuffer.
>
> **************************************************************
> public class StringBufferTest{
>
>  /** appends a 'Hello' at the head of receied String Buffer
> */
>  public void appendTest(StringBuffer a, String b){
>
>   a.append("Hello ");
>   a.append(b);
>  }
>
>  /**
> *Main
>  */
>  public static void main(String args[]){
>
>   StringBuffer strBuff = new StringBuffer();
>   StringBufferTest tes = new StringBufferTest();
>   tes.appendTest(strBuff, args[0]);
>
>   System.out.println(strBuff.toString());
>  }
> }
> ****************************************************************
>
> Example of a run and an output is as shown below.
>
> ****************************************************************
> >java StringBufferTest World
> Hello World
> ****************************************************************
>
> Question:
>  Is it possible to register the append Test
> of this cass as a Web Service, and implement this
> by SOAP communication?
>
> We tried by using Apache SOAP, but it doesn't work.
>
> Is it impossible to implement a service by SOAP,
> which 'let cliant arrange an empty parameter and
> let server put a value in parameter'?
>
> Thank you.
>
>


Re: Please Help Me!!

Posted by Scott Nichol <sn...@computer.org>.
Apache SOAP does not support "output" parameters, so it does not support a
method with the signature you show.  Some people (myself included) have
changed the source to add support.  It is not particularly difficult.  You
may want to see whether Axis (the next generation of Apache SOAP) supports
this.

Scott

----- Original Message -----
From: "Yasunori KASAI" <ka...@nexs.nec.co.jp>
To: <so...@xml.apache.org>
Sent: Thursday, December 27, 2001 7:39 PM
Subject: Please Help Me!!


> Assume there is a class shown below.
> This class has a method 'appendTest()'.This method has no return value,
> and appends a 'Hello',and a String received with same parameter to a
> received
> field of StringBuffer.
>
> **************************************************************
> public class StringBufferTest{
>
>  /** appends a 'Hello' at the head of receied String Buffer
> */
>  public void appendTest(StringBuffer a, String b){
>
>   a.append("Hello ");
>   a.append(b);
>  }
>
>  /**
> *Main
>  */
>  public static void main(String args[]){
>
>   StringBuffer strBuff = new StringBuffer();
>   StringBufferTest tes = new StringBufferTest();
>   tes.appendTest(strBuff, args[0]);
>
>   System.out.println(strBuff.toString());
>  }
> }
> ****************************************************************
>
> Example of a run and an output is as shown below.
>
> ****************************************************************
> >java StringBufferTest World
> Hello World
> ****************************************************************
>
> Question:
>  Is it possible to register the append Test
> of this cass as a Web Service, and implement this
> by SOAP communication?
>
> We tried by using Apache SOAP, but it doesn't work.
>
> Is it impossible to implement a service by SOAP,
> which 'let cliant arrange an empty parameter and
> let server put a value in parameter'?
>
> Thank you.
>
>