a
    ¨ˆcÆ  ã                   @   s4   G d d„ de ƒZG dd„ de ƒZG dd„ de ƒZdS )c                   @   s    e Zd ZdZdd„ Zdd„ ZdS )ÚProviderNotRegisteredErrorz: Raised when a provider is requested by ID and not found. c                 C   s
   || _ d S ©N©Úprovider_id©Úselfr   © r   ú\/home/yuhw/wc/wire-cell-python/wcpy/lib/python3.9/site-packages/apptools/selection/errors.pyÚ__init__   s    z#ProviderNotRegisteredError.__init__c                 C   s   d}|j | jd�S )Nz,Selection provider with ID '{id}' not found.©Úid©Úformatr   ©r   Úmsgr   r   r   Ú__str__   s    z"ProviderNotRegisteredError.__str__N©Ú__name__Ú
__module__Ú__qualname__Ú__doc__r	   r   r   r   r   r   r      s   r   c                   @   s    e Zd ZdZdd„ Zdd„ ZdS )ÚIDConflictErrorzC Raised when a provider is added and its ID is already registered. c                 C   s
   || _ d S r   r   r   r   r   r   r	      s    zIDConflictError.__init__c                 C   s   d}|j | jd�S )Nz:A selection provider with ID '{id}' is already registered.r
   r   r   r   r   r   r      s    zIDConflictError.__str__Nr   r   r   r   r   r      s   r   c                   @   s    e Zd ZdZdd„ Zdd„ ZdS )ÚListenerNotConnectedErrorzB Raised when a listener that was never connected is disconnected. c                 C   s   || _ || _d S r   )r   Úlistener)r   r   r   r   r   r   r	   %   s    z"ListenerNotConnectedError.__init__c                 C   s   d}|j | j| jd�S )Nz<Selection listener {lr} is not connected to provider '{id}'.)Úlrr   )r   r   r   r   r   r   r   r   )   s    z!ListenerNotConnectedError.__str__Nr   r   r   r   r   r   "   s   r   N)Ú	Exceptionr   r   r   r   r   r   r   Ú<module>   s   