dynamic modules
Werner Schiendl
ws-news at gmx.at
Tue Dec 18 14:53:10 EST 2001
More information about the Python-list mailing list
Tue Dec 18 14:53:10 EST 2001
- Previous message (by thread): dynamic modules
- Next message (by thread): dynamic modules
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Hi, you can create a type (a class) instead of a plain module. When the reference count drops to zero, the instance will then be deleted. It is probably possibly to create a singleton class, that always returns one single instance if there is one instead of creating a new one every time. But I never tried that. hth Werner "Marek Budyn" <rayn at infostrade.com.pl> wrote in message news:9vo01n$9j8$1 at news.tpi.pl... > Hi! > > I wanted go create dynamically loaded and removed plugins. I mean, id a > module a initalizes with 10 MB data structude, i would like to remove it > from memory if it is not needed eg. > > p1 = import plugin1 > > ... > > unload(p1) > > Is it possible in python ? And if so, how can I do this ? > Thanks for help! > > Marek Budyn > rayn at infostrade.com.pl > > > >
- Previous message (by thread): dynamic modules
- Next message (by thread): dynamic modules
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list