disposalTreeSize property
int
get
disposalTreeSize
The total size of the disposal tree rooted at the current Disposable instance.
This should only be used for debugging and profiling as it can incur a significant performance penalty if the tree is large.
Implementation
int get disposalTreeSize {
int size = 1;
for (var disposable in _internalDisposables) {
if (disposable is Disposable) {
size += disposable.disposalTreeSize;
} else {
size++;
}
}
return size;
}