Mix<T extends Attribute>.fromMaybeList constructor
Mix<T extends Attribute>.fromMaybeList (
- List<
T?> attributes
Instantiate a mix from a List of Attribute instances (attributes argument can be null)
Implementation
factory Mix.fromMaybeList(List<T?> attributes) {
final validAttributes = attributes.whereType<T>();
return Mix.fromList(validAttributes.toList());
}