removeBetweenSpaceMayNull static method
移除str两端的(空格|制表符\t),
如果str为null或移除空白符号后得到空字符串则返回null
Implementation
static String? removeBetweenSpaceMayNull(
String? str, {
bool removeLine = true,
bool subLeft = true,
bool subRight = true,
}) {
if (null == str) {
return null;
}
final result = removeBetweenSpace(
str,
removeLine: removeLine,
subLeft: subLeft,
subRight: subRight,
);
if (result.isEmpty) {
return null;
}
return result;
}