Re: [Zope-CMF] IMember: does it exist?
Jens Vagelpohl <[EMAIL PROTECTED]> writes: > > > On Oct 8, 2008, at 01:32 , Paul Winkler wrote: > > > Rob Miller <[EMAIL PROTECTED]> writes: > >> then CMF does it's normal wrapping of these user objects using the > >> standard > >> MemberData implementation. > > > > Hmm, right, so then this might still be on-topic here > > Maybe the right thing is for CMF to do a directlyProvides() call in > > wrapUser? > > The CMF itself doesn't need this. There's no place that tries to > ensure a member does indeed provide IMemberData or similar. In that case I'd be inclined to leave CMF alone, until somebody actually depends on that behavior. > If this is > something you need for Plone I'm happy to consider patches with tests. Not me; I was initially just trying to understand how the interfaces relate to each other. To me it's just a documentation issue. (Oh, and Philip, thanks for the reminder about alsoProvides(); I've made that mistake before and should have learned from it by now!) - PW ___ Zope-CMF maillist - Zope-CMF@lists.zope.org http://mail.zope.org/mailman/listinfo/zope-cmf See https://bugs.launchpad.net/zope-cmf/ for bug reports and feature requests
Re: [Zope-CMF] IMember: does it exist?
Paul Winkler wrote: > Rob Miller <[EMAIL PROTECTED]> writes: >> then CMF does it's normal wrapping of these user objects using the >> standard >> MemberData implementation. > > Hmm, right, so then this might still be on-topic here ;-) > Maybe the right thing is for CMF to do a directlyProvides() call in wrapUser? Please consider using alsoProvides() since directlyProvides *overrides* all directly set interfaces. alsoProvides *adds* to them. ___ Zope-CMF maillist - Zope-CMF@lists.zope.org http://mail.zope.org/mailman/listinfo/zope-cmf See https://bugs.launchpad.net/zope-cmf/ for bug reports and feature requests
Re: [Zope-CMF] IMember: does it exist?
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Oct 8, 2008, at 01:32 , Paul Winkler wrote: > Rob Miller <[EMAIL PROTECTED]> writes: >> then CMF does it's normal wrapping of these user objects using the >> standard >> MemberData implementation. > > Hmm, right, so then this might still be on-topic here ;-) > Maybe the right thing is for CMF to do a directlyProvides() call in > wrapUser? The CMF itself doesn't need this. There's no place that tries to ensure a member does indeed provide IMemberData or similar. If this is something you need for Plone I'm happy to consider patches with tests. jens -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.8 (Darwin) iEYEARECAAYFAkjsYVsACgkQRAx5nvEhZLKp+wCeNXxY6pPNfOSf9TEHnt71bPOJ 2A8AoKp6Y73R2YLRPJ699edbJWRPzplv =bVJl -END PGP SIGNATURE- ___ Zope-CMF maillist - Zope-CMF@lists.zope.org http://mail.zope.org/mailman/listinfo/zope-cmf See https://bugs.launchpad.net/zope-cmf/ for bug reports and feature requests
Re: [Zope-CMF] IMember: does it exist?
Rob Miller <[EMAIL PROTECTED]> writes: > then CMF does it's normal wrapping of these user objects using the standard > MemberData implementation. Hmm, right, so then this might still be on-topic here ;-) Maybe the right thing is for CMF to do a directlyProvides() call in wrapUser? - PW ___ Zope-CMF maillist - Zope-CMF@lists.zope.org http://mail.zope.org/mailman/listinfo/zope-cmf See https://bugs.launchpad.net/zope-cmf/ for bug reports and feature requests
Re: [Zope-CMF] IMember: does it exist?
Paul Winkler wrote: > Jens Vagelpohl <[EMAIL PROTECTED]> writes: >> I'd say that's a typo. The referenced IMember probably means the >> IMemberData interface, which does exist. > > Sounds good. Existing member implementations might have to be updated to > declare > themselves implementing that interface. For example, remember does not, > although > it does provide the required setProperties method. this is off-topic for this list, so we can discuss this off-list if you want to go any deeper, paul, but strictly speaking i don't think remember's Member class needs to implement IMemberData. the Member class is content, and PAS plug-ins use that content to generate and provide properties for user objects. then CMF does it's normal wrapping of these user objects using the standard MemberData implementation. -r ___ Zope-CMF maillist - Zope-CMF@lists.zope.org http://mail.zope.org/mailman/listinfo/zope-cmf See https://bugs.launchpad.net/zope-cmf/ for bug reports and feature requests
Re: [Zope-CMF] IMember: does it exist?
Jens Vagelpohl <[EMAIL PROTECTED]> writes: > I'd say that's a typo. The referenced IMember probably means the > IMemberData interface, which does exist. Sounds good. Existing member implementations might have to be updated to declare themselves implementing that interface. For example, remember does not, although it does provide the required setProperties method. ___ Zope-CMF maillist - Zope-CMF@lists.zope.org http://mail.zope.org/mailman/listinfo/zope-cmf See https://bugs.launchpad.net/zope-cmf/ for bug reports and feature requests
Re: [Zope-CMF] IMember: does it exist?
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Oct 2, 2008, at 20:32 , Paul Winkler wrote: > But there does not seem to be any such interface as IMember. > I've grepped everywhere I can think of. > > There probably should be :) I'd say that's a typo. The referenced IMember probably means the IMemberData interface, which does exist. If no one complains I'll change it over the next few days. jens -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.8 (Darwin) iEYEARECAAYFAkjlGnoACgkQRAx5nvEhZLIP2QCdHGTywTw3JResbScmc+yHu+3x 2ycAn3u2I09zBcH7v9nGom0KvscI1LI3 =dwXE -END PGP SIGNATURE- ___ Zope-CMF maillist - Zope-CMF@lists.zope.org http://mail.zope.org/mailman/listinfo/zope-cmf See https://bugs.launchpad.net/zope-cmf/ for bug reports and feature requests
[Zope-CMF] IMember: does it exist?
In CMFCore/interfaces/_tools.py I found several references to an IMember interface: class IMemberDataTool(Interface): ... def wrapUser(user): """Returns an IMember corresponding to the given user object. ... """ ... class IMembershipTool(Interface): ... def getMemberById(id): """ Returns the given IMember. ... """ ... def listMembers(): """ Return a sequence of all IMembers. ... """ ... But there does not seem to be any such interface as IMember. I've grepped everywhere I can think of. There probably should be :) - PW ___ Zope-CMF maillist - Zope-CMF@lists.zope.org http://mail.zope.org/mailman/listinfo/zope-cmf See https://bugs.launchpad.net/zope-cmf/ for bug reports and feature requests