}
protected void processOperation(WSDLInterface wsdlInterface, WSDLBinding wsdlBinding, OperationMetaData operation)
{
WSDLInterfaceOperation interfaceOperation = new WSDLInterfaceOperation(wsdlInterface, operation.getQName());
WSDLBindingOperation bindingOperation = new WSDLBindingOperation(wsdlBinding);
interfaceOperation.setPattern(operation.isOneWay() ? Constants.WSDL20_PATTERN_IN_ONLY
: Constants.WSDL20_PATTERN_IN_OUT);
bindingOperation.setRef(operation.getQName());
bindingOperation.setSOAPAction(operation.getSOAPAction());
if (operation.getStyle() == Style.DOCUMENT)
processOperationDOC(interfaceOperation, bindingOperation, operation);
else
processOperationRPC(interfaceOperation, bindingOperation, operation);
for (FaultMetaData fault : operation.getFaults())
{
QName faultName = new QName(operation.getQName().getNamespaceURI(), fault.getXmlName().getLocalPart());
WSDLInterfaceFault interfaceFault = new WSDLInterfaceFault(wsdlInterface, faultName);
interfaceFault.setElement(fault.getXmlName());
wsdlInterface.addFault(interfaceFault);
WSDLInterfaceOperationOutfault outfault = new WSDLInterfaceOperationOutfault(interfaceOperation);
String ns = getNamespace(fault.getJavaType(), fault.getXmlName().getNamespaceURI());
QName outFaultName = new QName(ns, fault.getXmlName().getLocalPart());
outfault.setRef(outFaultName);
interfaceOperation.addOutfault(outfault);
WSDLBindingFault bindingFault = new WSDLBindingFault(wsdlBinding);
bindingFault.setRef(faultName);
wsdlBinding.addFault(bindingFault);
}