@@ -49,7 +49,9 @@ public void reset() {
4949 }
5050
5151 /** Declares a new prefix. Typically called from within
52- * {@link org.xml.sax.ContextHandler#startPrefixMapping(java.lang.String, java.lang.String)}.
52+ * {@link org.xml.sax.ContentHandler#startPrefixMapping(String, String)}.
53+ * @param pPrefix The namespace prefix.
54+ * @param pURI The namespace URI.
5355 * @throws IllegalArgumentException Prefix or URI are null.
5456 */
5557 public void startPrefixMapping (String pPrefix , String pURI ) {
@@ -70,7 +72,8 @@ public void startPrefixMapping(String pPrefix, String pURI) {
7072
7173 /** Removes the declaration of the prefix, which has been defined
7274 * last. Typically called from within
73- * {@link org.xml.sax.ContextHandler#endPrefixMapping(java.lang.String)}.
75+ * {@link org.xml.sax.ContentHandler#endPrefixMapping(String)}.
76+ * @param pPrefix The namespace prefix.
7477 * @throws IllegalArgumentException The prefix is null.
7578 * @throws IllegalStateException The prefix is not the prefix, which
7679 * has been defined last. In other words, the calls to
@@ -94,10 +97,10 @@ public void endPrefixMapping(String pPrefix) {
9497 }
9598 }
9699
97- /** Given a prefix, returns the URI to which the prefix is
100+ /** <p> Given a prefix, returns the URI to which the prefix is
98101 * currently mapped or null, if there is no such mapping.</p>
99102 * <p><em>Note</em>: This methods behaviour is precisely
100- * defined by {@link NamespaceContext#getNamespaceURI(java.lang.String)}.
103+ * defined by {@link NamespaceContext#getNamespaceURI(java.lang.String)}</p> .
101104 * @param pPrefix The prefix in question
102105 */
103106 public String getNamespaceURI (String pPrefix ) {
@@ -157,7 +160,8 @@ public String getPrefix(String pURI) {
157160 * URL or null, if there is no such mapping. This method may be
158161 * used to find a possible prefix for an attributes namespace
159162 * URI. For elements you should use {@link #getPrefix(String)}.
160- * @param pURI Thhe namespace URI in question
163+ * @param pURI The namespace URI in question
164+ * @return the attribute prefix or null
161165 * @throws IllegalArgumentException The namespace URI is null.
162166 */
163167 public String getAttributePrefix (String pURI ) {
@@ -220,6 +224,9 @@ public Iterator getPrefixes(String pURI) {
220224 }
221225
222226 /** Returns whether a given prefix is currently declared.
227+ *
228+ * @param pPrefix the namespace prefix.
229+ * @return true if the prefix is declared, false otherwise.
223230 */
224231 public boolean isPrefixDeclared (String pPrefix ) {
225232 if (cachedURI != null ) {
@@ -245,6 +252,8 @@ public boolean isPrefixDeclared(String pPrefix) {
245252 * invoking
246253 * {@link org.xml.sax.ContentHandler#endElement(String, String, String)},
247254 * the state is restored by calling {@link #checkContext(int)}.
255+ *
256+ * @return the current number of assigned prefixes.
248257 */
249258 public int getContext () {
250259 return (prefixList == null ? 0 : prefixList .size ()) +
@@ -272,6 +281,9 @@ public int getContext() {
272281 * h.endPrefixMapping(prefix);
273282 * }
274283 * </pre>
284+ *
285+ * @param i the input state.
286+ * @return the prefix.
275287 */
276288 public String checkContext (int i ) {
277289 if (getContext () == i ) {
@@ -292,6 +304,8 @@ public String checkContext(int i) {
292304 * in the order of declaration. Duplicates are possible, if a
293305 * prefix has been assigned to more than one URI, or repeatedly to
294306 * the same URI.
307+ *
308+ * @return a list of all prefixes.
295309 */
296310 public List getPrefixes () {
297311 if (cachedPrefix == null ) {
0 commit comments