language – User Language Components Module¶
Handle language as requested by users.
-
class
waeup.kofa.language.
KofaLanguage
(context)[source]¶ Bases:
grokcore.component.components.Adapter
Set preferred languages
-
__doc__
= 'Set preferred languages'¶
-
__implemented__
= <implementedBy waeup.kofa.language.KofaLanguage>¶
-
__module__
= 'waeup.kofa.language'¶
-
__provides__
¶ Special descriptor for class __provides__
The descriptor caches the implementedBy info, so that we can get declarations for objects without instance-specific interfaces a bit quicker.
For example:
>>> from zope.interface import Interface >>> class IFooFactory(Interface): ... pass >>> class IFoo(Interface): ... pass >>> class C(object): ... implements(IFoo) ... classProvides(IFooFactory) >>> [i.getName() for i in C.__provides__] ['IFooFactory']
>>> [i.getName() for i in C().__provides__] ['IFoo']
-