metaclasses: timestamping instances
Gabriel Genellina
gagsl-py2 at yahoo.com.ar
Mon Sep 3 20:43:29 EDT 2007
More information about the Python-list mailing list
Mon Sep 3 20:43:29 EDT 2007
- Previous message (by thread): metaclasses: timestamping instances
- Next message (by thread): Is there a simple way to exit a while loop on keystroke?
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
En Mon, 03 Sep 2007 07:39:05 -0300, km <srikrishnamohan at gmail.com> escribi�: > But why does it show varied difference in the time between a and b > instance creations when __metaclass__ hook is used and when not used in > class Y ? I dont understand that point ! What do you expect from a._created, b._created, and its difference? You reset Meta.start each time - so _created measures the time between creation of two consecutive instances (minus a small delay because of the *two* calls to time.time()) And obviously the elapsed time until the second instance is created is larger, due to the intervening print statement. -- Gabriel Genellina
- Previous message (by thread): metaclasses: timestamping instances
- Next message (by thread): Is there a simple way to exit a while loop on keystroke?
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list