[jira] [Created] (LANG-700) Fix Javadoc for StringUtils.normalizeSpace

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

[jira] [Created] (LANG-700) Fix Javadoc for StringUtils.normalizeSpace

ASF GitHub Bot (Jira)
Fix Javadoc for StringUtils.normalizeSpace
------------------------------------------

                 Key: LANG-700
                 URL: https://issues.apache.org/jira/browse/LANG-700
             Project: Commons Lang
          Issue Type: Task
          Components: lang.*
    Affects Versions: 2.6
            Reporter: Eric Fenderbosch
            Priority: Trivial


The Javadocs for StringUtils.normalizeSpace state:

"The function returns the argument string with whitespace normalized by using trim(String) to remove leading and trailing whitespace and then replacing sequences of whitespace characters by a single space."

Looking at the source code StringUtils.normalizeSpace actually uses strip, not trim. The difference is subtle, but should be corrected.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
Reply | Threaded
Open this post in threaded view
|

[jira] [Commented] (LANG-700) Fix Javadoc for StringUtils.normalizeSpace

ASF GitHub Bot (Jira)

    [ https://issues.apache.org/jira/browse/LANG-700?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13036850#comment-13036850 ]

Gary D. Gregory commented on LANG-700:
--------------------------------------

In trunk (for 3.0) the code and Javadoc match.

> Fix Javadoc for StringUtils.normalizeSpace
> ------------------------------------------
>
>                 Key: LANG-700
>                 URL: https://issues.apache.org/jira/browse/LANG-700
>             Project: Commons Lang
>          Issue Type: Task
>          Components: lang.*
>    Affects Versions: 2.6
>            Reporter: Eric Fenderbosch
>            Priority: Trivial
>
> The Javadocs for StringUtils.normalizeSpace state:
> "The function returns the argument string with whitespace normalized by using trim(String) to remove leading and trailing whitespace and then replacing sequences of whitespace characters by a single space."
> Looking at the source code StringUtils.normalizeSpace actually uses strip, not trim. The difference is subtle, but should be corrected.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
Reply | Threaded
Open this post in threaded view
|

[jira] [Updated] (LANG-700) Fix Javadoc for StringUtils.normalizeSpace

ASF GitHub Bot (Jira)
In reply to this post by ASF GitHub Bot (Jira)

     [ https://issues.apache.org/jira/browse/LANG-700?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Henri Yandell updated LANG-700:
-------------------------------

    Fix Version/s: 2.x

> Fix Javadoc for StringUtils.normalizeSpace
> ------------------------------------------
>
>                 Key: LANG-700
>                 URL: https://issues.apache.org/jira/browse/LANG-700
>             Project: Commons Lang
>          Issue Type: Task
>          Components: lang.*
>    Affects Versions: 2.6
>            Reporter: Eric Fenderbosch
>            Priority: Trivial
>             Fix For: 2.x
>
>
> The Javadocs for StringUtils.normalizeSpace state:
> "The function returns the argument string with whitespace normalized by using trim(String) to remove leading and trailing whitespace and then replacing sequences of whitespace characters by a single space."
> Looking at the source code StringUtils.normalizeSpace actually uses strip, not trim. The difference is subtle, but should be corrected.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

       
Reply | Threaded
Open this post in threaded view
|

[jira] [Closed] (LANG-700) Fix Javadoc for StringUtils.normalizeSpace

ASF GitHub Bot (Jira)
In reply to this post by ASF GitHub Bot (Jira)

     [ https://issues.apache.org/jira/browse/LANG-700?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Henri Yandell closed LANG-700.
------------------------------

       Resolution: Fixed
    Fix Version/s:     (was: 2.x)
                   3.0

Fixed by the 3.0 release.

> Fix Javadoc for StringUtils.normalizeSpace
> ------------------------------------------
>
>                 Key: LANG-700
>                 URL: https://issues.apache.org/jira/browse/LANG-700
>             Project: Commons Lang
>          Issue Type: Task
>          Components: lang.*
>    Affects Versions: 2.6
>            Reporter: Eric Fenderbosch
>            Priority: Trivial
>             Fix For: 3.0
>
>
> The Javadocs for StringUtils.normalizeSpace state:
> "The function returns the argument string with whitespace normalized by using trim(String) to remove leading and trailing whitespace and then replacing sequences of whitespace characters by a single space."
> Looking at the source code StringUtils.normalizeSpace actually uses strip, not trim. The difference is subtle, but should be corrected.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira