Adding method to object

marco marc.lentz at ctrceal.caisse-epargne.fr
Wed Dec 3 12:55:38 EST 2003


> > Is it possible to do the same thing for an attribut, instead of a method
?
> >
> > i'd like to wrap an newAttribute to an oldAttribute one :
> > example:
> > i've got an instance "n" of an "xmlNode" class
> > i'd like to use "n.parentNode" instead of "n.parent" ...
> [snip]
>
> # try this ...
> n.parentNode = n.parent

i'll try,
but ... it s not dynamic ....

if n.parent change .... n.parentNode will not change ... it must be
re-affected ... not ?







More information about the Python-list mailing list