Re: Class and instance related questions.

2014-01-24 Thread Terry Reedy
On 1/24/2014 3:45 PM, Chris Angelico wrote: On Sat, Jan 25, 2014 at 7:32 AM, Asaf Las wrote: On Friday, January 24, 2014 6:37:29 PM UTC+2, Chris Angelico wrote: On Sat, Jan 25, 2014 at 3:31 AM, Asaf Las wrote: Hi Is there way to get list of instances of particular class through class itself?

Re: Class and instance related questions.

2014-01-24 Thread Dave Angel
Asaf Las Wrote in message: > On Friday, January 24, 2014 10:45:30 PM UTC+2, Chris Angelico wrote: >> On Sat, Jan 25, 2014 at 7:32 AM, Asaf Las wrote: >> > On Friday, January 24, 2014 6:37:29 PM UTC+2, Chris Angelico wrote: >> >> >> It's possible to unbind the name, but every instance retains a

Re: Class and instance related questions.

2014-01-24 Thread Asaf Las
On Friday, January 24, 2014 11:18:08 PM UTC+2, Chris Angelico wrote: > On Sat, Jan 25, 2014 at 8:03 AM, Asaf Las wrote: > > Chris, i like answers which open doors to my curiosity :-) > > yet i should spend my credits very carefully :-) > Trust me, there is no limit to what you can learn when you h

Re: Class and instance related questions.

2014-01-24 Thread Chris Angelico
On Sat, Jan 25, 2014 at 8:03 AM, Asaf Las wrote: > Chris, i like answers which open doors to my curiosity :-) > yet i should spend my credits very carefully :-) Trust me, there is no limit to what you can learn when you have that kind of curiosity! Ask more questions and you'll get more details.

Re: Class and instance related questions.

2014-01-24 Thread Asaf Las
On Friday, January 24, 2014 10:45:30 PM UTC+2, Chris Angelico wrote: > On Sat, Jan 25, 2014 at 7:32 AM, Asaf Las wrote: > > On Friday, January 24, 2014 6:37:29 PM UTC+2, Chris Angelico wrote: > >> On Sat, Jan 25, 2014 at 3:31 AM, Asaf Las wrote: > >> > Hi > >> > Is there way to get list of instan

Re: Class and instance related questions.

2014-01-24 Thread Chris Angelico
On Sat, Jan 25, 2014 at 7:32 AM, Asaf Las wrote: > On Friday, January 24, 2014 6:37:29 PM UTC+2, Chris Angelico wrote: >> On Sat, Jan 25, 2014 at 3:31 AM, Asaf Las wrote: >> > Hi >> > Is there way to get list of instances of particular >> > class through class itself? via metaclass or any other m

Re: Class and instance related questions.

2014-01-24 Thread Asaf Las
Hi Chris Thanks for answers On Friday, January 24, 2014 6:37:29 PM UTC+2, Chris Angelico wrote: > On Sat, Jan 25, 2014 at 3:31 AM, Asaf Las wrote: > > Hi > > Is there way to get list of instances of particular > > class through class itself? via metaclass or any other method? > Not automatical

Re: Class and instance related questions.

2014-01-24 Thread Chris Angelico
On Sat, Jan 25, 2014 at 3:31 AM, Asaf Las wrote: > Hi > > Is there way to get list of instances of particular > class through class itself? via metaclass or any other method? Not automatically, but you can make a class that keeps track of its instances with a weak reference system. > Another que

Class and instance related questions.

2014-01-24 Thread Asaf Las
Hi Is there way to get list of instances of particular class through class itself? via metaclass or any other method? Another question - if class is object is it possible to delete it? If it is possible then how instances of that class will behave? Thanks Asaf -- https://mail.python.org/