[Zope3-Users] Interface confusion (still)

Tim Cook timothywayne.cook at gmail.com
Tue Jul 15 14:53:29 EDT 2008


If interface B inherits from interface A and class B implements
interface B; do I need to explicitly state that class B provides
interface A?

Concrete example:

class IElement(Interface):
     value = Object(
        schema=IDataValue,
        title=_(u"value"),
        description=_(u"""Data value of this leaf."""),
        required=False
    )

class IDvText(IDataValue):

...


class DvText(DataValue):

....

implements(IDvText)
classProvides(IDvText)


Will Element.value allow instances of DvText or do I need to change the
DvText classProvides call to:

classProvides(IDataValue,IDvText)

Thanks,
Tim





-- 
Timothy Cook, MSc
Health Informatics Research & Development Services
LinkedIn Profile:http://www.linkedin.com/in/timothywaynecook 
Skype ID == timothy.cook 
**************************************************************
*You may get my Public GPG key from  popular keyservers or   *
*from this link http://timothywayne.cook.googlepages.com/home*
**************************************************************
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://mail.zope.org/pipermail/zope3-users/attachments/20080715/4adbe9ec/attachment.bin


More information about the Zope3-users mailing list