Futurescale, Inc. PureMVC Home

The PureMVC Framework Code at the Speed of Thought

Over 10 years of community discussion and knowledge are maintained here as a read-only archive.

New discussions should be taken up in issues on the appropriate projects at https://github.com/PureMVC

Pages: [1]
Author Topic: removeAllProxies and removeAllMediators  (Read 3739 times)
Posts: 4

View Profile Email
« on: January 15, 2009, 07:22:37 »

When deleting/cleaning an application i want to remove all registered proxies and mediators from the model and view. Would'nt it be great, if the model had the method removeAllProxies() and the view removeAllMediators()?
The Method iterates the proxyMap and calls the removeProxy method. The same with the view.
This would help cleaning/deleting an application module when removing it from a core application (garbage collection).
Global Moderator
Hero Member
Posts: 2871

View Profile WWW Email
« Reply #1 on: January 15, 2009, 10:00:22 »

When you unload a module, as long as you aren't retaining any references to things inside that module, you don't have to completely deconstruct it to make its pieces be GC'd. Check out this article on Garbage Collection by Simon Bailey. He really crunched the MultiCore GC problem hard:


Pages: [1]