StringNullSafety extension

String空安全扩展

on

Properties

isNotNullOrEmpty → bool

Available on String?, provided by the StringNullSafety extension

判断字符串是否不为空
no setter
isNullOrEmpty → bool

Available on String?, provided by the StringNullSafety extension

判断字符串是否为空
no setter
toNonNull → String

Available on String?, provided by the StringNullSafety extension

转化为非空字符串,如果为空则返回''
no setter

Methods

toNonNullString([String def = '']) → String

Available on String?, provided by the StringNullSafety extension

判断字符串是否为空,如果为空则返回默认值