Personal tools
Skip to content. | Skip to navigation
This package provides a framework to develop componentized Web GUI applications. Instead of describing the content of a page using a single template or static system of templates and METAL macros, content provider objects are dynamically looked up based on the setup/configuration of the application.
A utility module for content-type handling.
This package provides a pluggable way to copy persistent objects. It was once extracted from the zc.copy package to contain much less dependencies. In fact, we only depend on zope.interface to provide pluggability. The package provides a clone function that does the object cloning and the copy wrapper that sets __parent__ and __name__ attributes of object's copy to None. This is useful, when working with Zope's located objects (see zope.location package). The copy function actually calls the clone function so we'll use the first one in the examples below. We'll also look a bit at their differences in the end of this document. The clone function (and thus the copy function that wraps it) uses pickling to copy the object and all its subobjects recursively. As each object and subobject is pickled, the function tries to adapt it to zope.copy.interfaces.ICopyHook. If a copy hook is found, the recursive copy is halted. The hook is called with two values: the main, top-level object that is being copied; and a callable that supports registering functions to be called after the copy is made. The copy hook should return the exact object or subobject that should be used at this point in the copy, or raise zope.copy.interfaces.ResumeCopy exception to resume copying the object or subobject recursively after all. Note that we use zope's component architecture provided by the zope.component package in this document, but the zope.copy package itself doesn't use or depend on it, so you can provide another adaptation mechanism as described in zope.interface's adapter documentation.
This package provides Copy, Paste and Move support for content components in Zope. In particular, it defines the following interfaces for this kind of functionality: * IObjectMover, * IObjectCopier, * IContentItemRenamer, * IPrincipalClipboard as well as standard implementations for containers and contained objects as known from the zope.container package.
Commonly used date and time related utility functions.
zope.decorator
Often, especially for package modules, you want to import names for convenience, but not actually perform the imports until necessary. The zope.deferredimport package provided facilities for defining names in modules that will be imported from somewhere else when used. You can also cause deprecation warnings to be issued when a variable is used.
When we started working on Zope 3.1, we noticed that the hardest part of the development process was to ensure backward-compatibility and correctly mark deprecated modules, classes, functions, methods and properties. This package provides a simple function called 'deprecated(names, reason)' to deprecate the previously mentioned Python objects.
zope.documenttemplate
The zope.dottedname module provides one function, resolve that resolves strings containing dotted names into the appropriate python object. Dotted names are resolved by importing modules and by getting attributes from imported modules. Names may be relative, provided the module they are relative to is supplied.