isNotNull property

bool get isNotNull

Returns true if this object is not null.

Example:

String? name = 'John';
print(name.isNotNull); // true

Implementation

bool get isNotNull => this != null;