http://nagoya.apache.org/bugzilla/show_bug.cgi?id=2230 *** shadow/2230 Tue Jun 19 02:37:43 2001 --- shadow/2230.tmp.23043 Tue Jun 19 02:37:43 2001 *************** *** 0 **** --- 1,35 ---- + +============================================================================+ + | Method newTransformer(javax.xml.transform.Source) should not return null, | + +----------------------------------------------------------------------------+ + | Bug #: 2230 Product: XalanJ2 | + | Status: NEW Version: 2.0.x | + | Resolution: Platform: PC | + | Severity: Minor OS/Version: Windows NT/2K | + | Priority: Other Component: javax.xml | + +----------------------------------------------------------------------------+ + | Assigned To: [EMAIL PROTECTED] | + | Reported By: [EMAIL PROTECTED] | + | CC list: Cc: | + +----------------------------------------------------------------------------+ + | URL: http://xml.apache.org/xalan-j/apidocs/javax/xml/transform/Tr | + +============================================================================+ + | DESCRIPTION | + According to the apidocs [1], the method + javax.xml.transform.TransformerFactory.newTransformer + (javax.xml.transform.Source) is not supposed to return null under any + circumstances. But if you assign an error listener [2] to this class _before_ + you try to get an instance of a transformer and the stylesheet is not a well + formed document, this 'not wellformed' error is reported to the error listener + and 'null' is returned, but no exception is thrown. + + I suggest it is a bug in the apidocs for two reasons: + 1. the behavior is logical, as one intends to omit exceptions by registering + the error listener to the factory + 2. the apidocs point out the version 'Alpha, 2.0.0, July 05, 2000' on the + overview page [3]; maybe it's just not updated properly + + [1] http://xml.apache.org/xalan- + j/apidocs/javax/xml/transform/TransformerFactory.html#newTransformer + (javax.xml.transform.Source) + [2] http://xml.apache.org/xalan-j/apidocs/javax/xml/transform/ErrorListener.html + [3] http://xml.apache.org/xalan-j/apidocs/overview-summary.html \ No newline at end of file
