Added @since tags.
This commit is contained in:
@@ -26,6 +26,7 @@ import org.springframework.util.ClassUtils;
|
||||
* classes.
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @since 1.0
|
||||
*/
|
||||
public abstract class JaxpVersion {
|
||||
|
||||
|
||||
@@ -22,6 +22,7 @@ import org.springframework.core.NestedRuntimeException;
|
||||
* Root of the hierarchy of XML exception.
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @since 1.0
|
||||
*/
|
||||
public abstract class XmlException extends NestedRuntimeException {
|
||||
|
||||
|
||||
@@ -34,6 +34,7 @@ import org.xml.sax.helpers.DefaultHandler;
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @see org.w3c.dom.Node
|
||||
* @since 1.0
|
||||
*/
|
||||
public class DomContentHandler extends DefaultHandler {
|
||||
|
||||
|
||||
@@ -43,6 +43,7 @@ import org.springframework.util.StringUtils;
|
||||
* @see javax.xml.namespace.QName
|
||||
* @see javax.xml.namespace.QName#toString()
|
||||
* @see javax.xml.namespace.QName#valueOf(String)
|
||||
* @since 1.0
|
||||
*/
|
||||
public class QNameEditor extends PropertyEditorSupport {
|
||||
|
||||
|
||||
@@ -27,6 +27,7 @@ import org.w3c.dom.Node;
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @see javax.xml.namespace.QName
|
||||
* @since 1.0
|
||||
*/
|
||||
public abstract class QNameUtils {
|
||||
|
||||
|
||||
@@ -33,14 +33,13 @@ import org.springframework.util.Assert;
|
||||
* <code>java.util.Properties</code> object
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @since 1.0
|
||||
*/
|
||||
public class SimpleNamespaceContext implements NamespaceContext {
|
||||
|
||||
private Map prefixToNamespaceUri = new HashMap();
|
||||
|
||||
/**
|
||||
* Maps a <code>String</code> namespaceUri to a <code>List</code> of prefixes
|
||||
*/
|
||||
/** Maps a <code>String</code> namespaceUri to a <code>List</code> of prefixes */
|
||||
private Map namespaceUriToPrefixes = new HashMap();
|
||||
|
||||
private String defaultNamespaceUri = "";
|
||||
@@ -110,9 +109,7 @@ public class SimpleNamespaceContext implements NamespaceContext {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Removes all declared prefixes.
|
||||
*/
|
||||
/** Removes all declared prefixes. */
|
||||
public void clear() {
|
||||
prefixToNamespaceUri.clear();
|
||||
}
|
||||
|
||||
@@ -33,6 +33,7 @@ import org.xml.sax.ext.LexicalHandler;
|
||||
* @see #setDTDHandler(org.xml.sax.DTDHandler)
|
||||
* @see #setEntityResolver(org.xml.sax.EntityResolver)
|
||||
* @see #setErrorHandler(org.xml.sax.ErrorHandler)
|
||||
* @since 1.0
|
||||
*/
|
||||
public abstract class AbstractXmlReader implements XMLReader {
|
||||
|
||||
|
||||
@@ -25,6 +25,7 @@ import org.xml.sax.InputSource;
|
||||
* Convenient utility methods for dealing with SAX.
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @since 1.0
|
||||
*/
|
||||
public abstract class SaxUtils {
|
||||
|
||||
|
||||
@@ -31,6 +31,7 @@ import org.xml.sax.SAXException;
|
||||
* namespace context is used to keep track of declared namespaces.
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @since 1.0
|
||||
*/
|
||||
public abstract class AbstractStaxContentHandler implements ContentHandler {
|
||||
|
||||
|
||||
@@ -34,6 +34,7 @@ import org.xml.sax.SAXParseException;
|
||||
* @see #setDTDHandler(org.xml.sax.DTDHandler)
|
||||
* @see #setEntityResolver(org.xml.sax.EntityResolver)
|
||||
* @see #setErrorHandler(org.xml.sax.ErrorHandler)
|
||||
* @since 1.0
|
||||
*/
|
||||
public abstract class AbstractStaxXmlReader extends AbstractXmlReader {
|
||||
|
||||
|
||||
@@ -27,6 +27,7 @@ import org.springframework.util.Assert;
|
||||
* Abstract base class for <code>XMLStreamReader</code>s.
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @since 1.0
|
||||
*/
|
||||
public abstract class AbstractXmlStreamReader implements XMLStreamReader {
|
||||
|
||||
|
||||
@@ -40,6 +40,7 @@ import org.xml.sax.Locator;
|
||||
* @author Arjen Poutsma
|
||||
* @see XMLEvent
|
||||
* @see XMLEventConsumer
|
||||
* @since 1.0
|
||||
*/
|
||||
public class StaxEventContentHandler extends AbstractStaxContentHandler {
|
||||
|
||||
|
||||
@@ -45,6 +45,7 @@ import org.xml.sax.helpers.AttributesImpl;
|
||||
* @see #setDTDHandler(org.xml.sax.DTDHandler)
|
||||
* @see #setEntityResolver(org.xml.sax.EntityResolver)
|
||||
* @see #setErrorHandler(org.xml.sax.ErrorHandler)
|
||||
* @since 1.0
|
||||
*/
|
||||
public class StaxEventXmlReader extends AbstractStaxXmlReader {
|
||||
|
||||
|
||||
@@ -32,6 +32,7 @@ import org.xml.sax.Locator;
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @see XMLStreamWriter
|
||||
* @since 1.0
|
||||
*/
|
||||
public class StaxStreamContentHandler extends AbstractStaxContentHandler {
|
||||
|
||||
|
||||
@@ -36,6 +36,7 @@ import org.xml.sax.helpers.AttributesImpl;
|
||||
* @see #setDTDHandler(org.xml.sax.DTDHandler)
|
||||
* @see #setEntityResolver(org.xml.sax.EntityResolver)
|
||||
* @see #setErrorHandler(org.xml.sax.ErrorHandler)
|
||||
* @since 1.0
|
||||
*/
|
||||
public class StaxStreamXmlReader extends AbstractStaxXmlReader {
|
||||
|
||||
|
||||
@@ -34,6 +34,7 @@ import javax.xml.stream.events.XMLEvent;
|
||||
* vice-versa.
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @since 1.0
|
||||
*/
|
||||
public class XmlEventStreamReader extends AbstractXmlStreamReader {
|
||||
|
||||
|
||||
@@ -27,6 +27,7 @@ import org.springframework.xml.sax.SaxUtils;
|
||||
* set via the constructor.
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @since 1.0
|
||||
*/
|
||||
public class ResourceSource extends SAXSource {
|
||||
|
||||
|
||||
@@ -43,6 +43,7 @@ import org.xml.sax.ContentHandler;
|
||||
* @see XMLEventWriter
|
||||
* @see XMLStreamWriter
|
||||
* @see javax.xml.transform.Transformer
|
||||
* @since 1.0
|
||||
*/
|
||||
public class StaxResult extends SAXResult {
|
||||
|
||||
|
||||
@@ -43,6 +43,7 @@ import org.xml.sax.XMLReader;
|
||||
* @see XMLEventReader
|
||||
* @see XMLStreamReader
|
||||
* @see javax.xml.transform.Transformer
|
||||
* @since 1.0
|
||||
*/
|
||||
public class StaxSource extends SAXSource {
|
||||
|
||||
|
||||
@@ -17,7 +17,6 @@
|
||||
package org.springframework.xml.transform;
|
||||
|
||||
import java.io.StringWriter;
|
||||
|
||||
import javax.xml.transform.stream.StreamResult;
|
||||
|
||||
/**
|
||||
@@ -26,6 +25,7 @@ import javax.xml.transform.stream.StreamResult;
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @see #toString()
|
||||
* @since 1.0
|
||||
*/
|
||||
public class StringResult extends StreamResult {
|
||||
|
||||
@@ -33,9 +33,7 @@ public class StringResult extends StreamResult {
|
||||
super(new StringWriter());
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the written XML as a string.
|
||||
*/
|
||||
/** Returns the written XML as a string. */
|
||||
public String toString() {
|
||||
return getWriter().toString();
|
||||
}
|
||||
|
||||
@@ -17,7 +17,6 @@
|
||||
package org.springframework.xml.transform;
|
||||
|
||||
import java.io.StringReader;
|
||||
|
||||
import javax.xml.transform.stream.StreamSource;
|
||||
|
||||
/**
|
||||
@@ -25,6 +24,7 @@ import javax.xml.transform.stream.StreamSource;
|
||||
* can be set via the constructor.
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @since 1.0
|
||||
*/
|
||||
public class StringSource extends StreamSource {
|
||||
|
||||
|
||||
@@ -34,6 +34,7 @@ import org.apache.commons.logging.LogFactory;
|
||||
* @author Arjen Poutsma
|
||||
* @see Transformer
|
||||
* @see #createTransformer()
|
||||
* @since 1.0
|
||||
*/
|
||||
public abstract class TransformerObjectSupport {
|
||||
|
||||
|
||||
@@ -43,6 +43,7 @@ import org.xml.sax.helpers.DefaultHandler;
|
||||
* Internal class that uses JAXP 1.0 features to create <code>XmlValidator</code> instances.
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @since 1.0
|
||||
*/
|
||||
abstract class Jaxp10ValidatorFactory {
|
||||
|
||||
@@ -154,9 +155,7 @@ abstract class Jaxp10ValidatorFactory {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* <code>DefaultHandler</code> extension that stores errors and fatal errors in a list.
|
||||
*/
|
||||
/** <code>DefaultHandler</code> extension that stores errors and fatal errors in a list. */
|
||||
private static class ValidationErrorHandler extends DefaultHandler {
|
||||
|
||||
private List errors = new ArrayList();
|
||||
|
||||
@@ -31,6 +31,7 @@ import org.xml.sax.SAXParseException;
|
||||
* Internal class that uses JAXP 1.0 features to create <code>XmlValidator</code> instances.
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @since 1.0
|
||||
*/
|
||||
abstract class Jaxp13ValidatorFactory {
|
||||
|
||||
@@ -66,9 +67,7 @@ abstract class Jaxp13ValidatorFactory {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* <code>ErrorHandler</code> implementation that stores errors and fatal errors in a list.
|
||||
*/
|
||||
/** <code>ErrorHandler</code> implementation that stores errors and fatal errors in a list. */
|
||||
private static class ValidationErrorHandler implements ErrorHandler {
|
||||
|
||||
private List errors = new ArrayList();
|
||||
|
||||
@@ -31,6 +31,7 @@ import org.xml.sax.SAXException;
|
||||
* handling of input streams.
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @since 1.0
|
||||
*/
|
||||
public abstract class SchemaLoaderUtils {
|
||||
|
||||
@@ -85,9 +86,7 @@ public abstract class SchemaLoaderUtils {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Retrieves the URL from the given resource as System ID. Returns <code>null</code> if it cannot be openened.
|
||||
*/
|
||||
/** Retrieves the URL from the given resource as System ID. Returns <code>null</code> if it cannot be openened. */
|
||||
public static String getSystemId(Resource resource) {
|
||||
try {
|
||||
return resource.getURL().toString();
|
||||
|
||||
@@ -22,6 +22,7 @@ import org.springframework.xml.XmlException;
|
||||
* Expection thrown when a validation error occurs
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @since 1.0
|
||||
*/
|
||||
public class XmlValidationException extends XmlException {
|
||||
|
||||
|
||||
@@ -17,7 +17,6 @@
|
||||
package org.springframework.xml.validation;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
import javax.xml.transform.Source;
|
||||
|
||||
import org.xml.sax.SAXParseException;
|
||||
@@ -29,7 +28,8 @@ import org.xml.sax.SAXParseException;
|
||||
* <code>XmlValidator</code> instances are designed to be thread safe.
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @see XmlValidatorFactory#createValidator(org.springframework.core.io.Resource, String)
|
||||
* @see XmlValidatorFactory#createValidator(org.springframework.core.io.Resource,String)
|
||||
* @since 1.0
|
||||
*/
|
||||
public interface XmlValidator {
|
||||
|
||||
|
||||
@@ -33,6 +33,7 @@ import org.springframework.xml.JaxpVersion;
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @see XmlValidator
|
||||
* @since 1.0
|
||||
*/
|
||||
public abstract class XmlValidatorFactory {
|
||||
|
||||
|
||||
@@ -31,6 +31,7 @@ import org.w3c.dom.Node;
|
||||
* Abstract base class for implementations of {@link XPathOperations}. Contains a namespaces property.
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @since 1.0
|
||||
*/
|
||||
public abstract class AbstractXPathTemplate extends TransformerObjectSupport implements XPathOperations {
|
||||
|
||||
|
||||
@@ -32,6 +32,7 @@ import org.w3c.dom.Node;
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @see #createXPathExpression(String)
|
||||
* @since 1.0
|
||||
*/
|
||||
abstract class JaxenXPathExpressionFactory {
|
||||
|
||||
|
||||
@@ -36,6 +36,7 @@ import org.w3c.dom.Node;
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @see <a href="http://www.jaxen.org/">Jaxen</a>
|
||||
* @since 1.0
|
||||
*/
|
||||
public class JaxenXPathTemplate extends AbstractXPathTemplate {
|
||||
|
||||
|
||||
@@ -35,6 +35,7 @@ import org.w3c.dom.NodeList;
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @see #createXPathExpression(String)
|
||||
* @since 1.0
|
||||
*/
|
||||
abstract class Jaxp13XPathExpressionFactory {
|
||||
|
||||
|
||||
@@ -44,6 +44,7 @@ import org.xml.sax.InputSource;
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @see #setNamespaces(java.util.Properties)
|
||||
* @since 1.0
|
||||
*/
|
||||
public class Jaxp13XPathTemplate extends AbstractXPathTemplate {
|
||||
|
||||
|
||||
@@ -29,6 +29,7 @@ import org.w3c.dom.Node;
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @see XPathOperations#evaluate(String,javax.xml.transform.Source,NodeCallbackHandler)
|
||||
* @since 1.0
|
||||
*/
|
||||
public interface NodeCallbackHandler {
|
||||
|
||||
|
||||
@@ -29,6 +29,7 @@ import org.w3c.dom.Node;
|
||||
* @see XPathOperations#evaluateAsObject(String,javax.xml.transform.Source,NodeMapper)
|
||||
* @see XPathExpression#evaluate(org.w3c.dom.Node,NodeMapper)
|
||||
* @see XPathExpression#evaluateAsObject(org.w3c.dom.Node,NodeMapper)
|
||||
* @since 1.0
|
||||
*/
|
||||
public interface NodeMapper {
|
||||
|
||||
|
||||
@@ -22,6 +22,7 @@ import org.springframework.xml.XmlException;
|
||||
* Exception thrown when an error occurs during XPath processing.
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @since 1.0
|
||||
*/
|
||||
public class XPathException extends XmlException {
|
||||
|
||||
|
||||
@@ -28,6 +28,7 @@ import org.w3c.dom.Node;
|
||||
* used by {@link XPathOperations} implementations.
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @since 1.0
|
||||
*/
|
||||
public interface XPathExpression {
|
||||
|
||||
|
||||
@@ -34,6 +34,7 @@ import org.springframework.xml.JaxpVersion;
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @see XPathExpression
|
||||
* @since 1.0
|
||||
*/
|
||||
public abstract class XPathExpressionFactory {
|
||||
|
||||
|
||||
@@ -30,6 +30,7 @@ import org.springframework.util.Assert;
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @see #setExpression(String)
|
||||
* @since 1.0
|
||||
*/
|
||||
public class XPathExpressionFactoryBean implements FactoryBean, InitializingBean {
|
||||
|
||||
|
||||
@@ -31,6 +31,7 @@ import org.w3c.dom.Node;
|
||||
* @author Arjen Poutsma
|
||||
* @see Jaxp13XPathTemplate
|
||||
* @see JaxenXPathTemplate
|
||||
* @since 1.0
|
||||
*/
|
||||
public interface XPathOperations {
|
||||
|
||||
|
||||
@@ -20,6 +20,7 @@ package org.springframework.xml.xpath;
|
||||
* Exception throws when a XPath expression cannot be parsed.
|
||||
*
|
||||
* @author Arjen Poutsma
|
||||
* @since 1.0
|
||||
*/
|
||||
public class XPathParseException extends XPathException {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user