OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help



   RE: [xml-dev] Reusing, Refactoring, Reinventing??? (was Re: [xml-dev] SA

[ Lists Home | Date Index | Thread Index ]

Elliotte Rusty Harold wrote:
> As to reuse, this is a textbook case of 
> how not to reuse. 
	One can reuse implementation and one can reuse interface.
Sometimes, you can reuse both at the same time. Nonetheless, it is
still reuse if you reuse only one and not the other.

> However, the argument is whether to put this into SAX 
> itself rather than somebody's personal local classes.
	No. I don't care if the saxproject.org site ever says "This is
part of SAX." I'm just suggesting an extension to SAX that makes sense
for some people. And, as far as I know, there isn't really a
difference between "somebody's personal local classes" and a set of
classes that are "personal" to more than one person. How is SAX itself
different from a "personal local class?"

> TypedContentHandler is not a ContentHandler. 
> It merely acts like one. 
	Right. TypedContentHandler works exactly like ContentHandler
except that it can do just a little bit more. This is reuse of the
interface (and much, but not all, of the implementation as well). The
contract presented by TypeContentHandler is precisely the same as the
contrat presented by ContentHandler -- except that TypedContentHandler
can do a little more. Its like if you create a "Person" class and then
created "Man" and "Woman" subclasses that can do specific things that
the generic "Person" doesn't do to well. This is classic computer

		bob wyman


News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS