[z3-five] Re: SimpleViewClass and __hash__
Tarek Ziadé
tziade at nuxeo.com
Tue May 10 12:51:20 CEST 2005
Philipp von Weitershausen wrote:
> Florent Guillaume wrote:
>
>> Philipp von Weitershausen wrote:
>>
>>>> No. I'm saying that if the published doesn't have a getId() method,
>>>> then
>>>> you pass an object to getThemeByMethod instead of a string.
>>>
>>>
>>> So, what's an obvious solution then? Add a getId() method to Five's
>>> ZPTs? (I'd rather do that instead of adding a weird __hash__...)
>>
>>
>>
>> That could work yes. It's probably a good idea to give a getId to
>> objects used in a Zope 2 context in any case.
>
>
+1 That makes me think we also add extra getId()'s in our
zope-3-but-in-zope-2 products objects at this time
> You are probably quite right. However, I just looked at
> Products.PageTemplates.PageTemplateFile and PageTemplateFile actually
> inherits from OFS.SimpleItem.Item_w__name__, so our
> ZopeTwoPageTemplateFile (which inherits from PageTeplateFile) should
> already have a getId() method...
In my case they don't have a getId(),
I am getting confused, the object I have is a SimpleViewClass generated
in Five.metaclass with the makeClass method, given a ZopeTwoPageTemplate
Should it be added on the fly ?
All those wrappings are confusing me, i am a bit lost in the mechanism :)
>
> So, I guess the problem occurs with subclasses of
> ViewMixinForAttributes and ViewMixinForTemplates then?
>
> Philipp
> _______________________________________________
> z3-five mailing list
> z3-five at codespeak.net
> http://codespeak.net/mailman/listinfo/z3-five
--
Tarek ZIADE, Nuxeo SARL: Zope Service Provider.
Mail: tz at nuxeo.com - Tel: +33 (0)6 30 37 02 63
Nuxeo Collaborative Portal Server: http://www.nuxeo.com/cps
Gestion de contenu web / portail collaboratif / groupware / open source
More information about the z3-five
mailing list