need extra utility functions on properties

Issue #57 resolved
Mike Bayer repo owner created an issue

the property objects attached to classes should have enhanced options to improve setters/getters, i.e.:

    m = mapper(User, users)

    User.email.get = getstuff
    User.email.set = emailvalidator
    User.email.del = deleteemail

plus allow a decorator style:

   class User(object):
        @property_set('email')
        def set_email(self, email):
           ...

        @property_get('email')
        def get_email(self):
          ...

Comments (3)

  1. Mike Bayer reporter

    this is seeming like TMTOWTDI at the moment. we can add new things to properties but there hasnt yet been much of a need. wait for further inspiration on this one !

  2. Log in to comment