%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /proc/self/root/opt/alt/python27/lib/python2.7/site-packages/mako/ext/
Upload File :
Create Path :
Current File : //proc/self/root/opt/alt/python27/lib/python2.7/site-packages/mako/ext/beaker_cache.pyc

�
�ǚPc@sFdZddlmZddlmZdadefd��YZdS(s<Provide a :class:`.CacheImpl` for the Beaker caching system.i����(t
exceptions(t	CacheImpltBeakerCacheImplcBsDeZdZd�Zd�Zd�Zd�Zd�Zd�ZRS(sA :class:`.CacheImpl` provided for the Beaker caching system.
    
    This plugin is used by default, based on the default
    value of ``'beaker'`` for the ``cache_impl`` parameter of the
    :class:`.Template` or :class:`.TemplateLookup` classes.
    
    cCs�tdkryyddlm}Wn"tk
rD}tjd��nXd|jjkrj|jjdaqy|j	�ant
t|�j|�dS(Ni����(tcaches:the Beaker package is required to use cache functionality.tmanager(
t
_beaker_cachetNonetbeakerRtImportErrorRtRuntimeExceptionttemplatet
cache_argstCacheManagertsuperRt__init__(tselfRtbeaker_cachete((sF/opt/alt/python27/lib/python2.7/site-packages/mako/ext/beaker_cache.pyRs
cKs|jdd�}d|kr4|jd�|d<n%|jjjrY|jjj|d<nd|kru|jd�n|jd�dkr�d|d<nd|kr�|jd�}tj|jj||�}ntj	|jj|�}i|jj
d	6}|r||d
<n||fS(Nttimeouttdirtdata_dirRttypet	memcacheds
ext:memcachedtregiont	starttimet
expiretime(tpopRRR
tmodule_directorytgetRtget_cache_regiontidt	get_cacheR(RtkwRRRR((sF/opt/alt/python27/lib/python2.7/site-packages/mako/ext/beaker_cache.pyt
_get_cache!s"

cKs+|j|�\}}|j|d||�S(Nt
createfunc(R!R(Rtkeytcreation_functionR R((sF/opt/alt/python27/lib/python2.7/site-packages/mako/ext/beaker_cache.pyt
get_or_create8scKs,|j|�\}}|j|||�dS(N(R!tput(RR#tvalueR R((sF/opt/alt/python27/lib/python2.7/site-packages/mako/ext/beaker_cache.pyR&<scKs%|j|�\}}|j||�S(N(R!R(RR#R R((sF/opt/alt/python27/lib/python2.7/site-packages/mako/ext/beaker_cache.pyR@scKs)|j|�\}}|j||�dS(N(R!tremove_value(RR#R R((sF/opt/alt/python27/lib/python2.7/site-packages/mako/ext/beaker_cache.pyt
invalidateDs(	t__name__t
__module__t__doc__RR!R%R&RR)(((sF/opt/alt/python27/lib/python2.7/site-packages/mako/ext/beaker_cache.pyRs					N(R,tmakoRt
mako.cacheRRRR(((sF/opt/alt/python27/lib/python2.7/site-packages/mako/ext/beaker_cache.pyt<module>s

Zerion Mini Shell 1.0