operation.setSOAPAction(info.operation.getSOAPAction());
boolean unwrappable = info.operation.isWrapped();
operation.setWrapped(unwrappable);
SOAPBody soapRequestBody = getSOAPRequestBody();
Message inputMessage = getInputMessage();
Request request = new Request(inputMessage, errReceiver);
SOAPBody soapResponseBody = getSOAPResponseBody();
Message outputMessage = getOutputMessage();
Response response = new Response(outputMessage, errReceiver);
// Process parameterOrder and get the parameterList
java.util.List<String> parameterList = getAsynParameterOrder();
List<Parameter> inParameters = null;
if (isOperationDocumentLiteral(styleAndUse)) {
inParameters = getRequestParameters(request, parameterList);
// outParameters = getResponseParameters(response);
// re-create parameterList with unwrapped parameters
if (unwrappable) {
List<String> unwrappedParameterList = new ArrayList<String>();
if (inputMessage != null) {
Iterator<MessagePart> parts = inputMessage.parts();
if (parts.hasNext()) {
MessagePart part = parts.next();
JAXBType jaxbType = getJAXBType(part);
List<JAXBProperty> memberList = jaxbType.getWrapperChildren();
Iterator<JAXBProperty> props = memberList.iterator();
while (props.hasNext()) {
JAXBProperty prop = props.next();
unwrappedParameterList.add(prop.getElementName().getLocalPart());
}
}
}
parameterList.clear();
parameterList.addAll(unwrappedParameterList);
}
} else if (isOperationRpcLiteral(styleAndUse)) {
String operationName = info.bindingOperation.getName();
Block reqBlock = null;
if (inputMessage != null) {
QName name = new QName(getRequestNamespaceURI(soapRequestBody), operationName);
RpcLitStructure rpcStruct = new RpcLitStructure(name, getJAXBModelBuilder().getJAXBModel());
rpcStruct.setJavaType(new JavaSimpleType("com.sun.xml.internal.ws.encoding.jaxb.RpcLitPayload", null));
reqBlock = new Block(name, rpcStruct, inputMessage);
request.addBodyBlock(reqBlock);
}
inParameters = createRpcLitRequestParameters(request, parameterList, reqBlock);
}
// add response blocks, we dont need to create respnse parameters, just blocks will be fine, lets
// copy them from sync optraions
//copy the response blocks from the sync operation
Iterator<Block> blocks = info.operation.getResponse().getBodyBlocks();
while (blocks.hasNext()) {
response.addBodyBlock(blocks.next());
}
blocks = info.operation.getResponse().getHeaderBlocks();
while (blocks.hasNext()) {
response.addHeaderBlock(blocks.next());
}
blocks = info.operation.getResponse().getAttachmentBlocks();
while (blocks.hasNext()) {
response.addAttachmentBlock(blocks.next());
}
List<MessagePart> outputParts = outputMessage.getParts();
// handle headers
int numOfOutMsgParts = outputParts.size();
if (numOfOutMsgParts == 1) {