Commit d353d6f7 authored by yanzg's avatar yanzg

消除成功接收处理

parent aea3e881
......@@ -99,6 +99,28 @@ public class StringHelper {
return EMPTY;
}
/**
* 传入很多字符串,获取第一个非空的字符串,至少需要两个参数
*
* @param from0 第一个参数
* @param froms 参数列表
* @return 第一个非空字符串
*/
public static String getFirstNull(String from0, String... froms) {
if (!isEmpty(from0)) {
return from0;
}
if (froms != null) {
for (String from : froms) {
if (!isEmpty(from)) {
return from;
}
}
}
return null;
}
/**
* 检测值是否为数字
*
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment