[jdom-interest] Request -- please allow all XML 1.1 conformant text in Element.se tText()

Chris B. chris at tech.com.au
Sun Mar 7 14:11:48 PST 2004

Elliotte Rusty Harold wrote:

> At 8:05 PM +1100 3/7/04, Chris B. wrote:
>> When you inherit and dive into the internals, you say goodbye to 
>> backwards compatibility. So what? If you choose to do that, it is 
>> your choice. Are you my nanny?
> Yes, we are. That's why you're using an API rather than rolling your 
> own code. You're assigning us the responsibility of properly handling 
> XML so you don't have to. A good API does not require the users to be 
> subject domain experts (though the API designers had better be.)

--"In order to better support the Open-Closed principle, all features of 
a class are always available to subclasses in Eiffel, so there is no 
notion of private as there is in Java and C++."--

Many expert people don't agree with you. Read Meyer.

BTW, backwards compatibility is way over-valued in the Java community. 
It's better to move on, than maintain legacy forever.

> And it's not backwards compatibility that's the point. It's forwards 
> compatibility. Once we've exposed anything as either protected or 
> public, we can't change it in the future or existing code will break.
> Even if we were prepared to pay the cost of designing and maintaining 
> a protected API, that API should be exposed through methods, not 
> through fields. Methods allow flexibility in future implementation. 
> Fields do not. Data encapsulation and implementation hiding is no less 
> important a principle for the protected API than the public one.

More information about the jdom-interest mailing list