commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mben...@apache.org
Subject svn commit: r541446 - /jakarta/commons/proper/jxpath/trunk/src/java/org/apache/commons/jxpath/ri/NamespaceResolver.java
Date Thu, 24 May 2007 22:04:40 GMT
Author: mbenson
Date: Thu May 24 15:04:39 2007
New Revision: 541446

URL: http://svn.apache.org/viewvc?view=rev&rev=541446
Log:
restore binary compat. w/ 1.2: JXPATH-85; javadoc

Modified:
    jakarta/commons/proper/jxpath/trunk/src/java/org/apache/commons/jxpath/ri/NamespaceResolver.java

Modified: jakarta/commons/proper/jxpath/trunk/src/java/org/apache/commons/jxpath/ri/NamespaceResolver.java
URL: http://svn.apache.org/viewvc/jakarta/commons/proper/jxpath/trunk/src/java/org/apache/commons/jxpath/ri/NamespaceResolver.java?view=diff&rev=541446&r1=541445&r2=541446
==============================================================================
--- jakarta/commons/proper/jxpath/trunk/src/java/org/apache/commons/jxpath/ri/NamespaceResolver.java
(original)
+++ jakarta/commons/proper/jxpath/trunk/src/java/org/apache/commons/jxpath/ri/NamespaceResolver.java
Thu May 24 15:04:39 2007
@@ -16,7 +16,6 @@
  */
 package org.apache.commons.jxpath.ri;
 
-
 import java.util.HashMap;
 import java.util.Iterator;
 import java.util.Map;
@@ -26,7 +25,7 @@
 import org.apache.commons.jxpath.ri.model.NodePointer;
 
 /**
- * The reference implementation of JXPathContext.
+ * Namespace resolver for JXPathContextReferenceImpl.
  *
  * @author Dmitri Plotnikov
  * @version $Revision$ $Date$
@@ -37,7 +36,18 @@
     protected HashMap reverseMap;
     protected NodePointer pointer;
     private boolean sealed;
-        
+
+    /**
+     * Create a new NamespaceResolver.
+     */
+    public NamespaceResolver() {
+        this(null);
+    }
+
+    /**
+     * Create a new NamespaceResolver.
+     * @param parent
+     */
     public NamespaceResolver(NamespaceResolver parent) {
         this.parent = parent;
     }
@@ -55,11 +65,16 @@
     
     /**
      * Register a namespace for the expression context.
+     * @param pointer the Pointer to set.
      */
     public void setNamespaceContextPointer(NodePointer pointer) {
         this.pointer = pointer;
     }
-    
+
+    /**
+     * Get the namespace context pointer.
+     * @return Pointer
+     */
     public Pointer getNamespaceContextPointer() {
         if (pointer == null && parent != null) {
             return parent.getNamespaceContextPointer();
@@ -87,7 +102,12 @@
         }
         return uri;
     }
-    
+
+    /**
+     * Get the prefix associated with the specifed namespace URI.
+     * @param namespaceURI the ns URI to check.
+     * @return String prefix
+     */
     public String getPrefix(String namespaceURI) {
         if (reverseMap == null) {
             reverseMap = new HashMap();
@@ -114,18 +134,29 @@
         }
         return prefix;
     }
-        
+
+    /**
+     * Learn whether this NamespaceResolver has been sealed.
+     * @return
+     */
     public boolean isSealed() {
         return sealed;
     }
-    
+
+    /**
+     * Seal this {@link NamespaceResolver}.
+     */
     public void seal() {
         sealed = true;
         if (parent != null) {
             parent.seal();
         }
     }
-    
+
+    /**
+     * {@inheritDoc}
+     * @see java.lang.Object#clone()
+     */
     public Object clone() {
         try {
             return super.clone();



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


Mime
View raw message