Commit af530f0a authored by Gaston Dombiak's avatar Gaston Dombiak Committed by gato

Ported javadoc work.

git-svn-id: http://svn.igniterealtime.org/svn/repos/wildfire/branches@4400 b35dd754-fafc-0310-a699-88a17e54d16e
parent 38325900
...@@ -929,20 +929,19 @@ public class StringUtils { ...@@ -929,20 +929,19 @@ public class StringUtils {
return collection; return collection;
} }
/** /**
* Abbreviates a string to a specified length and then adds an ellipsis * Abbreviates a string to a specified length and then adds an ellipsis
* if the input is greater than the maxWidth. Example input: * if the input is greater than the maxWidth. Example input:
* * <pre>
* user1@jivesoftware.com/home * user1@jivesoftware.com/home
* * </pre>
* and a maximum length of 20 characters, the abbreviate method will return: * and a maximum length of 20 characters, the abbreviate method will return:
* * <pre>
* user1@jivesoftware.c... * user1@jivesoftware.c...
* * </pre>
* @param str the String to abbreviate, can be null * @param str the String to abbreviate.
* @param maxWidth, the maximum size of the string, minus the ellipsis * @param maxWidth the maximum size of the string, minus the ellipsis.
* @return abbreviated String, <code>null</code if input is null * @return the abbreviated String, or <tt>null</tt> if the string was <tt>null</tt>.
*/ */
public static String abbreviate(String str, int maxWidth) { public static String abbreviate(String str, int maxWidth) {
if (null == str) { if (null == str) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment