程序包 amo.lib.utils
类 StringUtils
java.lang.Object
amo.lib.utils.StringUtils
public class StringUtils extends Object
-
构造器概要
构造器 构造器 说明 StringUtils() -
方法概要
修饰符和类型 方法 说明 static StringconvertDateToString(Date date, String format)Date按照一定格式转Stringstatic DateconvertStringToDate(String dateStr, String format)String按照一定格式转Datestatic IntegergetInteger(String str)String转Integerstatic booleanisBlank(String str)static BooleanisNotEmpty(String str)static BooleanisNotEmpty(List<?> list)static BooleanisNullOrEmpty(String str)static BooleanisNullOrEmpty(List<?> list)static List<Integer>split(String ids, String regex)将String分割,转为Integer列表static StringsubstringBefore(String str, String separator)static StringtrimBracket(String source)移除前后的括号()
-
构造器详细资料
-
StringUtils
public StringUtils()
-
-
方法详细资料
-
isBlank
-
trimBracket
移除前后的括号()- 参数:
source- input string- 返回:
- result string(trim the start "(" and end ")")
-
isNullOrEmpty
-
isNotEmpty
-
substringBefore
-
split
将String分割,转为Integer列表- 参数:
ids- 原字符串regex- 分割字符串- 返回:
- Integer列表
-
getInteger
String转Integer- 参数:
str- input string- 返回:
- int value
-
isNotEmpty
-
isNullOrEmpty
-
convertStringToDate
String按照一定格式转Date- 参数:
dateStr- 原始Stringformat- 格式- 返回:
- Date
-
convertDateToString
Date按照一定格式转String- 参数:
date- Dateformat- 格式- 返回:
- String
-