
    z                     T    d dl Z d dlmZmZmZmZ  ed      ZdZ G d dee         Zy)    N)GenericTypeVarCallableOptional_ClientK   c                   v    e Zd ZU eg ef   Zeed<   ee   ed<   eed<   e	j                  ed<   defdZdefdZy	)
ClientCache_factory_latest_remaining_uses_lockfactoryc                 `    || _         d | _        d| _        t        j                         | _        y )Nr   )r   r   r   	threadingLockr   )selfr   s     Elib/third_party/google/cloud/pubsublite/internal/wire/client_cache.py__init__zClientCache.__init__   s&     ^^%
    returnc                     | j                   5  | j                  dk  r t        | _        | j                         | _        | xj                  dz  c_        | j                  cd d d        S # 1 sw Y   y xY w)Nr      )r   r   _MAX_CLIENT_USESr   r   )r   s    r   getzClientCache.get$   sN    ZZ##q('7$#}}  A% << ZZs   AA''A0N)__name__
__module____qualname__r   r   _ClientFactory__annotations__r   intr   r   r   r    r   r   r
   r
      sI    b'k*Ng>>& & W  r   r
   )	r   typingr   r   r   r   r   r   r
   r"   r   r   <module>r$      s1     7 7
)
  ''"  r   