You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by Daniel Rall <dl...@finemaltcoding.com> on 2002/08/29 19:35:23 UTC
Re: [lang][patch] StringUtils [Was: Re: [lang] Code donation: StringTokenUtils]
The changes look good, but your patch doesn't apply. Mind giving it a
go against CVS HEAD?
John Yu <jo...@scioworks.com> writes:
> Daniel,
>
> I've re-read the javadoc. It's already pretty comprehensive.
> Nevertheless, I've made some small changes to add clarification.
>
> ===== Diff starts here ============================================
>
> --- StringUtils_orig.java Wed Aug 28 14:07:47 2002
> +++ StringUtils.java Wed Aug 28 14:05:06 2002
> @@ -405,11 +405,16 @@
> /**
> * Splits the provided text into a list, based on a given separator.
> * The separator is not included in the returned String array.
> - * A null separator will cause parsing to be on whitespace.
> + * A null separator will cause parsing to be on whitespace.<p>
> + *
> + * This is useful for quickly tokenizing a string directly into
> + * an array of tokens, instead of an enumeration of tokens
> + * as what StringTokenizer does.
> *
> * @param str the string to parse
> - * @param separator The separator character. If <code>null</code>, splits
> - * on whitespace.
> + * @param separator Characters used as the delimiters.
> + * If <code>null</code>, splits
> + * on whitespace.
> * @return an array of parsed Strings
> */
> public static String[] split(String text, String separator) {
> @@ -422,9 +427,14 @@
> * The maximum number of splits to perfom can be controlled.
> * A null separator will cause parsing to be on whitespace.
> *
> + * This is useful for quickly tokenizing a string directly into
> + * an array of tokens, instead of an enumeration of tokens
> + * as what StringTokenizer does.
> + *
> * @param str the string to parse
> - * @param separator The separator character. If <code>null</code>, splits
> - * on whitespace.
> + * @param separator Characters used as the delimiters.
> + * If <code>null</code>, splits
> + * on whitespace.
> * @param max The maximum number of elements to include in the
> * list. A zero or negative value implies no limit.
> * @return an array of parsed Strings
>
> ===== Diff ends here ============================================
>
>
> At 03:04 am 28-08-2002, you wrote:
> >John Yu <jo...@scioworks.com> writes:
> >
> > > Steven,
> > >
> > > Doh! I overlooked them.
> > > You're right. The split() and join() do the work.
> >
> >John, can you think of anything to add to the JavaDoc to aid people in
> >finding/identifying those methods in the future?
> >--
> >
> >Daniel Rall <dl...@finemaltcoding.com>
>
> --
> John Yu Scioworks Technologies
> e: john@scioworks.com w: +(65) 873 5989
> w: http://www.scioworks.com m: +(65) 9782 9610
>
> Scioworks Camino - "Don't develop Struts Apps without it!"
>
> --
> To unsubscribe, e-mail: <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>
--
Daniel Rall <dl...@finemaltcoding.com>
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: [lang][patch] StringUtils [Was: Re: [lang] Code donation: StringTokenUtils]
Posted by Daniel Rall <dl...@finemaltcoding.com>.
As Steve says, that's usually the case. I didn't see any wrapped
lines though, which is the most common problem. *shrug*
Steve Downey <st...@netfolio.com> writes:
> Probably something got munged by the mailer. Sending the patch as an
> attachment, rather than inline, usually works much better.
>
> On Thursday 29 August 2002 11:04 pm, John Yu wrote:
> > How could that be?? I got the CVS HEAD only two hours ago, re-did the
> > change by hand and did the diff...
> >
> > Thanks for doing the manual merge.
> >
> > At 10:53 am 30-08-2002, you wrote:
> > >Hi John. That didn't apply either, so I merged your changes in
> > >manually. Thanks again.
--
Daniel Rall <dl...@finemaltcoding.com>
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: [lang][patch] StringUtils [Was: Re: [lang] Code donation: StringTokenUtils]
Posted by Steve Downey <st...@netfolio.com>.
Probably something got munged by the mailer. Sending the patch as an
attachment, rather than inline, usually works much better.
On Thursday 29 August 2002 11:04 pm, John Yu wrote:
> How could that be?? I got the CVS HEAD only two hours ago, re-did the
> change by hand and did the diff...
>
> Thanks for doing the manual merge.
>
> At 10:53 am 30-08-2002, you wrote:
> >Hi John. That didn't apply either, so I merged your changes in
> >manually. Thanks again.
> >
> >- Dan
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: [lang][patch] StringUtils [Was: Re: [lang] Code donation:
StringTokenUtils]
Posted by John Yu <jo...@scioworks.com>.
How could that be?? I got the CVS HEAD only two hours ago, re-did the
change by hand and did the diff...
Thanks for doing the manual merge.
At 10:53 am 30-08-2002, you wrote:
>Hi John. That didn't apply either, so I merged your changes in
>manually. Thanks again.
>
>- Dan
--
John Yu Scioworks Technologies
e: john@scioworks.com w: +(65) 873 5989
w: http://www.scioworks.com m: +(65) 9782 9610
Scioworks Camino - "Don't develop Struts Apps without it!"
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: [lang][patch] StringUtils [Was: Re: [lang] Code donation: StringTokenUtils]
Posted by Daniel Rall <dl...@finemaltcoding.com>.
Hi John. That didn't apply either, so I merged your changes in
manually. Thanks again.
- Dan
John Yu <jo...@scioworks.com> writes:
> Hi Daniel,
>
> How unmindful I am! How could I assume that my copy of the 20020822
> build was the CVS HEAD???
>
> Ok, here you go.
>
> ========= Diff starts here ============================================
>
> --- StringUtils_orig1.java Fri Aug 30 09:44:10 2002
> +++ StringUtils.java Fri Aug 30 09:46:54 2002
> @@ -408,11 +408,16 @@
> /**
> * Splits the provided text into a list, based on a given separator.
> * The separator is not included in the returned String array.
> - * A null separator will cause parsing to be on whitespace.
> + * A null separator will cause parsing to be on whitespace.<p>
> + *
> + * This is useful for quickly tokenizing a string directly into
> + * an array of tokens, instead of an enumeration of tokens
> + * as what StringTokenizer does.
> *
> * @param str the string to parse
> - * @param separator The separator character. If <code>null</code>, splits
> - * on whitespace.
> + * @param separator Characters used as the delimiters.
> + * If <code>null</code>, splits
> + * on whitespace.
> * @return an array of parsed Strings
> */
> public static String[] split(String text, String separator) {
> @@ -423,11 +428,16 @@
> * Splits the provided text into a list, based on a given separator.
> * The separator is not included in the returned String array.
> * The maximum number of splits to perfom can be controlled.
> - * A null separator will cause parsing to be on whitespace.
> + * A null separator will cause parsing to be on whitespace.<p>
> + *
> + * This is useful for quickly tokenizing a string directly into
> + * an array of tokens, instead of an enumeration of tokens
> + * as what StringTokenizer does.
> *
> * @param str the string to parse
> - * @param separator The separator character. If <code>null</code>, splits
> - * on whitespace.
> + * @param separator Characters used as the delimiters.
> + * If <code>null</code>, splits
> + * on whitespace.
> * @param max The maximum number of elements to include in the
> * list. A zero or negative value implies no limit.
> * @return an array of parsed Strings
>
> ========= Diff ends here ==============================================
>
>
> At 01:35 am 30-08-2002, you wrote:
> >The changes look good, but your patch doesn't apply. Mind giving it a
> >go against CVS HEAD?
> >
> >John Yu <jo...@scioworks.com> writes:
> >
> > > Daniel,
> > >
> > > I've re-read the javadoc. It's already pretty comprehensive.
> > > Nevertheless, I've made some small changes to add clarification.
> > >
> > > <snipped/>
> > >
> > >
> > > At 03:04 am 28-08-2002, you wrote:
> > > >John Yu <jo...@scioworks.com> writes:
> > > >
> > > > > Steven,
> > > > >
> > > > > Doh! I overlooked them.
> > > > > You're right. The split() and join() do the work.
> > > >
> > > >John, can you think of anything to add to the JavaDoc to aid people in
> > > >finding/identifying those methods in the future?
> > > >--
> > > >
> > > >Daniel Rall <dl...@finemaltcoding.com>
> > >
>
> --
> John Yu Scioworks Technologies
> e: john@scioworks.com w: +(65) 873 5989
> w: http://www.scioworks.com m: +(65) 9782 9610
>
> Scioworks Camino - "Don't develop Struts Apps without it!"
>
>
> --
> To unsubscribe, e-mail: <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>
>
--
Daniel Rall <dl...@finemaltcoding.com>
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: [lang][patch] StringUtils [Was: Re: [lang] Code donation:
StringTokenUtils]
Posted by John Yu <jo...@scioworks.com>.
Hi Daniel,
How unmindful I am! How could I assume that my copy of the 20020822 build
was the CVS HEAD???
Ok, here you go.
========= Diff starts here ============================================
--- StringUtils_orig1.java Fri Aug 30 09:44:10 2002
+++ StringUtils.java Fri Aug 30 09:46:54 2002
@@ -408,11 +408,16 @@
/**
* Splits the provided text into a list, based on a given separator.
* The separator is not included in the returned String array.
- * A null separator will cause parsing to be on whitespace.
+ * A null separator will cause parsing to be on whitespace.<p>
+ *
+ * This is useful for quickly tokenizing a string directly into
+ * an array of tokens, instead of an enumeration of tokens
+ * as what StringTokenizer does.
*
* @param str the string to parse
- * @param separator The separator character. If <code>null</code>, splits
- * on whitespace.
+ * @param separator Characters used as the delimiters.
+ * If <code>null</code>, splits
+ * on whitespace.
* @return an array of parsed Strings
*/
public static String[] split(String text, String separator) {
@@ -423,11 +428,16 @@
* Splits the provided text into a list, based on a given separator.
* The separator is not included in the returned String array.
* The maximum number of splits to perfom can be controlled.
- * A null separator will cause parsing to be on whitespace.
+ * A null separator will cause parsing to be on whitespace.<p>
+ *
+ * This is useful for quickly tokenizing a string directly into
+ * an array of tokens, instead of an enumeration of tokens
+ * as what StringTokenizer does.
*
* @param str the string to parse
- * @param separator The separator character. If <code>null</code>, splits
- * on whitespace.
+ * @param separator Characters used as the delimiters.
+ * If <code>null</code>, splits
+ * on whitespace.
* @param max The maximum number of elements to include in the
* list. A zero or negative value implies no limit.
* @return an array of parsed Strings
========= Diff ends here ==============================================
At 01:35 am 30-08-2002, you wrote:
>The changes look good, but your patch doesn't apply. Mind giving it a
>go against CVS HEAD?
>
>John Yu <jo...@scioworks.com> writes:
>
> > Daniel,
> >
> > I've re-read the javadoc. It's already pretty comprehensive.
> > Nevertheless, I've made some small changes to add clarification.
> >
> > <snipped/>
> >
> >
> > At 03:04 am 28-08-2002, you wrote:
> > >John Yu <jo...@scioworks.com> writes:
> > >
> > > > Steven,
> > > >
> > > > Doh! I overlooked them.
> > > > You're right. The split() and join() do the work.
> > >
> > >John, can you think of anything to add to the JavaDoc to aid people in
> > >finding/identifying those methods in the future?
> > >--
> > >
> > >Daniel Rall <dl...@finemaltcoding.com>
> >
--
John Yu Scioworks Technologies
e: john@scioworks.com w: +(65) 873 5989
w: http://www.scioworks.com m: +(65) 9782 9610
Scioworks Camino - "Don't develop Struts Apps without it!"
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>