mirror of
https://github.com/Jozufozu/Flywheel.git
synced 2025-01-10 06:16:07 +01:00
13 lines
276 B
Java
13 lines
276 B
Java
|
package com.jozufozu.flywheel.util;
|
||
|
|
||
|
public class StringUtil {
|
||
|
public static String trimEnd(String value) {
|
||
|
int len = value.length();
|
||
|
int st = 0;
|
||
|
while ((st < len) && Character.isWhitespace(value.charAt(len - 1))) {
|
||
|
len--;
|
||
|
}
|
||
|
return value.substring(0, len);
|
||
|
}
|
||
|
}
|