rpms/xalan-j2/devel xalan-j2-bz152255.patch, NONE, 1.1 xalan-j2.spec, 1.11, 1.12

fedora-cvs-commits at redhat.com fedora-cvs-commits at redhat.com
Tue May 24 16:10:51 UTC 2005


Author: gbenson

Update of /cvs/dist/rpms/xalan-j2/devel
In directory cvs.devel.redhat.com:/tmp/cvs-serv11730

Modified Files:
	xalan-j2.spec 
Added Files:
	xalan-j2-bz152255.patch 
Log Message:
Add DOM3 stubs to classes that need them (#152255)

xalan-j2-bz152255.patch:
 xalan/processor/TransformerFactoryImpl.java                     |    7 
 xalan/xsltc/trax/SmartTransformerFactoryImpl.java               |    6 
 xalan/xsltc/trax/TransformerFactoryImpl.java                    |    6 
 xml/dtm/ref/DTMNodeProxy.java                                   |  139 ++++++++++
 xml/dtm/ref/dom2dtm/DOM2DTMdefaultNamespaceDeclarationNode.java |   62 ++++
 xml/utils/UnImplNode.java                                       |  136 +++++++++
 xpath/domapi/XPathNamespaceImpl.java                            |   40 ++
 7 files changed, 396 insertions(+)

--- NEW FILE xalan-j2-bz152255.patch ---
--- xalan-j_2_6_0/src/org/apache/xml/dtm/ref/DTMNodeProxy.java~	2004-02-27 19:45:28.000000000 +0000
+++ xalan-j_2_6_0/src/org/apache/xml/dtm/ref/DTMNodeProxy.java	2005-05-24 14:45:34.000000000 +0100
@@ -24,6 +24,7 @@
 import org.w3c.dom.Attr;
 import org.w3c.dom.CDATASection;
 import org.w3c.dom.Comment;
+import org.w3c.dom.DOMConfiguration;
 import org.w3c.dom.DOMException;
 import org.w3c.dom.DOMImplementation;
 import org.w3c.dom.Document;
@@ -36,6 +37,8 @@
 import org.w3c.dom.NodeList;
 import org.w3c.dom.ProcessingInstruction;
 import org.w3c.dom.Text;
+import org.w3c.dom.TypeInfo;
+import org.w3c.dom.UserDataHandler;
 
 /**
  * <code>DTMNodeProxy</code> presents a DOM Node API front-end to the DTM model.
@@ -1353,5 +1356,141 @@
         return true;
       return false;
     }
+
+    // DOM Level 3 stub
+    public Object getFeature(String feature, String version)
+    {
+      throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+    }
+  }
+
+  // DOM Level 3 stubs
+  public Text replaceWholeText(String content) throws DOMException
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public boolean isElementContentWhitespace()
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public void setIdAttributeNS(String namespaceURI, 
+			       String localName, 
+			       boolean isId) throws DOMException
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public DOMConfiguration getDomConfig()
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public boolean isSameNode(Node other)
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public String getWholeText()
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public void setIdAttributeNode(Attr idAttr, boolean isId) throws DOMException
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public TypeInfo getSchemaTypeInfo()
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public String getXmlEncoding()
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public void setTextContent(String textContent) throws DOMException
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public void setXmlStandalone(boolean xmlStandalone) throws DOMException
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public String getBaseURI()
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public String lookupPrefix(String namespaceURI)
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public String getInputEncoding()
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public boolean getXmlStandalone()
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public boolean isDefaultNamespace(String namespaceURI)
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public String lookupNamespaceURI(String prefix)
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public short compareDocumentPosition(Node other) throws DOMException
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public void setXmlVersion(String xmlVersion) throws DOMException
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public boolean isId()
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public Object getFeature(String feature, String version)
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public void setIdAttribute(String name, boolean isId) throws DOMException
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public String getDocumentURI()
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public Object setUserData(String key, Object data, UserDataHandler handler)
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public Node renameNode(Node node,
+			 String namespaceURI,
+			 String qualifiedName) throws DOMException
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public String getXmlVersion()
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public boolean isEqualNode(Node arg)
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public String getTextContent() throws DOMException
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public void normalizeDocument()
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public Object getUserData(String key)
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public void setDocumentURI(String documentURI)
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
   }
 }
--- xalan-j_2_6_0/src/org/apache/xml/dtm/ref/dom2dtm/DOM2DTMdefaultNamespaceDeclarationNode.java~	2004-02-27 19:45:28.000000000 +0000
+++ xalan-j_2_6_0/src/org/apache/xml/dtm/ref/dom2dtm/DOM2DTMdefaultNamespaceDeclarationNode.java	2005-05-24 15:19:42.000000000 +0100
@@ -20,13 +20,17 @@
 package org.apache.xml.dtm.ref.dom2dtm;
 
 import org.apache.xml.dtm.DTMException;
+import org.apache.xml.dtm.DTMDOMException;
 
 import org.w3c.dom.Attr;
 import org.w3c.dom.Document;
+import org.w3c.dom.DOMException;
 import org.w3c.dom.Element;
 import org.w3c.dom.NamedNodeMap;
 import org.w3c.dom.Node;
 import org.w3c.dom.NodeList;
+import org.w3c.dom.TypeInfo;
+import org.w3c.dom.UserDataHandler;
 
 /** This is a kluge to let us shove a declaration for xml: into the
  * DOM2DTM model.  Basically, it creates a proxy node in DOM space to
@@ -101,5 +105,63 @@
 	{
 		return handle;
 	}
+
+  // DOM Level 3 stubs
+  public Object setUserData(String key, Object data, UserDataHandler handler)
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public String getBaseURI()
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public String getTextContent() throws DOMException
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public boolean isId()
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public TypeInfo getSchemaTypeInfo()
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public boolean isSameNode(Node other)
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public void setTextContent(String textContent) throws DOMException
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public boolean isDefaultNamespace(String namespaceURI)
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public Object getFeature(String feature, String version)
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public boolean isEqualNode(Node arg)
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public String lookupPrefix(String namespaceURI)
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public Object getUserData(String key)
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public short compareDocumentPosition(Node other) throws DOMException
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
+  public String lookupNamespaceURI(String prefix)
+  {
+    throw new DTMDOMException(DOMException.NOT_SUPPORTED_ERR);
+  }
 }
 
--- xalan-j_2_6_0/src/org/apache/xml/utils/UnImplNode.java~	2004-02-27 19:45:28.000000000 +0000
+++ xalan-j_2_6_0/src/org/apache/xml/utils/UnImplNode.java	2005-05-24 15:43:34.000000000 +0100
@@ -24,6 +24,7 @@
 import org.w3c.dom.Attr;
 import org.w3c.dom.CDATASection;
 import org.w3c.dom.Comment;
+import org.w3c.dom.DOMConfiguration;
 import org.w3c.dom.DOMException;
 import org.w3c.dom.DOMImplementation;
 import org.w3c.dom.Document;
@@ -36,6 +37,8 @@
 import org.w3c.dom.NodeList;
 import org.w3c.dom.ProcessingInstruction;
 import org.w3c.dom.Text;
+import org.w3c.dom.TypeInfo;
+import org.w3c.dom.UserDataHandler;
 
 /**
  * To be subclassed by classes that wish to fake being nodes.
@@ -1278,4 +1281,137 @@
   {
     error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
   }
+
+  // DOM Level 3 stubs
+  public String getBaseURI()
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+    return null;
+  }
+  public boolean getXmlStandalone()
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+    return false;
+  }
+  public Object setUserData(String key, Object data, UserDataHandler handler)
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+    return null;
+  }
+  public void normalizeDocument()
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+  }
+  public void setIdAttributeNode(Attr idAttr, boolean isId) throws DOMException
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+  }
+  public Node renameNode(Node node,
+			 String namespaceURI,
+			 String qualifiedName) throws DOMException
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+    return null;
+  }
+  public void setTextContent(String textContent) throws DOMException
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+  }
+  public void setIdAttributeNS(String namespaceURI, 
+			       String localName, 
+			       boolean isId) throws DOMException
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+  }
+  public String getInputEncoding()
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+    return null;
+  }
+  public String getXmlEncoding()
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+    return null;
+  }
+  public boolean isSameNode(Node other)
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+    return false;
+  }
+  public TypeInfo getSchemaTypeInfo()
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+    return null;
+  }
+  public String getDocumentURI()
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+    return null;
+  }
+  public void setDocumentURI(String documentURI)
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+  }
+  public Object getFeature(String feature, String version)
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+    return null;
+  }
+  public void setIdAttribute(String name, boolean isId) throws DOMException
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+  }
+  public boolean isDefaultNamespace(String namespaceURI)
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+    return false;
+  }
+  public boolean isEqualNode(Node arg)
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+    return false;
+  }
+  public void setXmlVersion(String xmlVersion) throws DOMException
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+  }
+  public String getXmlVersion()
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+    return null;
+  }
+  public String lookupPrefix(String namespaceURI)
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+    return null;
+  }
+  public Object getUserData(String key)
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+    return null;
+  }
+  public String getTextContent() throws DOMException
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+    return null;
+  }
+  public void setXmlStandalone(boolean xmlStandalone) throws DOMException
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+  }
+  public DOMConfiguration getDomConfig()
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+    return null;
+  }
+  public String lookupNamespaceURI(String prefix)
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+    return null;
+  }
+  public short compareDocumentPosition(Node other) throws DOMException
+  {
+    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);
+    return 0;
+  }
 }
--- xalan-j_2_6_0/src/org/apache/xalan/processor/TransformerFactoryImpl.java~	2004-02-27 19:45:28.000000000 +0000
+++ xalan-j_2_6_0/src/org/apache/xalan/processor/TransformerFactoryImpl.java	2005-05-24 15:58:58.000000000 +0100
@@ -892,4 +892,11 @@
 
     m_errorListener = listener;
   }
+
+  // DOM Level 3 stub
+  public void setFeature(String name, boolean value)
+    throws TransformerConfigurationException
+  {
+    throw new RuntimeException("not implemented");
+  }
 }
--- xalan-j_2_6_0/src/org/apache/xpath/domapi/XPathNamespaceImpl.java~	2004-02-27 19:45:28.000000000 +0000
+++ xalan-j_2_6_0/src/org/apache/xpath/domapi/XPathNamespaceImpl.java	2005-05-24 16:06:48.000000000 +0100
@@ -27,6 +27,7 @@
 import org.w3c.dom.NamedNodeMap;
 import org.w3c.dom.Node;
 import org.w3c.dom.NodeList;
+import org.w3c.dom.UserDataHandler;
 import org.w3c.dom.xpath.XPathNamespace;
 
 /**
@@ -264,4 +265,43 @@
         return m_attributeNode.hasAttributes();
     }
 
+    // DOM Level 3 stubs
+    public boolean isEqualNode(Node arg) {
+	throw new RuntimeException("not implemented");
+    }
+    public void setTextContent(String textContent) throws DOMException {
+	throw new RuntimeException("not implemented");
+    }
+    public String getBaseURI() {
+	throw new RuntimeException("not implemented");
+    }
+    public boolean isDefaultNamespace(String namespaceURI) {
+	throw new RuntimeException("not implemented");
+    }
+    public boolean isSameNode(Node other) {
+	throw new RuntimeException("not implemented");
+    }
+    public Object getUserData(String key) {
+	throw new RuntimeException("not implemented");
+    }
+    public Object setUserData(String key,
+			      Object data,
+			      UserDataHandler handler) {
+	throw new RuntimeException("not implemented");
+    }
+    public String lookupPrefix(String namespaceURI) {
+	throw new RuntimeException("not implemented");
+    }
+    public String getTextContent() throws DOMException {
+	throw new RuntimeException("not implemented");
+    }
+    public Object getFeature(String feature, String version) {
+	throw new RuntimeException("not implemented");
+    }
+    public short compareDocumentPosition(Node other) throws DOMException {
+	throw new RuntimeException("not implemented");
+    }
+    public String lookupNamespaceURI(String prefix) {
+	throw new RuntimeException("not implemented");
+    }
 }
--- xalan-j_2_6_0/src/org/apache/xalan/xsltc/trax/SmartTransformerFactoryImpl.java~	2004-02-27 19:45:28.000000000 +0000
+++ xalan-j_2_6_0/src/org/apache/xalan/xsltc/trax/SmartTransformerFactoryImpl.java	2005-05-24 16:21:39.000000000 +0100
@@ -382,4 +382,10 @@
             throw e1;
         }
     }
+
+    // DOM Level 3 stub
+    public void setFeature(String name, boolean value)
+	throws TransformerConfigurationException {
+	throw new RuntimeException("not implemented");
+    }
 }
--- xalan-j_2_6_0/src/org/apache/xalan/xsltc/trax/TransformerFactoryImpl.java~	2004-02-27 19:45:28.000000000 +0000
+++ xalan-j_2_6_0/src/org/apache/xalan/xsltc/trax/TransformerFactoryImpl.java	2005-05-24 16:22:52.000000000 +0100
@@ -1331,4 +1331,10 @@
     protected Class getDTMManagerClass() {
         return m_DTMManagerClass;
     }
+
+    // DOM Level 3 stub
+    public void setFeature(String name, boolean value)
+	throws TransformerConfigurationException {
+	throw new RuntimeException("not implemented");
+    }
 }


Index: xalan-j2.spec
===================================================================
RCS file: /cvs/dist/rpms/xalan-j2/devel/xalan-j2.spec,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -r1.11 -r1.12
--- xalan-j2.spec	1 Apr 2005 12:41:13 -0000	1.11
+++ xalan-j2.spec	24 May 2005 16:10:48 -0000	1.12
@@ -13,6 +13,7 @@
 Patch1:         %{name}-manifest.patch
 Patch2:         %{name}-crosslink.patch
 Patch3:         %{name}-bz130162.patch
+Patch4:         %{name}-bz152255.patch
 URL:            http://xml.apache.org/xalan-j/
 Group:          Text Processing/Markup/XML
 #Vendor:         JPackage Project
@@ -83,11 +84,12 @@
 if java -version 2>&1 | grep -q "gcj"; then
 %patch3 -p1
 fi
+%patch4 -p1
 
 %build
 if [ ! -e "$JAVA_HOME" ] ; then export JAVA_HOME="%{java_home}" ; fi
-export CLASSPATH=$(build-classpath servlet java_cup java_cup-runtime jlex \
-bcel xerces-j2)
+export CLASSPATH=$(build-classpath servletapi5 java_cup java_cup-runtime \
+jlex bcel xerces-j2)
 
 ant \
   -Djava.awt.headless=true \
@@ -192,6 +194,9 @@
 %{_datadir}/%{name}
 
 %changelog
+* Tue May 24 2005 Gary Benson <gbenson at redhat.com>
+- Add DOM3 stubs to classes that need them (#152255).
+
 * Fri Apr  1 2005 Gary Benson <gbenson at redhat.com> 0:2.6.0-2jpp_2fc
 - Add NOTICE file as per Apache License version 2.0.
 




More information about the fedora-cvs-commits mailing list