o
    à;ïj¾	  ã                   @   sŒ   d Z dZG dd„ deƒZG dd„ deƒZG dd„ deƒZG dd	„ d	eƒZG d
d„ deƒZG dd„ deƒZG dd„ deƒZ	G dd„ deƒZ
dS )z'
Exception Classes for the xdg package
Fc                   @   s    e Zd ZdZdd„ Zdd„ ZdS )ÚErrorz'Base class for exceptions defined here.c                 C   s   || _ t | |¡ d S ©N)ÚmsgÚ	ExceptionÚ__init__)Úselfr   © r   úW/home/hd29/karthikselvaraju/venvs/deluge/lib/python3.10/site-packages/xdg/Exceptions.pyr   	   s   zError.__init__c                 C   s   | j S r   )r   )r   r   r   r   Ú__str__   s   zError.__str__N)Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   r	   r   r   r   r   r      s    r   c                   @   ó   e Zd ZdZdd„ ZdS )ÚValidationErrorzXRaised when a file fails to validate.
    
    The filename is the .file attribute.
    c                 C   ó$   || _ || _t | d||f ¡ d S )Nz!ValidationError in file '%s': %s ©r   Úfiler   r   ©r   r   r   r   r   r   r      ó   zValidationError.__init__N©r
   r   r   r   r   r   r   r   r   r      ó    r   c                   @   r   )ÚParsingErrorzWRaised when a file cannot be parsed.
    
    The filename is the .file attribute.
    c                 C   r   )NzParsingError in file '%s', %sr   r   r   r   r   r      r   zParsingError.__init__Nr   r   r   r   r   r      r   r   c                   @   r   )Ú
NoKeyErrorzyRaised when trying to access a nonexistant key in an INI-style file.
    
    Attributes are .key, .group and .file.
    c                 C   ó,   t  | d|||f ¡ || _|| _|| _d S )Nz"No key '%s' in group %s of file %s©r   r   ÚkeyÚgroupr   ©r   r   r   r   r   r   r   r   (   ó   
zNoKeyError.__init__Nr   r   r   r   r   r   #   r   r   c                   @   r   )ÚDuplicateKeyErrorzpRaised when the same key occurs twice in an INI-style file.
    
    Attributes are .key, .group and .file.
    c                 C   r   )Nz)Duplicate key '%s' in group %s of file %sr   r   r   r   r   r   3   r   zDuplicateKeyError.__init__Nr   r   r   r   r   r   .   r   r   c                   @   r   )ÚNoGroupErrorzuRaised when trying to access a nonexistant group in an INI-style file.
    
    Attributes are .group and .file.
    c                 C   ó$   t  | d||f ¡ || _|| _d S )NzNo group: %s in file %s©r   r   r   r   ©r   r   r   r   r   r   r   >   ó   
zNoGroupError.__init__Nr   r   r   r   r   r    9   r   r    c                   @   r   )ÚDuplicateGroupErrorzjRaised when the same key occurs twice in an INI-style file.
    
    Attributes are .group and .file.
    c                 C   r!   )NzDuplicate group: %s in file %sr"   r#   r   r   r   r   H   r$   zDuplicateGroupError.__init__Nr   r   r   r   r   r%   C   r   r%   c                   @   r   )ÚNoThemeErrorzsRaised when trying to access a nonexistant icon theme.
    
    The name of the theme is the .theme attribute.
    c                 C   s   t  | d| ¡ || _d S )NzNo such icon-theme: %s)r   r   Útheme)r   r'   r   r   r   r   R   s   
zNoThemeError.__init__Nr   r   r   r   r   r&   M   r   r&   N)r   Údebugr   r   r   r   r   r   r    r%   r&   r   r   r   r   Ú<module>   s    



