£Á°èZ¨Ä…–K§‚«“ô4“ÒÙ´dîfUÙÃÅ WKbyÊ¦•êŽ…È®FÒ¿ÊÎóCozá¬S@6{Í:›œêZÌ:Š•_%:¢¾¾~;‘Ã~èŠ©ÊÇí`ÔÑ©úë™µ'5I¿fš×WO%ø9¾«¾DK|€ùÍD”Ýs]nHÕ¶ê×Ó¼ãžªéUWŸÈË%DÒÕ¬ï‘]/Åcx  ‰ï2ß]ä6G[]S£ÔÏ¯rs{úëóµmÒï#UQxo·õÞCe]"±/aÙ&Eã4ú9Jé_ÞåëdãöKë)AÞ                  ¯¹ægƒÛowÐø^d™ý½ßB7áyMä9ÜÖUã
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
<html>
3
dW                 @   sh   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dS )zCommon DNS Exceptions.c                   sR   e Zd ZdZdZe ZdZ fddZdd Z	dd Z
d	d
 Z fddZ  ZS )DNSExceptiona  Abstract base class shared by all dnspython exceptions.

    It supports two basic modes of operation:

    a) Old/compatible mode is used if __init__ was called with
    empty **kwargs.
    In compatible mode all *args are passed to standard Python Exception class
    as before and all *args are printed by standard __str__ implementation.
    Class variable msg (or doc string if msg is None) is returned from str()
    if *args is empty.

    b) New/parametrized mode is used if __init__ was called with
    non-empty **kwargs.
    In the new mode *args has to be empty and all kwargs has to exactly match
    set in class variable self.supp_kwargs. All kwargs are stored inside
    self.kwargs and used in new __str__ implementation to construct
    formatted message based on self.fmt string.

    In the simplest case it is enough to override supp_kwargs and fmt
    class variables to get nice parametrized messages.
    Nc                sp   | j || |r*| jf || _t| | _nt | _| jd krD| j| _|rZtt| j	|  ntt| j	| j d S )N)
_check_params_check_kwargskwargsstrmsgdict__doc__superr   __init__)selfargsr   )	__class__ /usr/lib/python3.6/exception.pyr
   .   s    
zDNSException.__init__c             O   s   |s|rdS )zsOld exceptions supported only args and not kwargs.

        For sanity we do not allow to mix old and new behavior.Nr   )r   r   r   r   r   r   r   =   s    zDNSException._check_paramsc             K   s   |r|S )Nr   )r   r   r   r   r   r   E   s    zDNSException._check_kwargsc             K   sh   i }x^|j  D ]R\}}t|ttfrXttt|||< t|| dkr`|| j ||< q|||< qW |S )zFormat kwargs before printing them.

        Resulting dictionary has to have keys necessary for str.format call
        on fmt class variable.
           )items
isinstancelistsetmapr   lenpop)r   r   fmtargskwdatar   r   r   _fmt_kwargsL   s    zDNSException._fmt_kwargsc                s:   | j r(| jr(| jf | j }| jjf |S tt| j S d S )N)r   fmtr   formatr	   r   __str__)r   r   )r   r   r   r   ^   s    zDNSException.__str__)__name__
__module____qualname__r   r   r   supp_kwargsr   r
   r   r   r   r   __classcell__r   r   )r   r   r      s   r   c               @   s   e Zd ZdZdS )	FormErrorzDNS message is malformed.N)r   r    r!   r   r   r   r   r   r$   h   s   r$   c               @   s   e Zd ZdZdS )SyntaxErrorzText input is malformed.N)r   r    r!   r   r   r   r   r   r%   m   s   r%   c               @   s   e Zd ZdZdS )UnexpectedEndzText input ended unexpectedly.N)r   r    r!   r   r   r   r   r   r&   r   s   r&   c               @   s   e Zd ZdZdS )TooBigzThe DNS message is too big.N)r   r    r!   r   r   r   r   r   r'   w   s   r'   c               @   s   e Zd ZdZedgZdZdS )TimeoutzThe DNS operation timed out.Ztimeoutz3The DNS operation timed out after {timeout} secondsN)r   r    r!   r   r   r"   r   r   r   r   r   r(   |   s   
r(   N)r   	Exceptionr   r$   r%   r&   r'   r(   r   r   r   r   <module>   s   U