Re: [Htmlparser-user] FrameTag : no "setFrameLocation" method ?
Brought to you by:
derrickoswald
From: Somik R. <so...@ya...> - 2003-02-12 06:44:31
|
Dhaval Udani wrote: > At this point of time we may not be able to understand different > requirements of different applications. As a rule we must not keep > anything binding in the parser. Everything should be read/write. Itsupto > the user of the API to use it properly. As such we keep seeing new ares > where the parser is getting deployed. Alongwith this come new > requirements and new unforeseen needs. Its best to keep it open such > that anyone can go and change any attribute/tag/node etc. I'd be inclined to agree with you - to have a setAttribute method on HTMLTag. But I'd like to add that I do not agree in general about adding stuff that may or may not be used - that is a code smell by itself (in fact, one of the code smells in Fowler's book talks about unnecessary setter methods). This always adds up to maintenance problems later. To accomodate future needs, I think we need to be agile (I hope we are agile enough for our community). In this situation though, we might save some duplication by allowing the setting of the attribute in HTMLTag, and it might be a good feature to have. Regards, Somik |