[Grok-dev] Dolmen and its releases
Martin Aspeli
optilude+lists at gmail.com
Thu Oct 22 10:39:04 EDT 2009
Souheil CHELFOUH wrote:
> the field property is a property that handles the persistency of your
> data transparently. And because code is always better than bad english
> explanations:
>
>
>>>> from persistent import Persistent
>>>> from dolmen.file import FileProperty, FileField
>>>> from zope.interface import Interface, implements
>
>>>> class IContent(Interface):
> ... binary = FileField(title=u"Binary data")
>
>>>> class MyContent(Persistent):
> ... implements(IContent)
> ... binary = FileProperty(IContent['binary'])
What does this do above and beyond just setting an object onto the
instance (like plone.namedfile or zope.app.file or z3c.blobfile do)?
Extra validation?
Martin
--
Author of `Professional Plone Development`, a book for developers who
want to work with Plone. See http://martinaspeli.net/plone-book
More information about the Grok-dev
mailing list