StringExtension extension

字符串相关

on

Properties

hasZh → bool

Available on String, provided by the StringExtension extension

是否含有中文
no setter
isAllNumber → bool

Available on String, provided by the StringExtension extension

是否是自然数
no setter
isEmail → bool

Available on String, provided by the StringExtension extension

是否是邮箱
no setter
isIdCard18 → bool

Available on String, provided by the StringExtension extension

是否是身份证
no setter
isIp → bool

Available on String, provided by the StringExtension extension

是否是ip地址
no setter
isPhone → bool

Available on String, provided by the StringExtension extension

是否是手机号
no setter
isPositiveNumber → bool

Available on String, provided by the StringExtension extension

正数
no setter
isTel → bool

Available on String, provided by the StringExtension extension

是否是座机号码
no setter
isUrl → bool

Available on String, provided by the StringExtension extension

是否是url
no setter
toBool → bool

Available on String, provided by the StringExtension extension

no setter
toDateTime → DateTime?

Available on String, provided by the StringExtension extension

no setter
toDouble → double?

Available on String, provided by the StringExtension extension

no setter
toInt → int?

Available on String, provided by the StringExtension extension

no setter

Methods

containsList(List<String> keys) → bool

Available on String, provided by the StringExtension extension

多关键字模糊匹配
ellipsis([int? length]) → String

Available on String, provided by the StringExtension extension

字符串中间截取
getDateStr() → String

Available on String, provided by the StringExtension extension

日期时间格式转换
getDateTimeStr() → String

Available on String, provided by the StringExtension extension

日期时间格式转换
getTimeStr() → String

Available on String, provided by the StringExtension extension

获取日期时间中的时间
hasMatch(String source) → bool

Available on String, provided by the StringExtension extension

正则表达式匹配
isIncludeIndex([int min = 10, int max = 20]) → bool

Available on String, provided by the StringExtension extension

长度范围