Take a string of LS separated strings and sort them and return them as a concatenated (LS separated) string. @param in string of lines to be sorted. @return sorted result.
(final String in)
| 621 | * @return sorted result. |
| 622 | */ |
| 623 | public static String sortLines(final String in) { |
| 624 | final String[] split = splitLines(in); |
| 625 | Arrays.sort(split); |
| 626 | //System.err.println(Arrays.toString(split)); |
| 627 | final StringBuilder sb = new StringBuilder(); |
| 628 | for (final String s : split) { |
| 629 | sb.append(s).append(StringUtils.LS); |
| 630 | } |
| 631 | return sb.toString(); |
| 632 | } |
| 633 | |
| 634 | /** |
| 635 | * Concatenates lines in input |
nothing calls this directly
no test coverage detected