Browse Source

添加 hasBlank

James 5 years ago
parent
commit
8ba2017b94
1 changed files with 13 additions and 0 deletions
  1. 13 0
      src/main/java/com/jfinal/kit/StrKit.java

+ 13 - 0
src/main/java/com/jfinal/kit/StrKit.java

@@ -79,6 +79,19 @@ public class StrKit {
 		return true;
 	}
 	
+	public static boolean hasBlank(String... strings) {
+		if (strings == null || strings.length == 0) {
+			return true;
+		}
+		
+		for (String str : strings) {
+			if (isBlank(str)) {
+				return true;
+			}
+		}
+		return false;
+	}
+	
 	public static boolean notNull(Object... paras) {
 		if (paras == null) {
 			return false;