Re: problem with defining a global class instance

2006-11-16 Thread [EMAIL PROTECTED]
sharath B N wrote: > hi, > i am sort of newbie to python. I am trying to do a super Market > simulation with OOP in python. I have problems with using a class > instance as global... > def generate (... ,,...) > > " in this function i define the global variables " > global stock,stockManager,

Re: problem with defining a global class instance

2006-11-16 Thread Fredrik Lundh
sharath B N wrote: > def generate (... ,,...) > > " in this function i define the global variables " > global stock,stockManager, manager etc. > > > class Manager > ... > ... > ... > def create_stockManager(..) > """ this is a method in class manager""" > stockManager = StockManager( name

problem with defining a global class instance

2006-11-16 Thread sharath B N
hi, i am sort of newbie to python. I am trying to do a super Market simulation with OOP in python. I have problems with using a class instance as global... def generate (... ,,...) " in this function i define the global variables " global stock,stockManager, manager etc. class Manager ... .