From b419209310112939039b6e2935bee6c53cdf7a52 Mon Sep 17 00:00:00 2001
From: ZhuDongming <773644075@qq.com>
Date: Thu, 25 Jul 2019 14:30:48 +0800
Subject: [PATCH] 新增无人机飞行轨迹地图页面
---
src/main/java/com/moral/common/util/StringUtils.java | 21 ++++++++++++++++++++-
1 files changed, 20 insertions(+), 1 deletions(-)
diff --git a/src/main/java/com/moral/common/util/StringUtils.java b/src/main/java/com/moral/common/util/StringUtils.java
index b6925d9..87d1cd0 100644
--- a/src/main/java/com/moral/common/util/StringUtils.java
+++ b/src/main/java/com/moral/common/util/StringUtils.java
@@ -1,11 +1,21 @@
package com.moral.common.util;
+import com.mysql.jdbc.TimeUtil;
+
+import javax.validation.constraints.NotNull;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;
+/**
+ *
+ * ������������: string ���������
+ * @author: fengxiang
+ * @date: 2018/7/30 10:53
+ */
public class StringUtils {
public static final char UNDERLINE = '_';
+ public static final String NULL = "null";
/**
* ������������������������������������������������������
@@ -44,7 +54,7 @@
return sb.toString();
}
public static boolean isNullOrEmpty(String toTest) {
- return toTest == null || toTest.length() == 0;
+ return toTest == null || toTest.length() == 0 || NULL.equals(toTest);
}
public static Object stringToObject4Type(Class<?> type,String value) throws Exception{
Object result = value;
@@ -132,4 +142,13 @@
sbuffer.append(suffix);
return sbuffer.toString();
}
+ public static boolean isNumericZidai(String str) {
+ for (int i = 0; i < str.length(); i++) {
+ //System.out.println(str.charAt(i));
+ if (!Character.isDigit(str.charAt(i))) {
+ return false;
+ }
+ }
+ return true;
+ }
}
--
Gitblit v1.8.0