endWithAny static method
给定字符串是否以任何一个字符串结尾
给定字符串和数组为空都返回false
Implementation
static bool endWithAny(String str, List<String> suffixes) {
if (isEmpty(str) || ListUtil.isEmpty(suffixes)) {
return false;
}
for (var suffix in suffixes) {
if (str.endsWith(suffix)) {
return true;
}
}
return false;
}