parseBoolsFromInlineList function
Parses s to a List<bool>.
delimiter pattern for delimiter if s is a String.
def the default value if s is invalid.
Implementation
List<bool>? parseBoolsFromInlineList(
Object? s,
Pattern delimiter, [
List<bool>? def,
]) {
if (s == null) return def;
if (s is bool) return [s];
if (s is List) return s.map((e) => parseBool(e)).nonNulls.toList();
return parseFromInlineList(
s.toString(),
delimiter,
(v) => parseBool(v)!,
def,
);
}