containsKey abstract method
- Object?key
Whether this map contains the givenkey.
Returns true if any of the keys in the map are equal tokeyaccording to the equality used by the map.
final moonCount = <String, int>{'Mercury': 0, 'Venus': 0, 'Earth': 1, 'Mars': 2, 'Jupiter': 79, 'Saturn': 82, 'Uranus': 27, 'Neptune': 14};final containsUranus = moonCount.containsKey('Uranus'); // truefinal containsPluto = moonCount.containsKey('Pluto'); // falseImplementation
bool containsKey(Object? key);