/** Unfortunately, this is transport-specific. However, no one
* but the HTTP transport should pick this property up.
*/
client.set(HTTPConstants.MC_HTTP_SOAPACTION, "AdminService");
Message inMsg = new Message( input, true );
client.setRequestMessage( inMsg );
client.set( Transport.USER, opts.getUser() );
client.set( Transport.PASSWORD, opts.getPassword() );
String tName = opts.isValueSet( 't' );
if ( tName != null && !tName.equals("") )
client.setTransportName( tName );
client.invoke();
Message outMsg = client.getMessageContext().
getResponseMessage();
if (outMsg == null) {
log("Null response message!");
return null;
}
client
.getMessageContext()
.setServiceDescription(new ServiceDescription("Admin", false));
input.close();
SOAPEnvelope envelope =
(SOAPEnvelope) outMsg.getAsSOAPEnvelope();
SOAPBodyElement body = envelope.getFirstBody();
StringWriter writer = new StringWriter();
client.addOption(AxisEngine.PROP_XML_DECL, new Boolean(false));
SerializationContext ctx = new SerializationContext(writer,
client.getMessageContext());