Polish URL Cleanup

This commit is contained in:
Rob Winch
2019-03-21 23:47:38 -05:00
parent d99edd154f
commit 263868f018
39 changed files with 162 additions and 154 deletions

View File

@@ -45,11 +45,11 @@ import org.springframework.util.StringUtils;
*/
abstract class AbstractStaxXMLReader extends AbstractXMLReader {
private static final String NAMESPACES_FEATURE_NAME = "http://www.xml.org/sax/features/namespaces";
private static final String NAMESPACES_FEATURE_NAME = "http://xml.org/sax/features/namespaces";
private static final String NAMESPACE_PREFIXES_FEATURE_NAME = "http://www.xml.org/sax/features/namespace-prefixes";
private static final String NAMESPACE_PREFIXES_FEATURE_NAME = "http://xml.org/sax/features/namespace-prefixes";
private static final String IS_STANDALONE_FEATURE_NAME = "http://www.xml.org/sax/features/is-standalone";
private static final String IS_STANDALONE_FEATURE_NAME = "http://xml.org/sax/features/is-standalone";
private boolean namespacesFeature = true;
@@ -101,14 +101,14 @@ abstract class AbstractStaxXMLReader extends AbstractXMLReader {
}
/**
* Indicates whether the SAX feature {@code http://www.xml.org/sax/features/namespaces} is turned on.
* Indicates whether the SAX feature {@code http://xml.org/sax/features/namespaces} is turned on.
*/
protected boolean hasNamespacesFeature() {
return this.namespacesFeature;
}
/**
* Indicates whether the SAX feature {@code http://www.xml.org/sax/features/namespaces-prefixes} is turned on.
* Indicates whether the SAX feature {@code http://xml.org/sax/features/namespaces-prefixes} is turned on.
*/
protected boolean hasNamespacePrefixesFeature() {
return this.namespacePrefixesFeature;

View File

@@ -109,12 +109,12 @@ abstract class AbstractXMLReader implements XMLReader {
/**
* This implementation throws a {@code SAXNotRecognizedException} exception
* for any feature outside of the "http://www.xml.org/sax/features/" namespace
* for any feature outside of the "http://xml.org/sax/features/" namespace
* and returns {@code false} for any feature within.
*/
@Override
public boolean getFeature(String name) throws SAXNotRecognizedException, SAXNotSupportedException {
if (name.startsWith("http://www.xml.org/sax/features/")) {
if (name.startsWith("http://xml.org/sax/features/")) {
return false;
}
else {
@@ -124,12 +124,12 @@ abstract class AbstractXMLReader implements XMLReader {
/**
* This implementation throws a {@code SAXNotRecognizedException} exception
* for any feature outside of the "http://www.xml.org/sax/features/" namespace
* for any feature outside of the "http://xml.org/sax/features/" namespace
* and accepts a {@code false} value for any feature within.
*/
@Override
public void setFeature(String name, boolean value) throws SAXNotRecognizedException, SAXNotSupportedException {
if (name.startsWith("http://www.xml.org/sax/features/")) {
if (name.startsWith("http://xml.org/sax/features/")) {
if (value) {
throw new SAXNotSupportedException(name);
}
@@ -141,12 +141,12 @@ abstract class AbstractXMLReader implements XMLReader {
/**
* Throws a {@code SAXNotRecognizedException} exception when the given property does not signify a lexical
* handler. The property name for a lexical handler is {@code http://www.xml.org/sax/properties/lexical-handler}.
* handler. The property name for a lexical handler is {@code http://xml.org/sax/properties/lexical-handler}.
*/
@Override
@Nullable
public Object getProperty(String name) throws SAXNotRecognizedException, SAXNotSupportedException {
if ("http://www.xml.org/sax/properties/lexical-handler".equals(name)) {
if ("http://xml.org/sax/properties/lexical-handler".equals(name)) {
return this.lexicalHandler;
}
else {
@@ -156,11 +156,11 @@ abstract class AbstractXMLReader implements XMLReader {
/**
* Throws a {@code SAXNotRecognizedException} exception when the given property does not signify a lexical
* handler. The property name for a lexical handler is {@code http://www.xml.org/sax/properties/lexical-handler}.
* handler. The property name for a lexical handler is {@code http://xml.org/sax/properties/lexical-handler}.
*/
@Override
public void setProperty(String name, Object value) throws SAXNotRecognizedException, SAXNotSupportedException {
if ("http://www.xml.org/sax/properties/lexical-handler".equals(name)) {
if ("http://xml.org/sax/properties/lexical-handler".equals(name)) {
this.lexicalHandler = (LexicalHandler) value;
}
else {