类 StringUtil
java.lang.Object
cn.vonce.sql.uitls.StringUtil
字符串工具类
-
字段概要
字段 -
构造器概要
构造器 -
方法概要
修饰符和类型方法说明static StringfirstToUpperCase(String str) 首字母转大写static StringgetBracketContent(String content) 获取指定字符串中括号内的内容,返回字符串数组static StringgetUUid()生成UUIDstatic String排除括号及括号内的数据static String驼峰命名转为符号分割命名static StringhumpToHyphen(String hump) 驼峰命名转为连字符命名static StringhumpToUnderline(String hump) 驼峰命名转为下划线命名static booleanstatic booleanstatic booleanisNotBlank(Object str) static booleanisNotEmpty(Object str) static StringrandomCode(int length) 生成一个几位的随机数static StringresolvePlaceholders(String text, Map<String, String> params) 将一段文本的占位符替换 如:${name} to zhangsanstatic StringunderlineToHump(String para) 下划线命名转为驼峰命名
-
字段详细资料
-
构造器详细资料
-
StringUtil
public StringUtil()
-
-
方法详细资料
-
isEmpty
-
isNotEmpty
-
isBlank
-
isNotBlank
-
getUUid
生成UUID -
randomCode
生成一个几位的随机数- 参数:
length- 随机数的长度
-
resolvePlaceholders
将一段文本的占位符替换 如:${name} to zhangsan- 参数:
text- 要替换的文本params- map.key = name,map.value = zhangsan- 返回:
- 替换后的文本
-
underlineToHump
下划线命名转为驼峰命名- 参数:
para- 下划线命名的字符串
-
humpToUnderline
驼峰命名转为下划线命名- 参数:
hump- 驼峰命名的字符串
-
humpToHyphen
驼峰命名转为连字符命名- 参数:
hump- 驼峰命名的字符串
-
humpTo
驼峰命名转为符号分割命名- 参数:
hump- 驼峰命名的字符串symbol- 符号
-
firstToUpperCase
首字母转大写- 参数:
str-- 返回:
-
getBracketContent
获取指定字符串中括号内的内容,返回字符串数组- 参数:
content-- 返回:
-
getWord
排除括号及括号内的数据- 参数:
content-- 返回:
-