You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Gabriele Kahlout (JIRA)" <ji...@apache.org> on 2011/05/21 18:48:47 UTC
[jira] [Updated] (LANG-701) VarArgs Join
[ https://issues.apache.org/jira/browse/LANG-701?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Gabriele Kahlout updated LANG-701:
----------------------------------
Attachment: VarArgJoinTest.java
2 methods (one wrapper) for the suggested feature, and a test of each method (all in the same file). I hope you consider including it in StringUtils.
> VarArgs Join
> ------------
>
> Key: LANG-701
> URL: https://issues.apache.org/jira/browse/LANG-701
> Project: Commons Lang
> Issue Type: New Feature
> Components: lang.text.*
> Reporter: Gabriele Kahlout
> Priority: Minor
> Attachments: VarArgJoinTest.java
>
>
> <code>
> final String apple = "apple";
> final String banana = "banana";
> final String orange = "orange";
> final String expected = apple + SPACE + banana + SPACE + orange;
> final String actual = join(SPACE, apple, banana, orange);
> final int expLength = expected.length();
> final int actLength = actual.length();
> assertEquals(expLength, actLength);
> assertEquals(expected, actual);
> </code>
> I missed the functionality of joining strings with the space separator in one line. BTW, why space ' ' not a constant field anywhere?
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira