diff options
author | Robert Schuster <theBohemian@gmx.net> | 2008-03-04 17:39:58 +0000 |
---|---|---|
committer | Robert Schuster <theBohemian@gmx.net> | 2008-03-04 17:39:58 +0000 |
commit | 04846ffa0396d1c741d42e20aa99bb0e33ade518 (patch) | |
tree | 901b35935a61cf0584df2fdeddbf485f6ad4acaa | |
parent | 22e05c59dcbd7a1641d5c79104fde5a6d5a09c80 (diff) | |
download | classpath-04846ffa0396d1c741d42e20aa99bb0e33ade518.tar.gz |
Fixes an incompatibility with official StAX API.
2008-03-04 Robert Schuster <robertschuster@fsfe.org>
* gnu/xml/stream/AttributeImpl.java: Changed type field to String.
(getDTDType): Changed return type to String.
* gnu/xml/stream/XMLEventAllocatorImpl.java:
(allocate): Removed wrapping of string in QName object.
* gnu/xml/stream/XMLEventFactoryImpl.java:
(createAttribute(String, String)): Removed wrapping of string in
QName object.
(createAttribute(QName, String)): Dito.
(createAttribute(String, String, String, String)): Dito.
* javax/xml/stream/events/Attribute.java:
(getDTDType): Changed return type to String.
-rw-r--r-- | ChangeLog | 14 | ||||
-rw-r--r-- | gnu/xml/stream/AttributeImpl.java | 6 | ||||
-rw-r--r-- | gnu/xml/stream/XMLEventAllocatorImpl.java | 2 | ||||
-rw-r--r-- | gnu/xml/stream/XMLEventFactoryImpl.java | 6 | ||||
-rw-r--r-- | javax/xml/stream/events/Attribute.java | 2 |
5 files changed, 22 insertions, 8 deletions
@@ -1,3 +1,17 @@ +2008-03-04 Robert Schuster <robertschuster@fsfe.org> + + * gnu/xml/stream/AttributeImpl.java: Changed type field to String. + (getDTDType): Changed return type to String. + * gnu/xml/stream/XMLEventAllocatorImpl.java: + (allocate): Removed wrapping of string in QName object. + * gnu/xml/stream/XMLEventFactoryImpl.java: + (createAttribute(String, String)): Removed wrapping of string in + QName object. + (createAttribute(QName, String)): Dito. + (createAttribute(String, String, String, String)): Dito. + * javax/xml/stream/events/Attribute.java: + (getDTDType): Changed return type to String. + 2008-03-03 Andrew John Hughes <gnu_andrew@member.fsf.org> * java/lang/reflect/Constructor.java, diff --git a/gnu/xml/stream/AttributeImpl.java b/gnu/xml/stream/AttributeImpl.java index 501575e56..f74aebd35 100644 --- a/gnu/xml/stream/AttributeImpl.java +++ b/gnu/xml/stream/AttributeImpl.java @@ -56,11 +56,11 @@ public class AttributeImpl protected final QName name; protected final String value; - protected final QName type; + protected final String type; protected final boolean specified; protected AttributeImpl(Location location, - QName name, String value, QName type, + QName name, String value, String type, boolean specified) { super(location); @@ -85,7 +85,7 @@ public class AttributeImpl return value; } - public QName getDTDType() + public String getDTDType() { return type; } diff --git a/gnu/xml/stream/XMLEventAllocatorImpl.java b/gnu/xml/stream/XMLEventAllocatorImpl.java index 666bffabe..fb1e4c28c 100644 --- a/gnu/xml/stream/XMLEventAllocatorImpl.java +++ b/gnu/xml/stream/XMLEventAllocatorImpl.java @@ -165,7 +165,7 @@ public class XMLEventAllocatorImpl attributes.add(new AttributeImpl(location, reader.getAttributeName(i), reader.getAttributeValue(i), - QName.valueOf(reader.getAttributeType(i)), + reader.getAttributeType(i), reader.isAttributeSpecified(i))); return new StartElementImpl(location, reader.getName(), diff --git a/gnu/xml/stream/XMLEventFactoryImpl.java b/gnu/xml/stream/XMLEventFactoryImpl.java index e1d7d6ab8..f694753c4 100644 --- a/gnu/xml/stream/XMLEventFactoryImpl.java +++ b/gnu/xml/stream/XMLEventFactoryImpl.java @@ -79,20 +79,20 @@ public class XMLEventFactoryImpl { return new AttributeImpl(location, new QName(namespaceURI, localName, prefix), - value, QName.valueOf("CDATA"), true); + value, "CDATA", true); } public Attribute createAttribute(String localName, String value) { return new AttributeImpl(location, new QName(localName), - value, QName.valueOf("CDATA"), true); + value, "CDATA", true); } public Attribute createAttribute(QName name, String value) { return new AttributeImpl(location, name, value, - QName.valueOf("CDATA"), true); + "CDATA", true); } public Namespace createNamespace(String namespaceURI) diff --git a/javax/xml/stream/events/Attribute.java b/javax/xml/stream/events/Attribute.java index cf4711374..6e6d0274c 100644 --- a/javax/xml/stream/events/Attribute.java +++ b/javax/xml/stream/events/Attribute.java @@ -59,7 +59,7 @@ public interface Attribute /** * Returns the type of this attribute. */ - QName getDTDType(); + String getDTDType(); /** * Indicates whether this attribute was specified in the input source, or |