AW: [Zope3-dev] Propose interface change (well not really)

Jim Fulton jim at zope.com
Thu Jul 8 18:38:10 EDT 2004


Stephan Richter wrote:
> On Thursday 08 July 2004 17:27, Roger ineichen wrote:
> 
>>Why does the IPrincipalSource not inherit from IContained?
> 
> 
> It was just not done yet. Just do it.

Well, because it has nothing to do with being contained.

But, given that IPluggableAuthService extends IContainer,
I see no harm in having IPrincipalSource extend IContained.

BTW,  IContainerPrincipalSource has a silly name and doc string.
Fortunately, this change will make it go away. :)

> 
>>Is it possible to have IPrincipalSource outside a
>>IPluggableAuthenticationService, because we don't have a
> 
> 
> No.
> 
> 
>>ContainerTypesConstraint for IPluggableAuthenticationService
>>like:
>>    __parent__= Field(
>>        constraint =
>>ContainerTypesConstraint(IPluggableAuthenticationService))

> Add it. This code is much older than the constraint code.

No, this code was added to work with the constraint code.
Maybe for X3.1, we can improve the spelling.

> 
>>And why we don't have read methods of the container in this interface?
>>Or at least the methods __len__(), keys(), values()
> 
> 
> Don't we use IContainer as a base class for IPrincipalSource? If not, you can 
> do this as well.

Are we talking about IPrincipalSource or IPluggableAuthenticationService?
IPluggableAuthenticationService extends ICOntainer already.

IPrincipalSource should not extend IContainer because principal
sources need not be containers.

> 
>>This way we can't get the size of the source or useable infos out
>>of the principal source. Just authenticate.

Roger, I'm confused. Are you talking about the principal source?
Or the auth service?

Jim

-- 
Jim Fulton           mailto:jim at zope.com       Python Powered!
CTO                  (540) 361-1714            http://www.python.org
Zope Corporation     http://www.zope.com       http://www.zope.org


More information about the Zope3-dev mailing list