I have a Axis2 web service implemented using AXIOM that returns a list of String.
The code snippet of client in Java that works is as follws.
// * send SOAP message
sender.fireAndForget( requestObject );
// * get response
OMElement reponseObject = sender.sendReceive( requestObject );
// * iterator for String
Iterator elementItr = reponseObject.getChildElements();
while(elementItr.hasNext())
{
OMElement element = (OMElement)elementItr.next();
// * print each message
System.out.println( element.getText() );
}
I need to implement a c# client that consumes the service as above.
I've been able to test a c# client that return a single String object as below.
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using HDMClient.hdssWS;
namespace HDMClient
{
class Program
{
static void Main(string[] args)
{
HDMClient.hdssWS.StockQuoteServicePortTypeClient client = new hdssWS.StockQuoteServicePortTypeClient("StockQuoteServiceHttpSoap11Endpoint");
client.update("apple", 1232.123);
Console.WriteLine(client.getPrice("apple"));
Console.ReadLine();
}
}
}
The message type in app.config is "MTOM" and the configuration in axis2.xml in WAS is set to
<parameter name="enableMTOM">true</parameter>
I can deal with a single String response.
But I have no idea how to deal with a list of String as above.
I've searched the similar cases
but it looks like there is not the case I am faced with.
Do you have any idea?