Looks like I wrote that, but changed some of the leaf classes to "final"
anyway. By extending a class like ToXMLStream you are on a slippery path.
The javadoc for the class says "**For internal use only**". That may be of
little consolation, but I guess we are trying to keep people from building
dependancies on non-public APIs.
For the moment what about containing a ToXMLStream rather than inheriting
from it?
class MyXMLSerializer implements ContentHandler {
private final ToXMLStream m_ser;
MyXMLSerializer() {
m_ser = new ToXMLStream();
}
void startDocument() {
m_ser.startDocument();
}
// .... other ContentHandler methods that delegate to m_ser,
}
Will that do, or are you using some protected or package-private methods or
fields? In the bigger scheme of things we want user's to be happy and this
issue could be revisited. We could make these classes non-final.
Even classes like ToXMLStream became public again, I guess you know that
these are not public APIs and you can't depend on them. They could go away
or have methods on them change in the future, but you are prepared for
that, right?
Let us know. Perhaps it is time for 2.7.1 or 2.8 with some changes.
Keep the dialogue going.
Regards,
- Brian
Apache Xalan XSLT Development
[EMAIL PROTECTED]
toadie D
<[EMAIL PROTECTED]
com> To
[email protected]
02/08/2006 06:12 cc
PM [EMAIL PROTECTED]
Subject
re: public to non-public in Xalan-J
Please respond to serializer - any impact?
xalan-dev
Reference: http://marc.theaimsgroup.com/?l=xalan-dev&m=107419182613741&w=2
--excerpt--
"public" classes that I'd like to see become package-private.
Is anyone using these directly?
This is my area of greatest concern so it will probably be left as
"public".
==========================================================
- ToHTMLStream
- ToTextStream
- ToXMLStream
--excerpt--
Unfortunately, we are using what Brian has proposed as a feature change (we
were on 2.5.1 and have recently moved to 2.7.x)
We had (and still do) have a need to extend the ToXMLStream class to
perform a number of tasks.
In 2.7.x, it's now declared as final. So, for implementation that
requires custom XML serialization, what is the general guideline for
implementing those serializer?
It would be nice if we can leverage some of the code that's already
implemented by Apache.
Thanks.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]