8077332: tidy warnings from javax/xml

Some HTML markup fix (jaxp part)

Reviewed-by: joehw, lancea
This commit is contained in:
Alexander Stepanov 2015-04-21 20:01:21 +04:00
parent 7cbdcf978d
commit b27f042010
30 changed files with 1381 additions and 1412 deletions

View file

@ -32,7 +32,7 @@ import org.xml.sax.InputSource;
/**
* {@code XPath} provides access to the XPath evaluation environment and expressions.
*
* <a name="XPath-evaluation"/>
* <a name="XPath-evaluation"></a>
* <table border="1" cellpadding="2">
* <thead>
* <tr>
@ -90,7 +90,6 @@ import org.xml.sax.InputSource;
* more than one thread at any given time, and while the {@code evaluate}
* method is invoked, applications may not recursively call
* the {@code evaluate} method.
* <p>
*
* @author <a href="Norman.Walsh@Sun.com">Norman Walsh</a>
* @author <a href="Jeff.Suttor@Sun.com">Jeff Suttor</a>
@ -462,7 +461,6 @@ public interface XPath {
* <pre> {@code
* evaluateExpression(expression, item, XPathEvaluationResult.class);
* }</pre>
* <p>
*
* @implSpec
* The default implementation in the XPath API is equivalent to:

View file

@ -32,7 +32,6 @@ import org.w3c.dom.Node;
* evaluation of an XPath expression within the context of a particular node.
* The evaluation of an XPath expression can result in various result types as
* defined in XML Path Language (XPath) Version 1.0.
* <p>
*
* @param <T> the object type returned by the XPath evaluation.
* @see <a href="http://www.w3.org/TR/xpath">XML Path Language (XPath) Version
@ -121,7 +120,7 @@ public interface XPathEvaluationResult<T> {
public XPathResultType type();
/**
* Returns the value of the result as the type &lt;T&gt; specified for the class.
* Returns the value of the result as the type {@code <T>} specified for the class.
*
* @return The value of the result.
*/

View file

@ -33,7 +33,7 @@ import java.io.ObjectStreamField;
import java.io.InvalidClassException;
/**
* <code>XPathException</code> represents a generic XPath exception.</p>
* {@code XPathException} represents a generic XPath exception.
*
* @author <a href="Norman.Walsh@Sun.com">Norman Walsh</a>
* @author <a href="mailto:Jeff.Suttor@Sun.COM">Jeff Suttor</a>
@ -46,23 +46,23 @@ public class XPathException extends Exception {
};
/**
* <p>Stream Unique Identifier.</p>
* Stream Unique Identifier.
*/
private static final long serialVersionUID = -1837080260374986980L;
/**
* <p>Constructs a new <code>XPathException</code>
* with the specified detail <code>message</code>.</p>
* Constructs a new {@code XPathException}
* with the specified detail {@code message}.
*
* <p>The <code>cause</code> is not initialized.</p>
* <p>The {@code cause} is not initialized.
*
* <p>If <code>message</code> is <code>null</code>,
* then a <code>NullPointerException</code> is thrown.</p>
* <p>If {@code message} is {@code null},
* then a {@code NullPointerException} is thrown.
*
* @param message The detail message.
*
* @throws NullPointerException When <code>message</code> is
* <code>null</code>.
* @throws NullPointerException When {@code message} is
* {@code null}.
*/
public XPathException(String message) {
super(message);
@ -72,15 +72,15 @@ public class XPathException extends Exception {
}
/**
* <p>Constructs a new <code>XPathException</code>
* with the specified <code>cause</code>.</p>
* Constructs a new {@code XPathException}
* with the specified {@code cause}.
*
* <p>If <code>cause</code> is <code>null</code>,
* then a <code>NullPointerException</code> is thrown.</p>
* <p>If {@code cause} is {@code null},
* then a {@code NullPointerException} is thrown.
*
* @param cause The cause.
*
* @throws NullPointerException if <code>cause</code> is <code>null</code>.
* @throws NullPointerException if {@code cause} is {@code null}.
*/
public XPathException(Throwable cause) {
super(cause);
@ -90,7 +90,7 @@ public class XPathException extends Exception {
}
/**
* <p>Get the cause of this XPathException.</p>
* Get the cause of this XPathException.
*
* @return Cause of this XPathException.
*/
@ -103,7 +103,7 @@ public class XPathException extends Exception {
* The cause is got from the parent class.
*
* @param out stream used for serialization.
* @throws IOException thrown by <code>ObjectOutputStream</code>
* @throws IOException thrown by {@code ObjectOutputStream}
*
*/
private void writeObject(ObjectOutputStream out)
@ -120,8 +120,8 @@ public class XPathException extends Exception {
* done before.
*
* @param in stream used for deserialization
* @throws IOException thrown by <code>ObjectInputStream</code>
* @throws ClassNotFoundException thrown by <code>ObjectInputStream</code>
* @throws IOException thrown by {@code ObjectInputStream}
* @throws ClassNotFoundException thrown by {@code ObjectInputStream}
*/
private void readObject(ObjectInputStream in)
throws IOException, ClassNotFoundException
@ -139,9 +139,9 @@ public class XPathException extends Exception {
}
/**
* <p>Print stack trace to specified <code>PrintStream</code>.</p>
* Print stack trace to specified {@code PrintStream}.
*
* @param s Print stack trace to this <code>PrintStream</code>.
* @param s Print stack trace to this {@code PrintStream}.
*/
public void printStackTrace(java.io.PrintStream s) {
if (getCause() != null) {
@ -153,16 +153,16 @@ public class XPathException extends Exception {
}
/**
* <p>Print stack trace to <code>System.err</code>.</p>
* Print stack trace to {@code System.err}.
*/
public void printStackTrace() {
printStackTrace(System.err);
}
/**
* <p>Print stack trace to specified <code>PrintWriter</code>.</p>
* Print stack trace to specified {@code PrintWriter}.
*
* @param s Print stack trace to this <code>PrintWriter</code>.
* @param s Print stack trace to this {@code PrintWriter}.
*/
public void printStackTrace(PrintWriter s) {

View file

@ -29,9 +29,9 @@ import javax.xml.namespace.QName;
import org.xml.sax.InputSource;
/**
* <p>{@code XPathExpression} provides access to compiled XPath expressions.</p>
* {@code XPathExpression} provides access to compiled XPath expressions.
*
* <a name="XPathExpression-evaluation"/>
* <a name="XPathExpression-evaluation"></a>
* <table border="1" cellpadding="2">
* <thead>
* <tr>
@ -54,7 +54,7 @@ import org.xml.sax.InputSource;
* If the expression contains a variable reference, its value will be found through the {@link XPathVariableResolver}.
* An {@link XPathExpressionException} is raised if the variable resolver is undefined or
* the resolver returns {@code null} for the variable.
* The value of a variable must be immutable through the course of any single evaluation.</p>
* The value of a variable must be immutable through the course of any single evaluation.
* </td>
* </tr>
* <tr>
@ -62,7 +62,7 @@ import org.xml.sax.InputSource;
* <td>
* If the expression contains a function reference, the function will be found through the {@link XPathFunctionResolver}.
* An {@link XPathExpressionException} is raised if the function resolver is undefined or
* the function resolver returns {@code null} for the function.</p>
* the function resolver returns {@code null} for the function.
* </td>
* </tr>
* <tr>
@ -76,9 +76,10 @@ import org.xml.sax.InputSource;
* <td>
* This result of evaluating an expression is converted to an instance of the desired return type.
* Valid return types are defined in {@link XPathConstants}.
* Conversion to the return type follows XPath conversion rules.</p>
* Conversion to the return type follows XPath conversion rules.
* </td>
* </tr>
* </tbody>
* </table>
*
* <p>An XPath expression is not thread-safe and not reentrant.
@ -87,7 +88,6 @@ import org.xml.sax.InputSource;
* more than one thread at any given time, and while the {@code evaluate}
* method is invoked, applications may not recursively call
* the {@code evaluate} method.
* <p>
*
* @author <a href="mailto:Norman.Walsh@Sun.com">Norman Walsh</a>
* @author <a href="mailto:Jeff.Suttor@Sun.com">Jeff Suttor</a>
@ -98,10 +98,10 @@ public interface XPathExpression {
/**
* <p>Evaluate the compiled XPath expression in the specified context and return the result as the specified type.</p>
* Evaluate the compiled XPath expression in the specified context and return the result as the specified type.
*
* <p>See <a href="#XPathExpression-evaluation">Evaluation of XPath Expressions</a> for context item evaluation,
* variable, function and QName resolution and return type conversion.</p>
* variable, function and QName resolution and return type conversion.
*
* <p>
* The parameter {@code item} represents the context the XPath expression
@ -126,13 +126,13 @@ public interface XPathExpression {
throws XPathExpressionException;
/**
* <p>Evaluate the compiled XPath expression in the specified context and return the result as a {@code String}.</p>
* Evaluate the compiled XPath expression in the specified context and return the result as a {@code String}.
*
* <p>This method calls {@link #evaluate(Object item, QName returnType)} with a {@code returnType} of
* {@link XPathConstants#STRING}.</p>
* {@link XPathConstants#STRING}.
*
* <p>See <a href="#XPathExpression-evaluation">Evaluation of XPath Expressions</a> for context item evaluation,
* variable, function and QName resolution and return type conversion.</p>
* variable, function and QName resolution and return type conversion.
*
* <p>
* The parameter {@code item} represents the context the XPath expression
@ -153,20 +153,21 @@ public interface XPathExpression {
throws XPathExpressionException;
/**
* <p>Evaluate the compiled XPath expression in the context of the specified {@code InputSource} and return the result as the
* specified type.</p>
* Evaluate the compiled XPath expression in the context
* of the specified {@code InputSource} and return the result as the
* specified type.
*
* <p>This method builds a data model for the {@link InputSource} and calls
* {@link #evaluate(Object item, QName returnType)} on the resulting document object.</p>
* {@link #evaluate(Object item, QName returnType)} on the resulting document object.
*
* <p>See <a href="#XPathExpression-evaluation">Evaluation of XPath Expressions</a> for context item evaluation,
* variable, function and QName resolution and return type conversion.</p>
* variable, function and QName resolution and return type conversion.
*
* <p>If {@code returnType} is not one of the types defined in {@link XPathConstants},
* then an {@code IllegalArgumentException} is thrown.</p>
* then an {@code IllegalArgumentException} is thrown.
*
* <p>If {@code source} or {@code returnType} is {@code null},
* then a {@code NullPointerException} is thrown.</p>
* then a {@code NullPointerException} is thrown.
*
* @param source The {@code InputSource} of the document to evaluate over.
* @param returnType The desired return type.
@ -182,16 +183,17 @@ public interface XPathExpression {
throws XPathExpressionException;
/**
* <p>Evaluate the compiled XPath expression in the context of the specified {@code InputSource} and return the result as a
* {@code String}.</p>
* Evaluate the compiled XPath expression in the context
* of the specified {@code InputSource} and return the result as a
* {@code String}.
*
* <p>This method calls {@link #evaluate(InputSource source, QName returnType)} with a {@code returnType} of
* {@link XPathConstants#STRING}.</p>
* {@link XPathConstants#STRING}.
*
* <p>See <a href="#XPathExpression-evaluation">Evaluation of XPath Expressions</a> for context item evaluation,
* variable, function and QName resolution and return type conversion.</p>
* variable, function and QName resolution and return type conversion.
*
* <p>If {@code source} is {@code null}, then a {@code NullPointerException} is thrown.</p>
* <p>If {@code source} is {@code null}, then a {@code NullPointerException} is thrown.
*
* @param source The {@code InputSource} of the document to evaluate over.
*
@ -351,7 +353,6 @@ public interface XPathExpression {
* <pre> {@code
* evaluateExpression(source, XPathEvaluationResult.class);
* }</pre>
* <p>
*
* @implSpec
* The default implementation in the XPath API is equivalent to:

View file

@ -26,7 +26,7 @@
package javax.xml.xpath;
/**
* <code>XPathExpressionException</code> represents an error in an XPath expression.</p>
* {@code XPathExpressionException} represents an error in an XPath expression.
*
* @author <a href="mailto:Norman.Walsh@Sun.com">Norman Walsh</a>
* @author <a href="mailto:Jeff.Suttor@Sun.com">Jeff Suttor</a>
@ -35,38 +35,38 @@ package javax.xml.xpath;
public class XPathExpressionException extends XPathException {
/**
* <p>Stream Unique Identifier.</p>
* Stream Unique Identifier.
*/
private static final long serialVersionUID = -1837080260374986980L;
/**
* <p>Constructs a new <code>XPathExpressionException</code>
* with the specified detail <code>message</code>.</p>
* Constructs a new {@code XPathExpressionException}
* with the specified detail {@code message}.
*
* <p>The <code>cause</code> is not initialized.</p>
* <p>The {@code cause} is not initialized.
*
* <p>If <code>message</code> is <code>null</code>,
* then a <code>NullPointerException</code> is thrown.</p>
* <p>If {@code message} is {@code null},
* then a {@code NullPointerException} is thrown.
*
* @param message The detail message.
*
* @throws NullPointerException When <code>message</code> is
* <code>null</code>.
* @throws NullPointerException When {@code message} is
* {@code null}.
*/
public XPathExpressionException(String message) {
super(message);
}
/**
* <p>Constructs a new <code>XPathExpressionException</code>
* with the specified <code>cause</code>.</p>
* Constructs a new {@code XPathExpressionException}
* with the specified {@code cause}.
*
* <p>If <code>cause</code> is <code>null</code>,
* then a <code>NullPointerException</code> is thrown.</p>
* <p>If {@code cause} is {@code null},
* then a {@code NullPointerException} is thrown.
*
* @param cause The cause.
*
* @throws NullPointerException if <code>cause</code> is <code>null</code>.
* @throws NullPointerException if {@code cause} is {@code null}.
*/
public XPathExpressionException(Throwable cause) {
super(cause);

View file

@ -26,7 +26,8 @@
package javax.xml.xpath;
/**
* <code>XPathFactoryConfigurationException</code> represents a configuration error in a <code>XPathFactory</code> environment.</p>
* {@code XPathFactoryConfigurationException} represents
* a configuration error in a {@code XPathFactory} environment.
*
* @author <a href="mailto:Norman.Walsh@Sun.com">Norman Walsh</a>
* @author <a href="mailto:Jeff.Suttor@Sun.com">Jeff Suttor</a>
@ -35,37 +36,38 @@ package javax.xml.xpath;
public class XPathFactoryConfigurationException extends XPathException {
/**
* <p>Stream Unique Identifier.</p>
* Stream Unique Identifier.
*/
private static final long serialVersionUID = -1837080260374986980L;
/**
* <p>Constructs a new <code>XPathFactoryConfigurationException</code> with the specified detail <code>message</code>.</p>
* Constructs a new {@code XPathFactoryConfigurationException}
* with the specified detail {@code message}.
*
* <p>The <code>cause</code> is not initialized.</p>
* <p>The {@code cause} is not initialized.
*
* <p>If <code>message</code> is <code>null</code>,
* then a <code>NullPointerException</code> is thrown.</p>
* <p>If {@code message} is {@code null},
* then a {@code NullPointerException} is thrown.
*
* @param message The detail message.
*
* @throws NullPointerException When <code>message</code> is
* <code>null</code>.
* @throws NullPointerException When {@code message} is
* {@code null}.
*/
public XPathFactoryConfigurationException(String message) {
super(message);
}
/**
* <p>Constructs a new <code>XPathFactoryConfigurationException</code>
* with the specified <code>cause</code>.</p>
* Constructs a new {@code XPathFactoryConfigurationException}
* with the specified {@code cause}.
*
* <p>If <code>cause</code> is <code>null</code>,
* then a <code>NullPointerException</code> is thrown.</p>
* <p>If {@code cause} is {@code null},
* then a {@code NullPointerException} is thrown.
*
* @param cause The cause.
*
* @throws NullPointerException if <code>cause</code> is <code>null</code>.
* @throws NullPointerException if {@code cause} is {@code null}.
*/
public XPathFactoryConfigurationException(Throwable cause) {
super(cause);

View file

@ -26,7 +26,7 @@
package javax.xml.xpath;
/**
* <code>XPathFunctionException</code> represents an error with an XPath function.</p>
* {@code XPathFunctionException} represents an error with an XPath function.
*
* @author <a href="mailto:Norman.Walsh@Sun.com">Norman Walsh</a>
* @author <a href="mailto:Jeff.Suttor@Sun.com">Jeff Suttor</a>
@ -35,36 +35,36 @@ package javax.xml.xpath;
public class XPathFunctionException extends XPathExpressionException {
/**
* <p>Stream Unique Identifier.</p>
* Stream Unique Identifier.
*/
private static final long serialVersionUID = -1837080260374986980L;
/**
* <p>Constructs a new <code>XPathFunctionException</code> with the specified detail <code>message</code>.</p>
* Constructs a new {@code XPathFunctionException} with the specified detail {@code message}.
*
* <p>The <code>cause</code> is not initialized.</p>
* <p>The {@code cause} is not initialized.
*
* <p>If <code>message</code> is <code>null</code>,
* then a <code>NullPointerException</code> is thrown.</p>
* <p>If {@code message} is {@code null},
* then a {@code NullPointerException} is thrown.
*
* @param message The detail message.
*
* @throws NullPointerException When <code>message</code> is
* <code>null</code>.
* @throws NullPointerException When {@code message} is
* {@code null}.
*/
public XPathFunctionException(String message) {
super(message);
}
/**
* <p>Constructs a new <code>XPathFunctionException</code> with the specified <code>cause</code>.</p>
* Constructs a new {@code XPathFunctionException} with the specified {@code cause}.
*
* <p>If <code>cause</code> is <code>null</code>,
* then a <code>NullPointerException</code> is thrown.</p>
* <p>If {@code cause} is {@code null},
* then a {@code NullPointerException} is thrown.
*
* @param cause The cause.
*
* @throws NullPointerException if <code>cause</code> is <code>null</code>.
* @throws NullPointerException if {@code cause} is {@code null}.
*/
public XPathFunctionException(Throwable cause) {
super(cause);

View file

@ -282,7 +282,6 @@ It is an XML document tree represented as a hierarchy of nodes, a
<h3>5. Using the XPath API</h3>
Consider the following XML document:
<p>
<blockquote>
<pre>
&lt;widgets&gt;
@ -366,7 +365,6 @@ The XPath 1.0 Number data type is defined as a double. However, the XPath
specification also provides functions that returns Integer type. To facilitate
such operations, the XPath API allows Integer and Long to be used in
{@code evaluateExpression} method such as the following code:
<p>
<blockquote>
<pre>
int count = xpath.evaluate("count(/widgets/widget)", document, Integer.class);