[
https://issues.apache.org/jira/browse/LANG-1064?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Duncan Jones resolved LANG-1064.
--------------------------------
Resolution: Fixed
Fix Version/s: 3.4
Assignee: Duncan Jones
I've updated the Javadoc to read
bq. If the number of characters in {{str}} is less than or equal to
{{maxWidth}}, return {{str}}.
Thanks for spotting this.
{noformat}
Author: djones
Date: Fri Nov 14 12:49:15 2014
New Revision: 1639624
URL: http://svn.apache.org/r1639624
Log:
Javadoc fix for LANG-1064.
Modified:
commons/proper/lang/trunk/src/changes/changes.xml
commons/proper/lang/trunk/src/main/java/org/apache/commons/lang3/StringUtils.java
{noformat}
> StringUtils.abbreviate description doesn't agree with the examples
> ------------------------------------------------------------------
>
> Key: LANG-1064
> URL: https://issues.apache.org/jira/browse/LANG-1064
> Project: Commons Lang
> Issue Type: Bug
> Reporter: B.J. Herbison
> Assignee: Duncan Jones
> Fix For: 3.4
>
>
> https://commons.apache.org/proper/commons-lang/javadocs/api-release/org/apache/commons/lang3/StringUtils.html#abbreviate%28java.lang.String,%20int%29
> {quote}
> If str is less than maxWidth characters long, return it.
> Else abbreviate it to (substring(str, 0, max-3) + "...").
> {quote}
> {quote}
> StringUtils.abbreviate("abcdefg", 7) = "abcdefg"
> {quote}
> The first element of the description probably means "less than or equal to"
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)