hillion 02/04/23 06:12:57
Modified: sources/org/apache/batik/dom/svg SVGDOMImplementation.java
Log:
Creation of unknown elements in the SVG namespace does not fail anymore.
Revision Changes Path
1.21 +9 -13
xml-batik/sources/org/apache/batik/dom/svg/SVGDOMImplementation.java
Index: SVGDOMImplementation.java
===================================================================
RCS file:
/home/cvs/xml-batik/sources/org/apache/batik/dom/svg/SVGDOMImplementation.java,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -r1.20 -r1.21
--- SVGDOMImplementation.java 9 Apr 2002 16:27:18 -0000 1.20
+++ SVGDOMImplementation.java 23 Apr 2002 13:12:57 -0000 1.21
@@ -61,7 +61,7 @@
* It provides support the SVG 1.0 documents.
*
* @author <a href="mailto:[EMAIL PROTECTED]">Stephane Hillion</a>
- * @version $Id: SVGDOMImplementation.java,v 1.20 2002/04/09 16:27:18 hillion Exp $
+ * @version $Id: SVGDOMImplementation.java,v 1.21 2002/04/23 13:12:57 hillion Exp $
*/
public class SVGDOMImplementation
extends AbstractDOMImplementation
@@ -249,23 +249,19 @@
if (namespaceURI.equals(SVG_NAMESPACE_URI)) {
String name = DOMUtilities.getLocalName(qualifiedName);
ElementFactory ef = (ElementFactory)factories.get(name);
- if (ef == null) {
- throw document.createDOMException
- (DOMException.NOT_FOUND_ERR,
- "invalid.element",
- new Object[] { namespaceURI,
- qualifiedName });
+ if (ef != null) {
+ return ef.create(DOMUtilities.getPrefix(qualifiedName),
+ document);
}
- return ef.create(DOMUtilities.getPrefix(qualifiedName), document);
- } else {
- return new GenericElementNS(namespaceURI.intern(),
- qualifiedName.intern(),
- document);
}
+ return new GenericElementNS(namespaceURI.intern(),
+ qualifiedName.intern(),
+ document);
}
/**
- * Creates an DocumentEventSupport object suitable for use with this
implementation.
+ * Creates an DocumentEventSupport object suitable for use with
+ * this implementation.
*/
public DocumentEventSupport createDocumentEventSupport() {
DocumentEventSupport result = new DocumentEventSupport();
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]