
    #Yh                    .   d dl mZ d dlZd dlZd dlZd dlmZmZ ej        dk    rd dlm	Z
 nd dlm	Z
 erej        dk    rd dlmZ nd dlmZ g dZ G d	 d
e          Zd$dZddeddd%dZ	dedddd&dZe
Z	  G d  d!          Z e            ad'd#ZdS )(    )annotationsN)TYPE_CHECKINGLiteral)      )
deprecated)r      )LiteralString)AltairDeprecationWarningr   deprecated_static_onlydeprecated_warnc                      e Zd ZdS )r   N)__name__
__module____qualname__     `D:\DownLoads\facial_attendance_system-main\venv311\Lib\site-packages\altair/utils/deprecation.pyr   r      s          r   r   versionr
   alternativeLiteralString | Nonemessagereturnc               8    d|  d}|r| d| d}|r| d| n|S )Nz
Deprecated since `altair=z`.z Use z	 instead.
r   )r   r   r   outputs       r   _format_messager      sP     77666F 877777%,8f!!!!!&8r      )r   r   category
stacklevelr   %type[AltairDeprecationWarning] | Noner    intc                H    t          | ||          }t          |||          S )a  
    Indicate that a class, function or overload is deprecated.

    When this decorator is applied to an object, the type checker
    will generate a diagnostic on usage of the deprecated object.

    Parameters
    ----------
    version
        ``altair`` version the deprecation first appeared.
    alternative
        Suggested replacement class/method/function.
    message
        Additional message appended to ``version``, ``alternative``.
    category
        If the *category* is ``None``, no warning is emitted at runtime.
    stacklevel
        The *stacklevel* determines where the
        warning is emitted. If it is ``1`` (the default), the warning
        is emitted at the direct caller of the deprecated object; if it
        is higher, it is emitted further up the stack.
        Static type checker behavior is not affected by the *category*
        and *stacklevel* arguments.

    References
    ----------
    [PEP 702](https://peps.python.org/pep-0702/)
    r   r    )r   _deprecated)r   r   r   r   r    msgs         r   r   r   -   s+    H ';
8
8CsX*EEEEr      )r   r   r    actiontype[AltairDeprecationWarning]r(   Literal['once'] | NoneNonec                   t          |||           }|t          j        |||           dS |dk    rt          |||           dS t	          |          )ar  
    Indicate that the current code path is deprecated.

    This should be used for non-trivial cases *only*. ``@deprecated`` should
    always be preferred as it is recognized by static type checkers.

    Parameters
    ----------
    message
        Explanation of the deprecated behaviour.

        .. note::
            Unlike ``@deprecated``, this is *not* optional.

    version
        ``altair`` version the deprecation first appeared.
    alternative
        Suggested replacement argument/method/function.
    category
        The runtime warning type emitted.
    stacklevel
        How far up the call stack to make this warning appear.
        A value of ``2`` attributes the warning to the caller
        of the code calling ``deprecated_warn()``.

    References
    ----------
    [warnings.warn](https://docs.python.org/3/library/warnings.html#warnings.warn)
    Nr$   once)r   warningswarn
_warn_onceNotImplementedError)r   r   r   r   r    r(   r&   s          r   r   r   U   sl    L ';
8
8C~cHDDDDDD	6		3jAAAAAA!&)))r   c                  .    e Zd ZddZddZddZdd	Zd
S )_WarningsMonitorr   r+   c                D    i | _         t          j                    | _        d S N)_warned	threadingLock_lockselfs    r   __init__z_WarningsMonitor.__init__   s    ;=^%%


r   keyr
   boolc               V    | j         5  || j        v cd d d            S # 1 swxY w Y   d S r5   r9   r6   r;   r=   s     r   __contains__z_WarningsMonitor.__contains__   sx    Z 	' 	'$,&	' 	' 	' 	' 	' 	' 	' 	' 	' 	' 	' 	' 	' 	' 	' 	' 	' 	's   	""c               Z    | j         5  d| j        |<   d d d            d S # 1 swxY w Y   d S )NTr@   rA   s     r   hitz_WarningsMonitor.hit   sz    Z 	% 	% $DL	% 	% 	% 	% 	% 	% 	% 	% 	% 	% 	% 	% 	% 	% 	% 	% 	% 	%s    $$c                x    | j         5  | j                                         d d d            d S # 1 swxY w Y   d S r5   )r9   r6   clearr:   s    r   rF   z_WarningsMonitor.clear   s    Z 	! 	!L   	! 	! 	! 	! 	! 	! 	! 	! 	! 	! 	! 	! 	! 	! 	! 	! 	! 	!s   /33N)r   r+   )r=   r
   r   r>   )r=   r
   r   r+   )r   r   r   r<   rB   rD   rF   r   r   r   r3   r3      sd        & & & &' ' ' '% % % %! ! ! ! ! !r   r3   r&   c                  | t           v rd S t                               |            t          j        | ||dz              d S )Nr   r$   )_warnings_monitorrD   r.   r/   )r&   r   r    s      r   r0   r0      sJ     c"""cHaHHHHHHr   )r   r
   r   r   r   r   r   r
   )
r   r
   r   r   r   r   r   r!   r    r"   )r   r
   r   r
   r   r   r   r)   r    r"   r(   r*   r   r+   )r&   r
   r   r)   r    r"   r   r+   )
__future__r   sysr7   r.   typingr   r   version_infor   r%   typing_extensionsr
   __all__DeprecationWarningr   r   r   r   r3   rH   r0   r   r   r   <module>rP      s   " " " " " " 



      ) ) ) ) ) ) ) )w2222222;;;;;;  4
7""(((((((333333   8 7 7 7 71 7 7 7	9 	9 	9 	9" )-$(6N%F %F %F %F %F %FX )-/G%),* ,* ,* ,* ,* ,*^ % D! ! ! ! ! ! ! !$ %$&& I I I I I Ir   