You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Sebb (JIRA)" <ji...@apache.org> on 2010/01/14 16:08:54 UTC

[jira] Issue Comment Edited: (LANG-581) a API document bug of org.apache.commons.lang.StringUtils

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

Sebb edited comment on LANG-581 at 1/14/10 3:07 PM:
----------------------------------------------------

Yes, the example is wrong, however it should be:

StringUtils.removeEnd("www.domain.com.", ".com") = "www.domain.com."

as for the same example in the removeEnd() Javadoc.

In fact all the Javadoc examples for removeEndIgnoreCase() are wrong, as they all refer to removeEnd().



      was (Author: sebb@apache.org):
    Yes, the example is wrong, in that the trailing "." should not be there.

The example should probably be something more like:

StringUtils.removeEndIgnoreCase("www.domain.com", ".COM.") = "www.domain.com"

and similarly for the other examples.


  
> a API document bug of org.apache.commons.lang.StringUtils
> ---------------------------------------------------------
>
>                 Key: LANG-581
>                 URL: https://issues.apache.org/jira/browse/LANG-581
>             Project: Commons Lang
>          Issue Type: Bug
>          Components: lang.*
>    Affects Versions: 2.4
>         Environment: Online document
>            Reporter: wangcee
>            Assignee: Sebb
>            Priority: Trivial
>
> the org.apache.commons.lang.StringUtils online document 
> http://commons.apache.org/lang/api-release/org/apache/commons/lang/StringUtils.html#removeEndIgnoreCase%28java.lang.String,%20java.lang.String%29
> at removeEndIgnoreCase()  description, there is one line 
> StringUtils.removeEnd("www.domain.com", ".com.")  = "www.domain.com."
> it should be 
> StringUtils.removeEnd("www.domain.com", ".com.")  = "www.domain.com"

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.