a
    Ò�éic  ã                	   @   sB  d Z ddlmZ ddlmZ ddlmZ G dd„ deƒZg d¢Zz*ddlm	Z
 G d	d
„ d
e
ƒZ	e d
¡ W n ey|   Y n0 z*ddlmZ G dd„ deƒZe d¡ W n eyº   Y n0 z*ddlmZ G dd„ deƒZe d¡ W n eyø   Y n0 z*ddlmZ G dd„ deƒZe d¡ W n eef�y<   Y n0 dS )aN  
pyee supplies a `EventEmitter` class that is similar to the
`EventEmitter` class from Node.js. In addition, it supplies the subclasses
`AsyncIOEventEmitter`, `TwistedEventEmitter` and `ExecutorEventEmitter`
for supporting async and threaded execution with asyncio, twisted, and
concurrent.futures Executors respectively, as supported by the environment.

# Example

```text
In [1]: from pyee.base import EventEmitter

In [2]: ee = EventEmitter()

In [3]: @ee.on('event')
   ...: def event_handler():
   ...:     print('BANG BANG')
   ...:

In [4]: ee.emit('event')
BANG BANG

In [5]:
```

é    )Úwarn)ÚEventEmitter)ÚPyeeExceptionc                       s    e Zd ZdZ‡ fdd„Z‡  ZS )ÚBaseEventEmitterzG
    BaseEventEmitter is deprecated and an alias for EventEmitter.
    c                    s   t tdƒƒ tt| ƒ ¡  d S )Nz|pyee.BaseEventEmitter is deprecated and will be removed in a future major version; you should instead use pyee.EventEmitter.)r   ÚDeprecationWarningÚsuperr   Ú__init__©Úself©Ú	__class__© ú=/home/Claro/venv/lib/python3.9/site-packages/pyee/__init__.pyr   )   s    ÿÿzBaseEventEmitter.__init__©Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   Ú__classcell__r   r   r   r   r   $   s   r   )r   r   r   )ÚAsyncIOEventEmitterc                       s"   e Zd ZdZd‡ fdd„	Z‡  ZS )r   zP
        AsyncIOEventEmitter has been moved to the pyee.asyncio module.
        Nc                    s"   t tdƒƒ tt| ƒj|d� d S )NzCpyee.AsyncIOEventEmitter has been moved to the pyee.asyncio module.)Úloop)r   r   r   r   r   )r
   r   r   r   r   r   >   s    ÿÿzAsyncIOEventEmitter.__init__)Nr   r   r   r   r   r   9   s   r   )ÚTwistedEventEmitterc                       s    e Zd ZdZ‡ fdd„Z‡  ZS )r   zP
        TwistedEventEmitter has been moved to the pyee.twisted module.
        c                    s   t tdƒƒ tt| ƒ ¡  d S )NzCpyee.TwistedEventEmitter has been moved to the pyee.twisted module.)r   r   r   r   r   r	   r   r   r   r   S   s    ÿÿzTwistedEventEmitter.__init__r   r   r   r   r   r   N   s   r   )ÚExecutorEventEmitterc                       s"   e Zd ZdZd‡ fdd„	Z‡  ZS )r   zR
        ExecutorEventEmitter has been moved to the pyee.executor module.
        Nc                    s"   t tdƒƒ tt| ƒj|d� d S )NzEpyee.ExecutorEventEmitter has been moved to the pyee.executor module.)Úexecutor)r   r   r   r   r   )r
   r   r   r   r   r   h   s    ÿÿzExecutorEventEmitter.__init__)Nr   r   r   r   r   r   c   s   r   )ÚTrioEventEmitterc                       s"   e Zd ZdZd‡ fdd„	Z‡  ZS )r   zJ
        TrioEventEmitter has been moved to the pyee.trio module.
        Nc                    s$   t tdƒƒ tt| ƒj||d� d S )Nz=pyee.TrioEventEmitter has been moved to the pyee.trio module.)ÚnurseryÚmanager)r   r   r   r   r   )r
   r   r   r   r   r   r   }   s    ÿÿzTrioEventEmitter.__init__)NNr   r   r   r   r   r   x   s   r   N)r   Úwarningsr   Z	pyee.baser   r   r   Ú__all__Zpyee.asyncior   Z_AsyncIOEventEmitterÚappendÚImportErrorZpyee.twistedr   Z_TwistedEventEmitterZpyee.executorr   Z_ExecutorEventEmitterZ	pyee.trior   Z_TrioEventEmitterÚSyntaxErrorr   r   r   r   Ú<module>   s:   