本文整理汇总了Java中org.apache.axis.message.RPCParam类的典型用法代码示例。如果您正苦于以下问题:Java RPCParam类的具体用法?Java RPCParam怎么用?Java RPCParam使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
RPCParam类属于org.apache.axis.message包,在下文中一共展示了RPCParam类的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: demarshallArguments
import org.apache.axis.message.RPCParam; //导入依赖的package包/类
private Object[] demarshallArguments() throws Exception {
SOAPMessage message = messageContext.getMessage();
messageContext.setProperty(org.apache.axis.SOAPPart.ALLOW_FORM_OPTIMIZATION, Boolean.TRUE);
if (message != null) {
message.saveChanges();
}
try {
Message reqMsg = messageContext.getRequestMessage();
SOAPEnvelope requestEnvelope = reqMsg.getSOAPEnvelope();
RPCElement body = getBody(requestEnvelope, messageContext);
body.setNeedDeser(true);
Vector args = null;
try {
args = body.getParams();
} catch (SAXException e) {
if (e.getException() != null) {
throw e.getException();
}
throw e;
}
Object[] argValues = new Object[operation.getNumParams()];
for (int i = 0; i < args.size(); i++) {
RPCParam rpcParam = (RPCParam) args.get(i);
Object value = rpcParam.getObjectValue();
ParameterDesc paramDesc = rpcParam.getParamDesc();
if (paramDesc != null && paramDesc.getJavaType() != null) {
value = JavaUtils.convert(value, paramDesc.getJavaType());
rpcParam.setObjectValue(value);
}
int order = (paramDesc == null || paramDesc.getOrder() == -1) ? i : paramDesc.getOrder();
argValues[order] = value;
}
return argValues;
} finally {
messageContext.setProperty(org.apache.axis.SOAPPart.ALLOW_FORM_OPTIMIZATION, Boolean.FALSE);
}
}