HEX
Server: LiteSpeed
System: Linux us-phx-web1284.main-hosting.eu 4.18.0-553.109.1.lve.el8.x86_64 #1 SMP Thu Mar 5 20:23:46 UTC 2026 x86_64
User: u300739242 (300739242)
PHP: 8.2.30
Disabled: system, shell_exec, passthru, mysql_list_dbs, ini_alter, dl, symlink, link, chgrp, leak, popen, apache_child_terminate, virtual, mb_send_mail
Upload Files
File: //opt/alt/python37/lib/python3.7/site-packages/jsons/__pycache__/_cache.cpython-37.pyc
B

�P�e��@sTdZddlmZddlmZmZddlmZGdd�d�Zed�dd	�Z	d
d�Z
dS)
zn
PRIVATE MODULE: do not import (from) it directly.

This module contains functionality for caching functions.
�)�deque)�	lru_cache�update_wrapper)�Callablec@s2eZdZdZeg�Zdd�Zedd�dd��ZdS)	�_Wrapperz�
    A wrapper around a function that needs to be cached. This wrapper allows
    for a single point from which cache can be cleared.
    cCs||_|j�|�dS)N)�wrapped�	instances�append)�selfr�r�=/opt/alt/python37/lib/python3.7/site-packages/jsons/_cache.py�__init__sz_Wrapper.__init__T)�typedcOs|j||�S)N)r)r
�args�kwargsrrr�__call__sz_Wrapper.__call__N)	�__name__�
__module__�__qualname__�__doc__rrr
rrrrrrrsr)�	decoratedcCst|�}t||d�|S)z�
    Alternative for ``functools.lru_cache``. By decorating a function with
    ``cached``, you can clear the cache of that function by calling
    ``clear()``.
    :param decorated: the decorated function.
    :return: a wrapped function.
    )�wrapperr)rr)rrrrr�cachedsrcCsxtjD]}|j��qWdS)z\
    Clear all cache of functions that were cached using ``cached``.
    :return: None.
    N)rrr�cache_clear)�wrrr�clear(srN)r�collectionsr�	functoolsrr�typingrrrrrrrr�<module>s