AlkantarClanX12

Your IP : 18.118.140.78


Current Path : /opt/alt/python34/lib64/python3.4/__pycache__/
Upload File :
Current File : //opt/alt/python34/lib64/python3.4/__pycache__/ntpath.cpython-34.pyo

�
e f�O�&@sNdZddlZddlZddlZddlZddlTdddddd	d
ddd
ddddddddddddddddddd d!d"d#d$d%d&d'd(d)g&Zd*Zd+Zd*Zd,Z	d-Z
d.Zd/Zd0ej
kr�d1Znd2Zd3d4�Zd5d6�Zd7d8�Zd9d:�Zd;d<�Zd=d>�Zd?d@�ZdAd�ZdBd�ZdCd�ZdDd�ZdEd�ZdFd�ZdGd	�Zejje_dHd
�ZdId�ZdJd�Z dKd�Z!yddLl"m#Z#Wne$k
rdZ#YnXdMd�Z%dNd�Z&dOd�Z'dPd�Z(yddQl"m)Z)Wne$k
rzdRd�Z*Yn
XdSd�Z*e*Z+e,edT�o�ej-�dUdVkZ.edWd&�Z/y9ej-�ddV�d]kr�ddYl"m0Z0ne$�Wn$e1e$fk
r dZd[�Z0YnXydd\l"m2Z3Wne$k
rIYnXdS)^z�Common pathname manipulations, WindowsNT/95 version.

Instead of importing this module directly, import os and refer to this
module as os.path.
�N)�*�normcase�isabs�join�
splitdrive�split�splitext�basename�dirname�commonprefix�getsize�getmtime�getatime�getctime�islink�exists�lexists�isdir�isfile�ismount�
expanduser�
expandvars�normpath�abspath�splitunc�curdir�pardir�sep�pathsep�defpath�altsep�extsep�devnull�realpath�supports_unicode_filenames�relpath�samefile�sameopenfile�samestat�.z..�\�;�/z.;C:\binZcez\WindowsZnulcCst|t�rdSdSdS)N��)�
isinstance�bytes)�path�r2�+/opt/alt/python34/lib64/python3.4/ntpath.py�
_get_empty#sr4cCst|t�rdSdSdS)Ns\r*)r/r0)r1r2r2r3�_get_sep)sr5cCst|t�rdSdSdS)N�/r,)r/r0)r1r2r2r3�_get_altsep/sr7cCst|t�rdSdSdS)Ns\/z\/)r/r0)r1r2r2r3�
_get_bothseps5sr8cCst|t�rdSdSdS)N�.r))r/r0)r1r2r2r3�_get_dot;sr:cCst|t�rdSdSdS)N�:�:)r/r0)r1r2r2r3�
_get_colonAsr=cCst|t�rdSdSdS)N�\\.\�\\?\�\\.\�\\?\)r>r?)r@rA)r/r0)r1r2r2r3�_get_specialGsrBcCsUt|ttf�s3tdj|jj���n|jt|�t	|��j
�S)zaNormalize case of pathname.

    Makes all characters lowercase and all slashes into backslashes.z2normcase() argument must be str or bytes, not '{}')r/r0�str�	TypeError�format�	__class__�__name__�replacer7r5�lower)�sr2r2r3rQs	cCs<t|�d}t|�dko;|dd�t|�kS)zTest whether a path is absolute�rN)r�lenr8)rJr2r2r3rasc
GsIt|�}t|�}t|�}t|�\}}x�|D]�}t|�\}}	|	r�|	d|kr�|sx|r�|}n|	}q=nE|r�||kr�|j�|j�kr�|}|	}q=n|}n|r�|d|kr�||}n||	}q=W|rA|d|krA|rA|dd�|krA|||S||S)NrrK���rM)r5r8r=rrI)
r1�pathsr�sepsZcolonZresult_driveZresult_path�pZp_driveZp_pathr2r2r3rhs0

		
cCsJt|�}t|�dkr@t|�}|jt|�|�}|dd�|dkr|dd�|kr|j|d�}|dkr�||fS|j||d�}||dkr�||fS|dkr�t|�}n|d|�||d�fS|dd�t|�kr@|dd�|dd�fSn||fS)a�Split a pathname into drive/UNC sharepoint and relative path specifiers.
    Returns a 2-tuple (drive_or_unc, path); either part may be empty.

    If you assign
        result = splitdrive(p)
    It is always true that:
        result[0] + result[1] == p

    If the path contained a drive letter, drive_or_unc will contain everything
    up to and including the colon.  e.g. splitdrive("c:/dir") returns ("c:", "/dir")

    If the path contained a UNC path, the drive_or_unc will contain the host name
    and share up to but not including the fourth directory separator character.
    e.g. splitdrive("//host/computer/dir") returns ("//host/computer", "/dir")

    Paths cannot contain both a drive letter and a UNC path.

    rKr��NrMrM)r4rLr5rHr7�findr=)rP�emptyrZnormp�indexZindex2r2r2r3r�s"0

!cCsaddl}|jdtd�t|�\}}t|�dkrW|dd�|fS||fS)a�Deprecated since Python 3.1.  Please use splitdrive() instead;
    it now handles UNC paths.

    Split a pathname into UNC mount point and relative path specifiers.

    Return a 2-tuple (unc, rest); either part may be empty.
    If unc is not empty, it has the form '//host/mount' (or similar
    using backslashes).  unc+rest is always the input path.
    Paths containing drive letters never have an UNC part.
    rNz<ntpath.splitunc is deprecated, use ntpath.splitdrive insteadrQ)�warnings�warn�DeprecationWarningrrL)rPrV�driver1r2r2r3r�s	
cCs�t|�}t|�\}}t|�}x(|rT||d|krT|d8}q-W|d|�||d�}}|}x0|r�|dd�|kr�|dd�}qW|p�|}|||fS)z~Split a pathname.

    Return tuple (head, tail) where tail is everything after the final slash.
    Either part may be empty.rKNrMrM)r8rrL)rPrO�d�i�head�tailZhead2r2r2r3r�s!cCs(tj|t|�t|�t|��S)N)�genericpath�	_splitextr5r7r:)rPr2r2r3r�scCst|�dS)z)Returns the final component of a pathnamerK)r)rPr2r2r3r	�scCst|�dS)z-Returns the directory component of a pathnamer)r)rPr2r2r3r
�scCsBytj|�}Wnttfk
r1dSYnXtj|j�S)zhTest whether a path is a symbolic link.
    This will always return false for Windows prior to 6.0.
    F)�os�lstat�OSError�AttributeError�stat�S_ISLNK�st_mode)r1�str2r2r3rs
	cCs0ytj|�}Wntk
r+dSYnXdS)zCTest whether a path exists.  Returns True for broken symbolic linksFT)r`rarb)r1rgr2r2r3rs

	)�_getvolumepathnamecCs�t|�}t|�}t|�\}}|rQ|d|krQ|pP||kS||kradStr�|j|�t|�j|�kSdSdS)zaTest whether a path is a mount point (a drive root, the root of a
    share, or a mounted volume)rTFN)r8rrrh�rstrip)r1rO�root�restr2r2r3r$s"c
Csqt|t�rd}nd}|j|�s1|Sdt|�}}x0||krv||t|�krv|d7}qGWdtjkr�tjd}ntdtjkr�tjd}nUdtjkr�|Sytjd}Wntk
r�d}YnXt|tjd�}t|t�r1|j	t
j��}n|dkr_tt|�|d|��}n|||d	�S)
zLExpand ~ and ~user constructs.

    If user or $HOME is unknown, do nothing.�~�~rK�HOMEZUSERPROFILEZHOMEPATHZ	HOMEDRIVEr.N)
r/r0�
startswithrLr8r`�environ�KeyErrorr�encode�sys�getfilesystemencodingr
)r1�tilder[�n�userhomerYr2r2r3r>s0	%
"cCsyt|t�r�td�|kr7td�|kr7|Sddl}t|j|jdd�}d}d}d	}d
}ttdd�}n]d|kr�d|kr�|Sddl}|j|jd}d}d}d
}d}tj}|dd�}d}	t	|�}
xf|	|
krt||	|	d�}||kr�||	dd�}t	|�}
y/|j
|�}	|||d|	d�7}Wqgtk
r�|||7}|
d}	YqgXn�||kr�||	d|	d�|kr�||7}|	d7}	qg||	dd�}t	|�}
y|j
|�}	Wn*tk
rZ|||7}|
d}	YqgX|d|	�}y<|dkr�tjtjtj
|��}
n
||}
Wn tk
r�|||}
YnX||
7}n�||kr]||	d|	d�|kr||7}|	d7}	qg||	d|	d�|krs||	dd�}t	|�}
y4t|t�rz|j
d�}	n|j
d�}	WnJtk
r�t|t�r�|d|7}n|d|7}|
d}	YqZX|d|	�}y<|dkrtjtjtj
|��}
n
||}
Wn@tk
ret|t�rSd|d}
nd|d}
YnX||
7}qg|dd�}|	d7}	||	|	d�}x>|r�||kr�||7}|	d7}	||	|	d�}q�Wy<|dkrtjtjtj
|��}
n
||}
Wntk
r<||}
YnX||
7}|rg|	d8}	qgn
||7}|	d7}	qW|S)zfExpand shell variables of the forms $var, ${var} and %var%.

    Unknown variables are left unchanged.�$�%rNz_-�asciis'�%�{�$�environb�'�{rKrQ�}�}s${z${)r/r0�ord�stringZ
ascii_lettersZdigits�getattrr`rprLrU�
ValueError�fsencode�fsdecoderq)r1r�ZvarcharsZquoteZpercentZbraceZdollarrp�resrUZpathlen�c�var�valuer2r2r3ros�$	 



"




"




"


cCs�t|�}t|�d}t|�}|j|�r;|S|jt|�|�}t|�\}}|j|�r�||7}|j|�}n|j|�}d}x�|t	|�kr|||s�||t|�kr�||=q�|||kro|dkr7||d|kr7||d|d�=|d8}qy|dkrb|j
t|��rb||=qy|d7}q�|d7}q�W|r�|r�|jt|��n||j|�S)z0Normalize path, eliminating double slashes, etc.rQrrK)
r5r:rBrorHr7r�lstriprrL�endswith�appendr)r1r�dotdotZspecial_prefixes�prefix�compsr[r2r2r3r�s4
!
 
!

)�_getfullpathnamecCsRt|�sHt|t�r*tj�}ntj�}t||�}nt|�S)z&Return the absolute version of a path.)rr/r0r`�getcwdb�getcwdrr)r1�cwdr2r2r3rscCsb|r.yt|�}WqXtk
r*YqXXn*t|t�rLtj�}ntj�}t|�S)z&Return the absolute version of a path.)r�rbr/r0r`r�r�r)r1r2r2r3rs
�getwindowsversionrRrQcCs�t|�}|tkr't|�}n|s<td��ntt|��}tt|��}t|�\}}t|�\}}t|�t|�kr�dj||�}	t|	��ndd�|j	|�D�}
dd�|j	|�D�}d}xCt
|
|�D]2\}
}t|
�t|�kr3Pn|d7}qWt|t�rYd}nd	}|gt
|
�|||d
�}|s�t|�St|�S)z#Return a relative version of a pathzno path specifiedz,path is on mount '{0}', start on mount '{1}'cSsg|]}|r|�qSr2r2)�.0�xr2r2r3�
<listcomp>Es	zrelpath.<locals>.<listcomp>cSsg|]}|r|�qSr2r2)r�r�r2r2r3r�Fs	rrKs..z..N)r5rr:r�rrrrrEr�zipr/r0rLr)r1�startrZ	start_absZpath_absZstart_driveZ
start_restZ
path_driveZ	path_rest�error�
start_list�	path_listr[Ze1Ze2r�rel_listr2r2r3r%2s6	%
�)�_getfinalpathnamecCstt|��S)N)rr)�fr2r2r3r�esr�)�_isdir)r�r)4�__doc__r`rsrdr^�__all__rrr!rrr r�builtin_module_namesr"r4r5r7r8r:r=rBrrrrrrrr_r	r
rr�ntrh�ImportErrorrrrrr�rr#�hasattrr�r$r%r�rcr�rr2r2r2r3�<module>s�
	
#-
1w)
'