isWeak property
bool
get
isWeak
Whether this reference is marked as weak (not strong). See isStrong.
NOTE: This does NOT verify if the target is still reachable (see isAlive). It only checks that no strong reference exists and a weak reference object is present. The referenced object may already have been garbage-collected.
Implementation
bool get isWeak => _strongRef == null && _weakRef != null;