You are viewing a plain text version of this content. The canonical link for it is here.
Posted to axis-cvs@ws.apache.org by da...@apache.org on 2006/12/15 20:21:56 UTC
svn commit: r487626 -
/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/addressing/wsdl/WSDL11ActionHelper.java
Author: davidillsley
Date: Fri Dec 15 11:21:55 2006
New Revision: 487626
URL: http://svn.apache.org/viewvc?view=rev&rev=487626
Log:
Add support for WSA-Final Namespace for wsaw:Action to support Muse 2.0 applications.
Modified:
webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/addressing/wsdl/WSDL11ActionHelper.java
Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/addressing/wsdl/WSDL11ActionHelper.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/addressing/wsdl/WSDL11ActionHelper.java?view=diff&rev=487626&r1=487625&r2=487626
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/addressing/wsdl/WSDL11ActionHelper.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/addressing/wsdl/WSDL11ActionHelper.java Fri Dec 15 11:21:55 2006
@@ -39,7 +39,10 @@
public class WSDL11ActionHelper {
private static final Log log = LogFactory.getLog(WSDL11ActionHelper.class);
-
+ private static final QName submissionWSAWNS = new QName(AddressingConstants.Submission.WSA_NAMESPACE, AddressingConstants.WSA_ACTION);
+ private static final QName finalWSANS = new QName(AddressingConstants.Final.WSA_NAMESPACE, AddressingConstants.WSA_ACTION);
+ private static final QName finalWSAWNS = new QName(AddressingConstants.Final.WSAW_NAMESPACE, AddressingConstants.WSA_ACTION);
+
/**
* getActionFromInputElement
* @param def the wsdl:definitions which contains the wsdl:portType
@@ -93,10 +96,15 @@
private static String getWSAWActionExtensionAttribute(AttributeExtensible ae){
// Search first for a wsaw:Action using the submission namespace
- Object attribute = ae.getExtensionAttribute(new QName(AddressingConstants.Submission.WSA_NAMESPACE, AddressingConstants.WSA_ACTION));
- // Then if that did no exist one using the w3c namespace
- if(attribute ==null){
- attribute = ae.getExtensionAttribute(new QName(AddressingConstants.Final.WSAW_NAMESPACE, AddressingConstants.WSA_ACTION));
+ Object attribute = ae.getExtensionAttribute(submissionWSAWNS);
+ // Then if that did not exist one using the w3c namespace
+ if(attribute == null){
+ attribute = ae.getExtensionAttribute(finalWSAWNS);
+ }
+ // Then finally if that did not exist, try the 2005/08 NS
+ // (Included here because it's needed for Apache Muse)
+ if(attribute == null){
+ attribute = ae.getExtensionAttribute(finalWSANS);
}
// wsdl4j may return a String, QName or a List of either
@@ -117,15 +125,15 @@
attribute = qn.getLocalPart();
}
- if(!(attribute instanceof String)){
+ if((attribute instanceof String)) {
+ String result = (String)attribute;
+ log.trace(result);
+ return result;
+ } else {
if(log.isTraceEnabled()){
log.trace("No wsaw:Action attribute found");
}
return null;
- }else{
- String result = (String)attribute;
- log.trace(result);
- return result;
}
}
}
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org