Personal tools
You are here: Home Zope & Plone tips One-liner to set attributes on a class using keyword arguments at class initialization
Navigation
 
Document Actions
  • Send this page to somebody
  • Print this page
  • Add Bookmarklet

One-liner to set attributes on a class using keyword arguments at class initialization

by tibi last modified 2007-07-08 18:38
class Target:
    def __init__(self, **kw):
        self.__dict__.update(kw)
Creative Commons License
This work is licensed under a Creative Commons Attribution 3.0 License.
 

Powered by Plone CMS, the Open Source Content Management System

This site conforms to the following standards: