Addressing second round of review issues

This commit is contained in:
Torsten Grote
2016-10-19 09:03:48 -02:00
parent 0523c4e718
commit 8f882dc910
26 changed files with 167 additions and 164 deletions

View File

@@ -86,4 +86,11 @@ public class StringUtils {
public static String trim(String s) {
return s.trim();
}
/**
* Returns true if the string is longer than maxLength
*/
public static boolean isTooLong(String s, int maxLength) {
return toUtf8(s).length > maxLength;
}
}