/** * Get the Soap Action URI from the operation's soap:operation extensiblity element. * * @param operation * A WSDL Operation. * @return Soap action URI as string, null if not defined. */ protected static String getSOAPAction( BindingOperation operation ) { ExtensibilityElement e = findExtensibilityElement( operation, SOAP_OPERATION_ELEMENT_NAME ); if ( e != null ) { if ( e instanceof SOAP12Operation ) { return ( (SOAP12Operation) e ).getSoapActionURI(); } else { return ( (SOAPOperation) e ).getSoapActionURI(); } } return null; }
soapOperation.getSoapActionURI(), pw); DOMUtils.printAttribute(SOAP12Constants.ATTR_SOAP_ACTION_REQUIRED,
/** * Returns the SOAP action related to an operation, or null if not specified. */ private String getSoapAction(BindingOperation bindingOperation) { List extensions = bindingOperation.getExtensibilityElements(); for (Object extension : extensions) { if (extension instanceof SOAPOperation) { return ((SOAPOperation) extension).getSoapActionURI(); } if (extension instanceof SOAP12Operation) { return ((SOAP12Operation) extension).getSoapActionURI(); } } return null; }
/** * Get the soapAction value for a given operation. * * @param operation The WSDL BindingOperation. * @return the soapAction value if it exists. */ public static String getSoapAction(final BindingOperation operation) { String soapActionUri = ""; if (operation != null) { List<ExtensibilityElement> extElements = operation.getExtensibilityElements(); for (ExtensibilityElement extElement : extElements) { if (extElement instanceof SOAPOperation) { soapActionUri = ((SOAPOperation) extElement).getSoapActionURI(); break; } else if (extElement instanceof SOAP12Operation) { SOAP12Operation soapOperation = ((SOAP12Operation) extElement); Boolean soapActionRequired = soapOperation.getSoapActionRequired(); if ((soapActionRequired == null) || soapActionRequired) { soapActionUri = soapOperation.getSoapActionURI(); } break; } } } return soapActionUri; }
protected String getSOAPAction(String operationName) { Binding binding = wsBinding.getBinding(); if (binding != null) { for (Object o : binding.getBindingOperations()) { BindingOperation bop = (BindingOperation)o; if (bop.getName().equalsIgnoreCase(operationName)) { for (Object o2 : bop.getExtensibilityElements()) { if (o2 instanceof SOAPOperation) { return ((SOAPOperation)o2).getSoapActionURI(); } else if (o2 instanceof SOAP12Operation) { return ((SOAP12Operation)o2).getSoapActionURI(); } } } } } return null; }
/** * Get the soapAction value for a given operation. * * @param operation The WSDL BindingOperation. * @return the soapAction value if it exists. */ public static String getSoapAction(final BindingOperation operation) { String soapActionUri = ""; if (operation != null) { List<ExtensibilityElement> extElements = operation.getExtensibilityElements(); for (ExtensibilityElement extElement : extElements) { if (extElement instanceof SOAPOperation) { soapActionUri = ((SOAPOperation) extElement).getSoapActionURI(); break; } else if (extElement instanceof SOAP12Operation) { SOAP12Operation soapOperation = ((SOAP12Operation) extElement); Boolean soapActionRequired = soapOperation.getSoapActionRequired(); if ((soapActionRequired == null) || soapActionRequired) { soapActionUri = soapOperation.getSoapActionURI(); } break; } } } return soapActionUri; }
} else if (extensibilityElement instanceof SOAP12Operation) { SOAP12Operation soap12Operation = (SOAP12Operation) extensibilityElement; String soapActionUri = soap12Operation.getSoapActionURI(); operationPolicy.setOperationAction(soapActionUri); operationPolicy.setSoapMessageVersionNamespace(WSSConstants.NS_SOAP12);
soapOperation.getSoapActionURI(), pw); DOMUtils.printAttribute(SOAP12Constants.ATTR_SOAP_ACTION_REQUIRED,
operation.setName(new QName(wsdlPortType.getQName().getNamespaceURI(), wsdlOperation.getName())); if (wsdlSoapOperation != null) { operation.setSoapAction(wsdlSoapOperation.getSoapActionURI()); operation.setStyle(getStyle(wsdlSoapOperation.getStyle())); } else {
destBindingOperation.setSOAPAction(soapOp.getSoapActionURI());
/** * Attempts to extract the SOAP Action is defined in the WSDL document. * * @param partnerMessageContext BPELMessageContext * @return the SOAPAction value if one is specified, otherwise empty string */ public static String getSoapAction(BPELMessageContext partnerMessageContext) { BindingOperation bop = partnerMessageContext.getWsdlBindingForCurrentMessageFlow(). getBindingOperation(partnerMessageContext.getOperationName(), null, null); if (bop == null) { return ""; } if (partnerMessageContext.isSoap12()) { for (SOAP12Operation soapOp : CollectionsX.filter(bop.getExtensibilityElements(), SOAP12Operation.class)) { return soapOp.getSoapActionURI(); } } else { for (SOAPOperation soapOp : CollectionsX.filter(bop.getExtensibilityElements(), SOAPOperation.class)) { return soapOp.getSoapActionURI(); } } return ""; }
String soapActionURI = soapOperation.getSoapActionURI();
String soapActionURI = soapOperation.getSoapActionURI();