find<K, V> method
Implementation
MapEntry<K, V>? find<K, V>({Check<K>? key, Check<V>? value}) {
if (isNotEmpty(key) && isNotEmpty(value)) {
for (final entry in entries) {
if (key!(entry.key) && value!(entry.value)) {
return MapEntry(entry.key, entry.value);
}
}
}
if (isNotEmpty(key)) {
for (final key in keys) {
if (key!(key)) {
return MapEntry(key, this[key]);
}
}
}
if (isNotEmpty(value)) {
for (final value in values) {
if (value!(value)) {
return MapEntry(keys.first, value);
}
}
}
return null;
}