com.zys.mybatis.utils.StringUtils Maven / Gradle / Ivy
package com.zys.mybatis.utils;
/**
* @author zys
* @version 1.0
* @date 2021/1/25 15:47
*/
public class StringUtils {
public static boolean isNotBlank(CharSequence cs) {
return !isBlank(cs);
}
public static boolean isBlank(CharSequence cs) {
int strLen = length(cs);
if (strLen != 0) {
for (int i = 0; i < strLen; ++i) {
if (!Character.isWhitespace(cs.charAt(i))) {
return false;
}
}
}
return true;
}
public static int length(CharSequence cs) {
return cs == null ? 0 : cs.length();
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy