/** * Find the specified operation in the WSDL definition. * * @param operationName * Name of operation to find. * @return A WsdlOperation instance, null if operation can not be found in WSDL. */ public WsdlOperation getOperation( String operationName ) throws KettleStepException { // is the operation in the cache? if ( _operationCache.containsKey( operationName ) ) { return _operationCache.get( operationName ); } Binding b = _port.getBinding(); PortType pt = b.getPortType(); Operation op = pt.getOperation( operationName, null, null ); if ( op != null ) { try { WsdlOperation wop = new WsdlOperation( b, op, _wsdlTypes ); // cache the operation _operationCache.put( operationName, wop ); return wop; } catch ( KettleException kse ) { LogChannel.GENERAL.logError( "Could not retrieve WSDL Operator for operation name: " + operationName ); throw new KettleStepException( "Could not retrieve WSDL Operator for operation name: " + operationName, kse ); } } return null; }
Operation right = rightPortType.getOperation(left.getName(), null, null); if (right != null) { if (isDifferent(left, right)) {
Operation tempOp = pt.getOperation(name, inputName, outputName); Operation tempOp = pt.getOperation(name, inputName, outputName);
: null); op = portType.getOperation(name, inputName, outputName);
? (bindingOutput.getName() != null ? bindingOutput.getName() : Constants.NONE) : null); Operation op = portType.getOperation(name, inputName, outputName); op = portType.getOperation(name, null, null); op = portType.getOperation(name, null, outputName); op = portType.getOperation(name, inputName, null);
private void initializeInvocation() { __log.debug("Initializing BPELInvoker"); Interface interfaze = operation.getInterface(); if(interfaze instanceof WSDLInterface){ WSDLInterface wsdlInterface = null; wsdlInterface = (WSDLInterface) interfaze; // Fetch the service name from the service object - including the componentURI guarantees a unique service name String componentURI = component.getURI(); bpelServiceName = new QName( Base.SCA11_TUSCANY_NS, componentURI + service.getName() ); bpelOperationInputPart = (Part) wsdlInterface.getPortType().getOperation(bpelOperationName,null,null).getInput().getMessage().getParts().values().iterator().next(); bpelOperationOutputPart = (Part) wsdlInterface.getPortType().getOperation(bpelOperationName,null,null).getOutput().getMessage().getParts().values().iterator().next(); } } // end method initializeInvocation
public WSDLAwareMessage parseRequest() throws AxisFault { /** * I assume that local part of the Axis Operation's name is always equal to * the operation name in the WSDL. */ BindingOperation bindingOp = wsdlBinding.getBindingOperation( wsdlBinding.getPortType().getOperation( inMessageCtx.getAxisOperation().getName().getLocalPart(), null, null).getName(), null, null); if (bindingOp == null) { throw new AxisFault("WSDL binding operation not found for service: " + serviceName.getLocalPart() + " port: " + portName); } BindingInput bindingInput = bindingOp.getBindingInput(); if (bindingInput == null) { throw new AxisFault("BindingInput not found for service: " + serviceName.getLocalPart() + " port: " + portName); } return processMessageParts(bindingInput); }
private Message createResponseMessage(PartnerRoleMessageExchange partnerRoleMessageExchange, Operation operation, Element invocationResult) { Document dom = DOMUtils.newDocument(); String operationName = operation.getName(); Part bpelOperationOutputPart = (Part)((WSDLInterface)operation.getInterface()).getPortType().getOperation(operationName, null, null) .getOutput().getMessage().getParts().values().iterator().next(); Element contentMessage = dom.createElement("message"); Element contentPart = dom.createElement(bpelOperationOutputPart.getName()); contentPart.appendChild(dom.importNode(invocationResult, true)); contentMessage.appendChild(contentPart); dom.appendChild(contentMessage); if(__log.isDebugEnabled()) { __log.debug("Creating result message:"); __log.debug(">>>" + DOMUtils.domToString(dom.getDocumentElement())); } QName id = partnerRoleMessageExchange.getOperation().getOutput().getMessage().getQName(); Message response = partnerRoleMessageExchange.createMessage(id); response.setMessage(dom.getDocumentElement()); return response; }
private void addWSAActionHeader( SOAPHeader sh ) { // Create wsa:Action header which is required by ws-addressing spec String action = options.getAction(); if (action == null) { PortType portType = ((WSDLInterface)wsBinding.getBindingInterfaceContract().getInterface()).getPortType(); Operation op = portType.getOperation(wsdlOperationName.getLocalPart(), null, null); action = WSDL11ActionHelper.getActionFromInputElement(wsBinding.getGeneratedWSDLDocument(), portType, op, op.getInput()); } OMElement actionOM = sh.getOMFactory().createOMElement(QNAME_WSA_ACTION); actionOM.setText(action == null ? "" : action); sh.addChild(actionOM); } // end method addWSAActionHeader
private Operation findOperation(PortType portType, BindingOperation wsdl4jBindingOperation) { Operation op = wsdl4jBindingOperation.getOperation(); String input = null; if (op != null && op.getInput() != null) { input = op.getInput().getName(); if (":none".equals(input)) { input = null; } } String output = null; if (op != null && op.getOutput() != null) { output = op.getOutput().getName(); if (":none".equals(output)) { output = null; } } Operation op2 = portType.getOperation(op.getName(), input, output); return ((op2 == null) ? op : op2); }
private Operation findOperation(PortType portType, BindingOperation wsdl4jBindingOperation) { Operation op = wsdl4jBindingOperation.getOperation(); String input = null; if (op != null && op.getInput() != null) { input = op.getInput().getName(); if (":none".equals(input)) { input = null; } } String output = null; if (op != null && op.getOutput() != null) { output = op.getOutput().getName(); if (":none".equals(output)) { output = null; } } Operation op2 = portType.getOperation(op.getName(), input, output); return ((op2 == null) ? op : op2); }
Operation op = wsdlBinding.getPortType().getOperation(axisOperationName.getLocalPart(), null, null); String rpcWrapper = op.getName();
: bindingOutput.getName(); if (binding.getPortType().getOperation( opName, inputName, outputName) == null) { throw new IOException(Messages.getMessage("unmatchedOp",
private void processPort(JCasBuilder casBuilder, Port port, Selector selector) { if (!selector.port.equals(lastPort)) { // Add Service name to textualServiceRepresentation // This is used in the new version of the reader casBuilder.add("Port:", StopWord.class); casBuilder.add(" "); casBuilder.add(port.getName(), Field.class).setName(FIELD_PORT_NAME); casBuilder.add("\n"); processDocumentation(casBuilder, port.getDocumentationElement(), "", "Port Documentation", FIELD_PORT_DOCUMENTATION); lastPort = selector.port; } processOperation(casBuilder, port.getBinding().getPortType().getOperation( selector.operation, selector.input, selector.output)); }
private void addWSAActionHeader(SOAPHeader sh, String action) throws SOAPException { // Create wsa:Action header which is required by ws-addressing spec if (action == null) { PortType portType = ((WSDLInterface)wsBinding.getBindingInterfaceContract().getInterface()).getPortType(); javax.wsdl.Operation op = portType.getOperation(operation.getName(), null, null); action = getActionFromInputElement(wsBinding.getGeneratedWSDLDocument(), portType, op, op.getInput()); } // OMElement actionOM = // sh.getOMFactory().createOMElement(QNAME_WSA_ACTION); // actionOM.setText(action == null ? "" : action); // sh.addChild(actionOM); SOAPHeaderElement actionH = sh.addHeaderElement(QNAME_WSA_ACTION); actionH.setTextContent(action == null ? "" : action); } // end method addWSAActionHeader
boolean needRootNode = false; for (BindingOperation bo : bos) { Operation op = binding.getPortType().getOperation(bo.getName(), null, null); needRootNode = false; if (op.getInput().getMessage().getParts().size() == 0
public void reconcileReferences(boolean deep) { if (element != null) { Binding binding = (Binding)getContainer(); PortType portType = binding.getEPortType(); if (portType != null) { BindingInput input = getEBindingInput(); BindingOutput output = getEBindingOutput(); String inputName = input != null ? input.getName() : null; String outputName = output != null ? output.getName() : null; setOperation(portType.getOperation(getName(), inputName, outputName)); } } super.reconcileReferences(deep); } } //BindingOperationImpl
public javax.wsdl.Binding createBinding(WSDLBuilder builder, PortType portType) { Transport t = builder.getTransportManager().getTransport(getBindingId()); if (!(t instanceof WSDL11Transport)) return null; Definition def = builder.getDefinition(); javax.wsdl.Binding wbinding = def.createBinding(); wbinding.setQName( getName() ); wbinding.setPortType( portType ); wbinding.setUndefined(false); // add in soap:Body, et al wbinding.addExtensibilityElement(createSoapBinding()); for (Iterator oitr = getService().getServiceInfo().getOperations().iterator(); oitr.hasNext();) { OperationInfo op = (OperationInfo) oitr.next(); javax.wsdl.Operation wsdlOp = (javax.wsdl.Operation) portType.getOperation(op.getName(), null, null); javax.wsdl.BindingOperation bop = createBindingOperation(builder, wsdlOp, op); createHeaders(builder, op, bop); wbinding.addBindingOperation(bop); } def.addBinding(wbinding); return wbinding; }
javax.wsdl.Operation operation=_portType.getOperation(operationName, null, null); Element newresp = null; Element respelem = null;
_portType.getOperation(exchange.getContract(). getProviderOperation().getName(), null, null);