I want to write a cost analysis method for a number of different classes that would count the number of times certain objects have been created. The easy way would be to increment a variable in the constructors for each of them, but I was wondering if it's possible to just go through every object currently in use using reflection?
Aucun commentaire:
Enregistrer un commentaire