Adding method to object

Sean Ross frobozz_electric at hotmail.com
Wed Dec 3 12:37:51 EST 2003


"marco" <marc.lentz at ctrceal.caisse-epargne.fr> wrote in message
news:bqkrsb$nf1$2 at s1.read.news.oleane.net...
> 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

HTH
Sean






More information about the Python-list mailing list