How to determine the number of instances of a class at any given point of time?
Printable View
How to determine the number of instances of a class at any given point of time?
Add a static member variable which you increment in the constructor and decrement in the desctructor
Hi
Take the concept of COM reference counting implementation and maintain a counter.
Regards
S.K.Pradhan
Be sure to rate answers if it helped, to encourage them.