the gs representation can be whatever you want, registering an adapter allows you to serialize content in whatever form is best for it. contentsetup in plone svn uses marshall for example on at content, with separate data file serialization for any file/image fields. for gs default, dav was used primarily as canonical likley because it was easy as already present generically on content implementations.



On Thu, 07 Dec 2006 13:51:38 -0500, Miles Waller <[EMAIL PROTECTED]> wrote:


What is the correct pattern for FTP representations of a CMF content type? I am trying to create a content export/import mechanism for some custom objects, but I've found a few different patterns to follow:

First of all, all content tries to use it's WebDAV representation. This is good for links and documents because it captures all the properties in one place. It's not so good for Files and Images because their metadata doesn't get exported/imported at all.

Secondly, the types which export a full set of information implement their own manage_FTPget methods which hard-code in the representation in some way. Document uses aliases, but only if the content type is text/html - if it is text/plain for example, aliases are bypassed. Link doesn't use aliases at all, and News just does whatever Document does.

Thirdly, folders store the title and description in a .properties file. The properties to be included in this file (title, description) are specifically specified in the import/export adapter.

My questions are:

  - what sort of pattern should be aimed for (ideally) here?

- should all the types use aliases to work out their DAV representation or was this abandonded?

- are there any 'hidden' advantages of im-/exporters adhering closely to the DAV views (as opposed to an im/export specific representation. e.g. a binary file and associated .properties file)

- should each object's representation take care of including all the required properties, or should there be some way of ensuring that all common metadata (DC values) are treated via some sort of common route


Zope-CMF maillist  -

See for bug reports and feature requests

Reply via email to