commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From scolebou...@btopenworld.com
Subject Re: [LANG] Bugzilla id 17882
Date Fri, 14 Mar 2003 13:51:52 GMT
>  from:    "Henning P. Schmiedehausen" <hps@intermeta.de>
> Henri Yandell <bayard@generationjava.com> writes:
> 
> >Personally I'm against them.
> 
> >If we do this method, why are we not adding a char override for every
> >method that takes a String as an argument in that way? ie) countMatches,
> >chomp/chompLast[after renaming], getNestedString, indexOfAny, leftPad,
> >replace, reverseDelimitedString, strip etc.
> 
> >Is there any reason why split/join are special?
> 
> I need them. :-) And splitting at a single char / joining with a
> single char as delimiter is needed very often and using '.' is more
> efficient than "."

This case is justified IMHO for StringUtils as it matches the JDKs indexOf(). It is not part
of a CharArrayUtils, because the char is an additional parameter, not the primary.

eg.
StringUtils.split(String, String)
StringUtils.split(String, char)
CharArrayUtils.split(char[], String)
CharArrayUtils.split(char[], char)

Stephen


> >StringUtils is already huge and adding lots of overrides just seems to
> >make it even larger. Just looking at the javadoc, I have to wonder why we
> >need the Object[] and the Iterator [okay, i'm actually for this one] and
> >why we don't have an Iterator option for concatenate.
> 
> Then we should thing about using the current StringUtils as a frontend
> facade for some split up classes and then deprecate StringUtils stuff
> later.
> 
> >Just my -2 new pence :)
> 
> 	Regards
> 		Henning
> 
> 
> -- 
> Dipl.-Inf. (Univ.) Henning P. Schmiedehausen          INTERMETA GmbH
> hps@intermeta.de         49 9131 50 654 0   http://www.intermeta.de/
> 
> Java, perl, Solaris, Linux, xSP Consulting, Web Services 
> freelance consultant -- Jakarta Turbine Development  -- hero for hire
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-dev-help@jakarta.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message