How can I get all instances from a particular class or kill all instances of a particular class?
For example, I have a class MyClassthat I repeat three times as m1, m2and m3.
Is there any way to get or kill all of these instances?
more explanation: when I have a "settings" class. When the user clicks the Options button, the application makes an instance of this class. When he presses the same button again, he creates a new instance. I want it to show only one instance and not create a new instance
source
share