AlkantarClanX12
Current Path : /usr/lib64/python3.8/__pycache__/ |
Current File : //usr/lib64/python3.8/__pycache__/nturl2path.cpython-38.opt-2.pyc |
U e5dG � @ s d d� Z dd� ZdS )c C s� dd l }dd l}| �dd�} d| kr\| d d� dkr@| dd � } | �d�}|j�d�|��S | �d�}t|�dks�|d d |jkr�d | }t |��|d d � � }|d �d�}|d }|D ]}|r�|d |j�|� }q�|�d�r�| �d�r�|d7 }|S )N� �:�|� z////� �/�\���z Bad URL: � )�string�urllib.parse�replace�split�parseZunquote�join�lenZ ascii_letters�OSError�upper�endswith)Zurlr �urllib� components�comp�error�drive�path� r �"/usr/lib64/python3.8/nturl2path.py�url2pathname s( r c C s4 dd l }| d d� dkrf| dd � } | d d� �� dkrJd| dd � } n| dd� dkrftd | ��d| kr�| d d� d kr�d | } | �d�}|j�d�|��S | jddd�}t|�dks�t|d �dkr�d | }t|��|j�|d �� �}|d �d�}d | d }|D ] }|�r|d |j�|� }�q|S )Nr r z\\?\zUNC\r r r r z Bad path: z\\r )�maxsplitz///)r r r r r Zquoter r )�pr r r r r r r r r �pathname2url- s. r N)r r r r r r �<module> s %