Support for "indent-number"?
Added by Anonymous about 17 years ago
Legacy ID: #4532121 Legacy Poster: Dan Rollo (bhamail)
Hi, Is there any plan to support "indent-number" in Saxon? Here's why I ask: http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6396599 Basically, the Java 6 Preferences API assumes "indent-number" is supported. Since apparently Saxon does not support "indent-number", Java 6 dies when trying to save preferences info to an xml file. The sun bug fix used in Java 7 apparently removes the use of "indent-number", but this means anyone using Java 6 Preferences with Saxon is toast. (I've posted requests for a backport of the Java 7 fix to Java 6, but I see no evidence that will happen.) (I don't really understand the details of exactly what the "indent-number" feature is.) Apologies is this is the wrong forum, and please direct me to the right place. Thanks, Dan
Replies (2)
RE: Support for "indent-number"? - Added by Anonymous about 17 years ago
Legacy ID: #4532243 Legacy Poster: Michael Kay (mhkay)
Very occasionally I will make a change to Saxon to enable users to circumvent a bug in another product, but in general I think it's a bad thing to do: bugs should be fixed at source. In this particular case I'm not convinced that the problem is severe enough to justify it. It's not even clear that making the change would solve the problem. If Sun haven't tested that the Preferences code works with JAXP providers other than Xalan, then there might be lots of things that stop it working, and removing this particular failure might simply open the door to others. (The actual problem appears to be that they are calling setAttribute() on the TransformerFactory, with "indent-spaces" as the attribute name, and they are not recovering when the TransformerFactory says it doesn't recognize the attribute name. I believe that this Xalan-defined attribute has a fairly similar effect to the output property saxon:indent-spaces in Saxon, though I have no idea why they have made it a system-wide property of the TransformerFactory rather than a more local serialization property that can vary from one transformation to another.) There might be a workaround by defining a user-defined subclass of Saxon's TransformerFactoryImpl that intercepts the setAttribute() call. Michael Kay http://www.saxonica.com/
RE: Support for "indent-number"? - Added by Anonymous about 17 years ago
Legacy ID: #4535925 Legacy Poster: Dan Rollo (bhamail)
Understood, and agreed. I'll keep pushing for a backport of the Java 7 fix to Java 6.
Please register to reply