[Zope] Classes

Tom Deprez tom.deprez@uz.kuleuven.ac.be
Mon, 28 Feb 2000 12:23:29 +0100


This is what I'm trying to achieve :

A ZClass when added, fills some properties according to where it is created.
eg. a propety called Parent. When the instance of the class is created, it
looks for its parent-name and puts that name in the property 'Parent'.
When the instance is moved, it should look again for the name of its parent
(because the parent is changed) and thus change it's property 'Parent'.

(this is a dumb example, but I think it illustrates what I want to achieve).

Thanks in advance,
Tom.

At 16:50 28/02/2000 +0530, Shalabh Chaturvedi wrote:
>From: Tom Deprez
>> Hi,
>>
>> Is there a view which allows you to map a method to the creation of a
class?
>> (eg, like we map a propertiesform to the properties view)
>>
>> ie. A method which is operated when a class is created?
>>
>> Thanks in advance,
>>
>> Tom.
>
>What exactly do you want to do ?
>
>If you're working with ZClasses, I think what you want is the Factory.
When you
>add a 'Zope Factory' to Product, you really associate a method with an
item in
>the ubiquitous drop down 'add' list.
>
>Hope this helps.
>
>Shalabh
>
>