You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commons-dev@ws.apache.org by ch...@apache.org on 2006/07/26 08:15:18 UTC

svn commit: r425640 - /webservices/commons/trunk/modules/neethi/src/org/apache/ws/policy/util/OMPolicyReader.java

Author: chinthaka
Date: Tue Jul 25 23:15:17 2006
New Revision: 425640

URL: http://svn.apache.org/viewvc?rev=425640&view=rev
Log:
Deprecating getName() method of OMNamespace and adding getNamespaceURI() method, as per http://issues.apache.org/jira/browse/WSCOMMONS-16

Modified:
    webservices/commons/trunk/modules/neethi/src/org/apache/ws/policy/util/OMPolicyReader.java

Modified: webservices/commons/trunk/modules/neethi/src/org/apache/ws/policy/util/OMPolicyReader.java
URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/neethi/src/org/apache/ws/policy/util/OMPolicyReader.java?rev=425640&r1=425639&r2=425640&view=diff
==============================================================================
--- webservices/commons/trunk/modules/neethi/src/org/apache/ws/policy/util/OMPolicyReader.java (original)
+++ webservices/commons/trunk/modules/neethi/src/org/apache/ws/policy/util/OMPolicyReader.java Tue Jul 25 23:15:17 2006
@@ -23,11 +23,11 @@
 import org.apache.axiom.om.impl.llom.factory.OMXMLBuilderFactory;
 import org.apache.ws.policy.All;
 import org.apache.ws.policy.Assertion;
+import org.apache.ws.policy.ExactlyOne;
 import org.apache.ws.policy.Policy;
 import org.apache.ws.policy.PolicyConstants;
 import org.apache.ws.policy.PolicyReference;
 import org.apache.ws.policy.PrimitiveAssertion;
-import org.apache.ws.policy.ExactlyOne;
 
 import javax.xml.namespace.QName;
 import javax.xml.stream.XMLInputFactory;
@@ -66,7 +66,7 @@
 
 	private Assertion readAssertion(OMElement element) {
         
-		String namespace = element.getNamespace().getName();
+		String namespace = element.getNamespace().getNamespaceURI();
 		String localName = element.getLocalName();
 
 		if (!(namespace.equals(PolicyConstants.POLICY_NAMESPACE_URI))) {
@@ -144,7 +144,7 @@
 		while (childElements.hasNext()) {
 			OMElement childElement = (OMElement) childElements.next();
 
-			if (childElement.getNamespace().getName().equals(
+			if (childElement.getNamespace().getNamespaceURI().equals(
 					PolicyConstants.POLICY_NAMESPACE_URI)
 					&& childElement.getLocalName().equals(
 							PolicyConstants.POLICY)) {



---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: commons-dev-help@ws.apache.org