getTypeOrNull<T> method
T?
getTypeOrNull<T>()
Implementation
T? getTypeOrNull<T>() {
try {
return _values.singleWhere((element) => element is T);
} catch (e) {
return null;
}
}
T? getTypeOrNull<T>() {
try {
return _values.singleWhere((element) => element is T);
} catch (e) {
return null;
}
}