????
Your IP : 3.141.244.160
�
� f�7c%@sdZddlZddlZddlZddlZddlTdddddd d
ddd
ddddddddddddddddddd d!d"d#d$d%d&d'd(g%Zd)Zd*Zd)Zd+Z d,Z
d-ZdZ
d.Zd/d0�Zd1d�Zd2d�Zd3d�Zd4d�Zd5d �Zejje_d6d�Zd7d
�Zd8d�Zd9d�Zd:d�Zd;d�Zd<d�Zd=d�Zd>d�Zd?d�Zda da!d@d�Z"dAd�Z#dBd�Z$dCd&�Z%dDdE�Z&ej'dFkZ(ddGd(�Z)dS(Hu�Common operations on Posix pathnames.
Instead of importing this module directly, import os and refer to
this module as os.path. The "os.path" name is an alias for this
module on Posix systems; on other systems (e.g. Mac, Windows),
os.path provides the same operations in a manner specific to that
platform, and is an alias to another module (e.g. macpath, ntpath).
Some of this can actually be useful on non-Posix systems too, e.g.
for manipulation of the pathname component of URLs.
iN(u*unormcaseuisabsujoinu
splitdriveusplitusplitextubasenameudirnameucommonprefixugetsizeugetmtimeugetatimeugetctimeuislinkuexistsulexistsuisdiruisfileuismountu
expanduseru
expandvarsunormpathuabspathusamefileusameopenfileusamestatucurdirupardirusepupathsepudefpathualtsepuextsepudevnullurealpathusupports_unicode_filenamesurelpathu.u..u/u:u:/bin:/usr/binu /dev/nullcCst|t�rdSdSdS(Ns/u/(u
isinstanceubytes(upath((u./opt/alt/python33/lib64/python3.3/posixpath.pyu_get_sep&su_get_sepcCs7t|ttf�s3tdj|jj���n|S(u6Normalize case of pathname. Has no effect under Posixu2normcase() argument must be str or bytes, not '{}'(u
isinstanceubytesustru TypeErroruformatu __class__u__name__(us((u./opt/alt/python33/lib64/python3.3/posixpath.pyunormcase1s cCst|�}|j|�S(uTest whether a path is absolute(u_get_sepu
startswith(ususep((u./opt/alt/python33/lib64/python3.3/posixpath.pyuisabs=scGs�t|�}|}y^xW|D]O}|j|�r:|}q|sP|j|�r]||7}q|||7}qWWnMtk
r�tdd�|f|D��}|r�td�d�n�YnX|S(u�Join two or more pathname components, inserting '/' as needed.
If any component is an absolute path, all previous path components
will be discarded. An empty last part will result in a path that
ends with a separator.css'|]}t|tttf�VqdS(N(u
isinstanceustrubytesu bytearray(u.0us((u./opt/alt/python33/lib64/python3.3/posixpath.pyu <genexpr>Wsujoin.<locals>.<genexpr>u/Can't mix strings and bytes in path components.N(u_get_sepu
startswithuendswithu TypeErrorualluNone(uaupusepupathubuvalid_types((u./opt/alt/python33/lib64/python3.3/posixpath.pyujoinGs"
cCsxt|�}|j|�d}|d|�||d�}}|rn||t|�krn|j|�}n||fS(u�Split a pathname. Returns tuple "(head, tail)" where "tail" is
everything after the final slash. Either part may be empty.iN(u_get_sepurfindulenurstrip(upusepuiuheadutail((u./opt/alt/python33/lib64/python3.3/posixpath.pyusplitfs!cCs@t|t�rd}d}nd}d}tj||d|�S(Ns/s.u/u.(u
isinstanceubytesugenericpathu _splitextuNone(upusepuextsep((u./opt/alt/python33/lib64/python3.3/posixpath.pyusplitextvs cCs|dd�|fS(uJSplit a pathname into drive and path. On Posix, drive is always
empty.Ni((up((u./opt/alt/python33/lib64/python3.3/posixpath.pyu
splitdrive�scCs-t|�}|j|�d}||d�S(u)Returns the final component of a pathnameiN(u_get_sepurfind(upusepui((u./opt/alt/python33/lib64/python3.3/posixpath.pyubasename�scCsat|�}|j|�d}|d|�}|r]||t|�kr]|j|�}n|S(u-Returns the directory component of a pathnameiN(u_get_sepurfindulenurstrip(upusepuiuhead((u./opt/alt/python33/lib64/python3.3/posixpath.pyudirname�scCsEytj|�}Wntjtfk
r4dSYnXtj|j�S(u&Test whether a path is a symbolic linkF(uosulstatuerroruAttributeErroruFalseustatuS_ISLNKust_mode(upathust((u./opt/alt/python33/lib64/python3.3/posixpath.pyuislink�s
cCs1ytj|�Wntjk
r,dSYnXdS(uCTest whether a path exists. Returns True for broken symbolic linksFT(uosulstatuerroruFalseuTrue(upath((u./opt/alt/python33/lib64/python3.3/posixpath.pyulexists�s
cCs+tj|�}tj|�}t||�S(u9Test whether two pathnames reference the same actual file(uosustatusamestat(uf1uf2us1us2((u./opt/alt/python33/lib64/python3.3/posixpath.pyusamefile�scCs+tj|�}tj|�}t||�S(u:Test whether two open file objects reference the same file(uosufstatusamestat(ufp1ufp2us1us2((u./opt/alt/python33/lib64/python3.3/posixpath.pyusameopenfile�scCs"|j|jko!|j|jkS(u5Test whether two stat buffers reference the same file(ust_inoust_dev(us1us2((u./opt/alt/python33/lib64/python3.3/posixpath.pyusamestat�scCs�t|�rdSyRtj|�}t|t�rCt|d�}nt|d�}tj|�}Wntjk
r}dSYnX|j}|j}||kr�dS|j
}|j
}||kr�dSdS(u$Test whether a path is a mount points..u..FT(uislinkuFalseuosulstatu
isinstanceubytesujoinuerrorust_devuTrueust_ino(upathus1uparentus2udev1udev2uino1uino2((u./opt/alt/python33/lib64/python3.3/posixpath.pyuismount�s& c Cs�t|t�rd}nd}|j|�s1|St|�}|j|d�}|dkrjt|�}n|dkr�dtjkr�ddl}|j tj
��j}q.tjd}nrddl}|d|�}t|t�r�t|d�}ny|j
|�}Wntk
r$|SYnX|j}t|t�rUtj|�}d}nd }|j|�}|||d�p�|S(
uOExpand ~ and ~user constructions. If user or $HOME is unknown,
do nothing.s~u~iiuHOMENuASCIIs/u/(u
isinstanceubytesu
startswithu_get_sepufindulenuosuenvironupwdugetpwuidugetuidupw_dirustrugetpwnamuKeyErrorufsencodeurstrip( upathutildeusepuiupwduuserhomeunameupwenturoot((u./opt/alt/python33/lib64/python3.3/posixpath.pyu
expanduser�s:
cCs�t|t�rsd|kr|StsIddl}|jd|j�antj}d}d}ttdd�}nXd|kr�|St
s�ddl}|jd |j�a
nt
j}d
}d}tj}d}x|||�}|s�Pn|jd�\}}|j
d�} | j|�rB| j|�rB| dd
�} ny<|dkrstjtjtj| ��}
n
|| }
Wntk
r�|}Yq�X||d�}|d|�|
}t|�}||7}q�|S(uZExpand shell variables of form $var and ${var}. Unknown variables
are left unchanged.s$iNs\$(\w+|\{[^}]*\})s{s}uenvironbu$u\$(\w+|\{[^}]*\})u{u}ii����(u
isinstanceubytesu _varprogbureucompileuASCIIusearchugetattruosuNoneu_varproguenvironuspanugroupu
startswithuendswithufsencodeufsdecodeuKeyErrorulen(upathureusearchustartuenduenvironuiumujunameuvalueutail((u./opt/alt/python33/lib64/python3.3/posixpath.pyu
expandvars"sN "
c Cs^t|t�r*d}d}d}d}nd}d}d}d}||krR|S|j|�}|r�|j|d �r�|j|d
�r�d }n|j|�}g}xy|D]q}|||fkr�q�n||ks|r�|s|r|d|kr|j|�q�|r�|j�q�q�W|}|j|�}|rT|||}n|p]|S(
u0Normalize path, eliminating double slashes, etc.s/ss.s..u/uu.u..iiii����(u
isinstanceubytesu
startswithusplituappendupopujoin( upathusepuemptyudotudotdotuinitial_slashesucompsu new_compsucomp((u./opt/alt/python33/lib64/python3.3/posixpath.pyunormpathVs< '
cCsRt|�sHt|t�r*tj�}ntj�}t||�}nt|�S(uReturn an absolute path.(uisabsu
isinstanceubytesuosugetcwdbugetcwdujoinunormpath(upathucwd((u./opt/alt/python33/lib64/python3.3/posixpath.pyuabspath{scCs,t|dd�|i�\}}t|�S(ulReturn the canonical path of the specified filename, eliminating any
symbolic links encountered in the path.Ni(u
_joinrealpathuabspath(ufilenameupathuok((u./opt/alt/python33/lib64/python3.3/posixpath.pyurealpath�s"c
Cs�t|t�r$d}d}d}nd}d}d}t|�r[|dd�}|}nx?|r�|j|�\}}}|s^||kr�q^n||kr�|r�t|�\}}||kr�t|||�}q�q^|}q^nt||�}t|�s|}q^n||krK||}|dk r8q^nt||�dfSd||<t |t
j|�|�\}} | s�t||�dfS|||<q^W|d fS(
Ns/s.s..u/u.u..iFT(
u
isinstanceubytesuisabsu partitionusplitujoinuislinkuNoneuFalseu
_joinrealpathuosureadlinkuTrue(
upathurestuseenusepucurdirupardirunameu_unewpathuok((u./opt/alt/python33/lib64/python3.3/posixpath.pyu
_joinrealpath�sH
!u
_joinrealpathudarwinc Cs�|std��nt|t�r9d}d}d}nd}d}d}|dkr`|}ndd �t|�j|�D�}d
d �t|�j|�D�}tt||g��}|gt|�|||d�}|s�|St|�S(u#Return a relative version of a pathuno path specifieds.s/s..u.u/u..cSsg|]}|r|�qS(((u.0ux((u./opt/alt/python33/lib64/python3.3/posixpath.pyu
<listcomp>�s urelpath.<locals>.<listcomp>cSsg|]}|r|�qS(((u.0ux((u./opt/alt/python33/lib64/python3.3/posixpath.pyu
<listcomp>�s N( u
ValueErroru
isinstanceubytesuNoneuabspathusplitulenucommonprefixujoin( upathustartucurdirusepupardiru
start_listu path_listuiurel_list((u./opt/alt/python33/lib64/python3.3/posixpath.pyurelpath�s$ ""%(*u__doc__uosusysustatugenericpathu__all__ucurdirupardiruextsepusepupathsepudefpathuNoneualtsepudevnullu_get_sepunormcaseuisabsujoinusplitusplitextu _splitextu
splitdriveubasenameudirnameuislinkulexistsusamefileusameopenfileusamestatuismountu
expanduseru_varprogu _varprogbu
expandvarsunormpathuabspathurealpathu
_joinrealpathuplatformusupports_unicode_filenamesurelpath(((u./opt/alt/python33/lib64/python3.3/posixpath.pyu<module>s\
"*4%3