Ë
     ƒh  ã                   óN   — d Z ddlZddlZddlmZ  G d„ dej
                  «      Zy)z"Classes related to cdrom handling.é    N)ÚCdromProgressc            	       ó‚   — e Zd ZdZ	 	 	 ddedz  dedz  deddfd„Zddedz  defd„Zddedz  defd	„Z	e
defd
„«       Zy)ÚCdroma;  Support for apt-cdrom like features.

    This class has several optional parameters for initialisation, which may
    be used to influence the behaviour of the object:

    The optional parameter `progress` is a CdromProgress() subclass, which will
    ask for the correct cdrom, etc. If not specified or None, a CdromProgress()
    object will be used.

    The optional parameter `mountpoint` may be used to specify an alternative
    mountpoint.

    If the optional parameter `nomount` is True, the cdroms will not be
    mounted. This is the default behaviour.
    NÚprogressÚ
mountpointÚnomountÚreturnc                 ó>  — t         j                  j                  | «       |€t        «       | _        n|| _        |� t         j
                  j                  d|«       |r!t         j
                  j                  dd«       y t         j
                  j                  dd«       y )NzAcquire::cdrom::mountzAPT::CDROM::NoMountÚtrueÚfalse)Úapt_pkgr   Ú__init__r   Ú	_progressÚconfigÚset)Úselfr   r   r   s       ú+/usr/lib/python3/dist-packages/apt/cdrom.pyr   zCdrom.__init__/   st   € ô 	�‰×Ñ˜tÔ$ØÐÜ*›_ˆD�Nà%ˆDŒNàÐ!Ü�N‰N×ÑÐ6¸
ÔCáÜ�N‰N×ÑÐ4°fÕ=ä�N‰N×ÑÐ4°gÕ>ó    c                 ó^   — t         j                  j                  | |xs | j                  «      S )zAdd cdrom to the sources.list.)r   r   Úaddr   ©r   r   s     r   r   z	Cdrom.addC   s"   € ä�}‰}× Ñ   xÒ'A°4·>±>ÓBÐBr   c                 ó^   — t         j                  j                  | |xs | j                  «      S )zIdentify the cdrom.)r   r   Úidentr   r   s     r   r   zCdrom.identG   s"   € ä�}‰}×"Ñ" 4¨Ò)C°T·^±^ÓDÐDr   c                 ó¬  — | j                  «       }|€yt        j                  t        j                  j	                  d«      dz   «      }|j                  t        j                  j                  d«      «       |D ]M  }t        |«      5 }|D ]1  }|j                  «       j                  d«      rŒ#||v sŒ( ddd«        y 	 ddd«       ŒO y# 1 sw Y   ŒZxY w)z:Check if the cdrom is already in the current sources.list.NFzDir::Etc::sourcepartsÚ*zDir::Etc::sourcelistú#T)
r   Úglobr   r   Úfind_dirÚappendÚ	find_fileÚopenÚlstripÚ
startswith)r   Úcd_idÚsrcÚfnameÚfobjÚlines         r   Úin_sources_listzCdrom.in_sources_listK   sÃ   € ð —
‘
“ˆØˆ=àä�i‰iœŸ™×/Ñ/Ð0GÓHÈ3ÑNÓOˆØ�
‰
”7—>‘>×+Ñ+Ð,BÓCÔDàò 	$ˆEÜ�e“ð $ Ø ò $�DØŸ;™;›=×3Ñ3°CÕ8¸UÀdº]Ø#÷$ñ $ñ$÷$ð $ð	$ð
 ÷	$ð $ús   Â%C
Â-C
Â2C
Â=C
Ã
C	)NNT)N)Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   ÚstrÚboolr   r   r   Úpropertyr)   © r   r   r   r      s—   „ ñð$ *.Ø!%Øñ	?à $Ñ&ð?ð ˜$‘Jð?ð ð	?ð
 
ó?ñ(C˜M¨DÑ0ð C¸Dó CñE˜m¨dÑ2ð E¸có Eð ð ò ó ñr   r   )r-   r   r   Úapt.progress.baser   r   r1   r   r   ú<module>r3      s#   ðñ, )Û ã å +ô=ˆG�M‰Mõ =r   