class - How to actively delete a Dart object? -


i'm building dart app contains variety of class objects. particular class object i'm dealing contains variety of stream event listeners on dom elements. when remove these objects dom , untrack class object these listeners persist.

i know dart runs garbage collection eventually, i'm not 100% sure come along , delete these class objects since there watcher , stream listeners continue.

my question is, there way actively delete class object immediately? tried setting class object null doesn't seem work reason. when check if object exists afterward print statement, still lists instance of class object.

furthermore, i'm trying accomplish, canceling streams doesn't seem enough. need destroy class object.

setting references null can do. test seems weird. how can print object if don't have reference? if still have reference, how can expect instance collected.


Comments

Popular posts from this blog

c++ - Difference between pre and post decrement in recursive function argument -

php - Nothing but 'run(); ' when browsing to my local project, how do I fix this? -

php - How can I echo out this array? -