[jdom-interest] Default for getChildText?
Patrick Dowler
patrick.dowler at nrc.ca
Wed Apr 3 13:54:17 PST 2002
On 03 April 2002 12:57, Garrett Zork wrote:
> One of the convenience methods I had placed into a utility
> class was the getAttributeValue with a default value, described
> below. Other methods that JDOM users commonly code into
> a utility class include:
>
> - getIntAttributeValue and setIntAttribute value - also
> with a default value for the get. While I certainly
> don't see the need for float/double/String versions of
> this, I don't need practice with parseInt and valueOf.
But I actually use float and double WAY more than int!! Waaahhhh!!!
I want getFloatAttributeValue()!
I want getDoubleAttributeValue()!!
I want getDateAttributeValue()!!!
What about getDateInFunkyFormat() ??
I want getTheThingIWantDespiteAnExistingJava2SDKMethod()!!!! :-)
Does it ever end? You can't just say "int is useful, forget the rest". What
about "money"??
> - readDocument, writeDocument. These would obviously fit
> nicely in the Document class.
>
> A good API is solid, stable and convenient not pretty.
For some reason the lyrics "she ain't pretty - she just looks that way" came into my
head. I have no idea how it relates to this topic. Maybe it's what encapsulation is
all about....
--
Patrick Dowler
Canadian Astronomy Data Centre
National Research Council
Victoria, BC
More information about the jdom-interest
mailing list