Allan Miller wrote:
I am VERY new to Zope development, having come from a mainstream Java Struts and Perl CGI web development background. I've been looking at the source code for various Zope Products and applications, and haven't seen a lot of classes used.
For applications, you won't see too many classes. Products are usually built using classes though...
The applications and Products I've seen define one or two application or Product classes, and consist of a lot of ZPT's that are essentially forms paired with, or posting to, PythonScripts.
That's about right.
I wonder - am I missing something? It seems like the applications are organized almost exclusively around ZPT's and PythonScripts, with no use of business objects/classes, for example. Is this the unusual approach? Can anyone point me towards some applications that are considered well designed - make good use of programmer defined (espcially domain) classes? How about some articles on good Zope application design practices?
Can't help there really. In Zope, you can be as regid or as flexible as you want with your development. If you want formality, lots of classes, etc, then you can develop a disk-based python product to solve your problem. This is more powerful (not always a good thing) but often slower to develop. The more pragmatic approach used by most Zope developers is to re-use standard Zope objects in new and interesting ways (ZCatalog, Folders, BTreeFolder2's and PropertyManagers are your friends here) and tie them together with scripts and page templates organised using folders and obtained using Acquisition. cheers, Chris -- Simplistix - Content Management, Zope & Python Consulting - http://www.simplistix.co.uk