commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Gary D. Gregory (Jira)" <j...@apache.org>
Subject [jira] [Resolved] (LANG-1463) StringUtils abbreviate returns String of length greater than maxWidth
Date Mon, 04 Nov 2019 23:03:00 GMT

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

Gary D. Gregory resolved LANG-1463.
-----------------------------------
    Fix Version/s: 3.10
       Resolution: Fixed

In git master. Please verify and close.

> StringUtils abbreviate returns String of length greater than maxWidth
> ---------------------------------------------------------------------
>
>                 Key: LANG-1463
>                 URL: https://issues.apache.org/jira/browse/LANG-1463
>             Project: Commons Lang
>          Issue Type: Bug
>          Components: lang.*
>    Affects Versions: 3.9
>            Reporter: Thomas Wessendorf
>            Priority: Minor
>             Fix For: 3.10
>
>
> In the JavaDoc of StringUtils.abbreviate(final String str, final String abbrevMarker,
final int maxWidth) is written, that the method in no case will return a String of length
greater than maxWidth. This doesn't hold, if abbrevMarker is an empty string.
> Expected behaviour:
> abbreviate("much too long text", "", 13).equals("much too long")
>  
> Actual behaviour:
> abbreviate("much too long text", "", 13).equals("much too long text")



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Mime
View raw message