try {
URL url =
new URL("http://mindstrm.com:8199/CorpDataService/Proxy.asmx");
Service service = new Service();
Call call = (Call) service.createCall();
call.setTargetEndpointAddress( url );
call.setOperationName("getHeadlines");
call.setProperty(Call.NAMESPACE,
"http://mindstrm.com/CorpDataService");
call.setProperty(HTTPConstants.MC_HTTP_SOAPACTION,
"http://mindstrm.com/CorpDataService/getHeadlines");
call.addParameter("symbol", XMLType.XSD_STRING, Call.PARAM_MODE_IN);
call.setReturnType(XMLType.SOAP_ARRAY);
ArrayList ret = (ArrayList)call.invoke(new Object[] {args[0]});
Object[] res = ret.toArray();
int cnt = res.length;
for (int i = 0; i < cnt; i++) {
System.out.println((String)res[i]);
}
}
catch (Exception e) {
System.out.println(e);
}