ok

Mini Shell

Direktori : /lib/python3.6/site-packages/zope/component/__pycache__/
Upload File :
Current File : //lib/python3.6/site-packages/zope/component/__pycache__/globalregistry.cpython-36.pyc

3

,�W�
�@s�dZddlmZddlmZddlmZddlmZddl	m
Z
dd�ZGd	d
�d
e�Zee�Gdd�de��Z
e
d
�ZyddlmZWnek
r�YnXedd��[eZdd�Zde
fdd�Zdde
fdd�Zddd�Zddd�ZdS)zGlobal components support
�)�implementer)�AdapterRegistry)�
Components)�IComponentLookup)�_BLANKcCs
t||�S)N)�getattr)Z
componentsZregistryName�r�$/usr/lib/python3.6/globalregistry.py�GARsr
cs(eZdZdZ�fdd�Zdd�Z�ZS)�GlobalAdapterRegistryz~A global adapter registry

    This adapter registry's main purpose is to be picklable in combination
    with a site manager.cs||_||_tt|�j�dS)N)�
__parent__�__name__�superr�__init__)�self�parent�name)�	__class__rr	r szGlobalAdapterRegistry.__init__cCst|j|jffS)N)r
rr
)rrrr	�
__reduce__%sz GlobalAdapterRegistry.__reduce__)r
�
__module__�__qualname__�__doc__rr�
__classcell__rr)rr	rsrc@seZdZdd�Zdd�ZdS)�BaseGlobalComponentscCst|d�|_t|d�|_dS)N�adapters�	utilities)rrr)rrrr	�_init_registries+sz%BaseGlobalComponents._init_registriescCs|jS)N)r
)rrrr	r/szBaseGlobalComponents.__reduce__N)r
rrrrrrrr	r(sr�base)�
addCleanUpcCs
tjd�S)Nr)rrrrrr	�<lambda>:srcCstS)N)�globalSiteManagerrrrr	�getGlobalSiteManager>sr!NcCstj|||dd�dS)NF)�event)rZregisterUtility)Z	component�providesrrrr	�provideUtilityEsr$cCstj||||dd�dS)NF)r")rZregisterAdapter)�factory�adaptsr#rrrr	�provideAdapterHsr'cCstj|||dd�dS)NF)r")rZregisterSubscriptionAdapter)r%r&r#rrr	�provideSubscriptionAdapterKsr(cCstj||dd�dS)NF)r")rZregisterHandler)r%r&rrr	�provideHandlerNsr))NN)N)rZzope.interfacerZzope.interface.adapterrZzope.interface.registryrZzope.component.interfacesrZzope.component._compatrr
rrrZzope.testing.cleanupr�ImportErrorr r!r$r'r(r)rrrr	�<module>s,



Zerion Mini Shell 1.0