List of utility methods to do String Sub String
String | substringAfterIfExist(String source, String rev) substring After If Exist if (source == null) return source; int n = source.indexOf(rev); if (n == -1) return source; return source.substring(n + rev.length()); |
String | subStringAfterIgnoreCase(String str, String separator, Integer num) sub String After Ignore Case return subStringAfter(str, separator, num, true);
|
String | substringAfterLast(final String str, final String separator) Gets the substring after the last occurrence of a separator. if (isEmpty(str)) { return str; if (isEmpty(separator)) { return ""; final int pos = str.lastIndexOf(separator); if (pos == -1 || pos == str.length() - separator.length()) { ... |
String | substringAfterLast(final String str, final String separator) substring After Last if (str == null) { return null; final int pos = str.lastIndexOf(separator); if (pos == -1 || pos == (str.length() - separator.length())) { return ""; return str.substring(pos + separator.length()); ... |
String | substringAfterLast(final String value, final String searchValue) substring After Last final int index = value.lastIndexOf(searchValue); return (index < 0 || index >= value.length()) ? value : value.substring(index + 1); |
String | substringAfterLast(String input, String delimiter) substring After Last final int lastIndexOfDelimiter = input.lastIndexOf(delimiter); if (lastIndexOfDelimiter <= 0) return input; return input.substring(lastIndexOfDelimiter + 1); |
String | substringAfterLast(String str, String pattern) substring After Last return str.substring(str.lastIndexOf(pattern) + 1);
|
String | substringAfterLast(String str, String separator) substring After Last if (isEmpty(str)) { return str; if (isEmpty(separator)) { return ""; int pos = str.lastIndexOf(separator); if ((pos == -1) || (pos == str.length() - separator.length())) { ... |
String | substringAfterLast(String str, String separator) Gets the substring after the last occurrence of a separator. if (isEmpty(str)) { return str; if (isEmpty(separator)) { return EMPTY; int pos = str.lastIndexOf(separator); if (pos == INDEX_NOT_FOUND || pos == (str.length() - separator.length())) { ... |
String | substringAfterLast(String string, String delimiter) Returns the substring after the last delimiter of the specified occurrence. final int index = string.lastIndexOf(delimiter); if (index == -1 || string.endsWith(delimiter)) { return ""; return string.substring(index + 1); |