/opt/alt/python34/lib64/python3.4/__pycache__
NameSizeModeActions
abc.cpython-34.pyc78770644editdlrm
abc.cpython-34.pyo78270644editdlrm
aifc.cpython-34.pyc279120644editdlrm
aifc.cpython-34.pyo279120644editdlrm
antigravity.cpython-34.pyc8470644editdlrm
antigravity.cpython-34.pyo8470644editdlrm
argparse.cpython-34.pyc658740644editdlrm
argparse.cpython-34.pyo657150644editdlrm
ast.cpython-34.pyc123600644editdlrm
ast.cpython-34.pyo123600644editdlrm
asynchat.cpython-34.pyc83590644editdlrm
asynchat.cpython-34.pyo83590644editdlrm
asyncore.cpython-34.pyc179630644editdlrm
asyncore.cpython-34.pyo179630644editdlrm
base64.cpython-34.pyc182970644editdlrm
base64.cpython-34.pyo180990644editdlrm
bdb.cpython-34.pyc186940644editdlrm
bdb.cpython-34.pyo186940644editdlrm
binhex.cpython-34.pyc135410644editdlrm
binhex.cpython-34.pyo135410644editdlrm
bisect.cpython-34.pyc28580644editdlrm
bisect.cpython-34.pyo28580644editdlrm
bz2.cpython-34.pyc151560644editdlrm
bz2.cpython-34.pyo151560644editdlrm
calendar.cpython-34.pyc275670644editdlrm
calendar.cpython-34.pyo275670644editdlrm
cgi.cpython-34.pyc298270644editdlrm
cgi.cpython-34.pyo298270644editdlrm
cgitb.cpython-34.pyc110640644editdlrm
cgitb.cpython-34.pyo110640644editdlrm
chunk.cpython-34.pyc52700644editdlrm
chunk.cpython-34.pyo52700644editdlrm
cmd.cpython-34.pyc134560644editdlrm
cmd.cpython-34.pyo134560644editdlrm
code.cpython-34.pyc97020644editdlrm
code.cpython-34.pyo97020644editdlrm
codecs.cpython-34.pyc351320644editdlrm
codecs.cpython-34.pyo351320644editdlrm
codeop.cpython-34.pyc64660644editdlrm
codeop.cpython-34.pyo64660644editdlrm
colorsys.cpython-34.pyc36590644editdlrm
colorsys.cpython-34.pyo36590644editdlrm
compileall.cpython-34.pyc73780644editdlrm
compileall.cpython-34.pyo73780644editdlrm
configparser.cpython-34.pyc448820644editdlrm
configparser.cpython-34.pyo448820644editdlrm
contextlib.cpython-34.pyc103700644editdlrm
contextlib.cpython-34.pyo103700644editdlrm
copy.cpython-34.pyc80610644editdlrm
copy.cpython-34.pyo79750644editdlrm
copyreg.cpython-34.pyc46070644editdlrm
copyreg.cpython-34.pyo45660644editdlrm
cProfile.cpython-34.pyc46220644editdlrm
cProfile.cpython-34.pyo46220644editdlrm
crypt.cpython-34.pyc24370644editdlrm
crypt.cpython-34.pyo24370644editdlrm
csv.cpython-34.pyc129970644editdlrm
csv.cpython-34.pyo129970644editdlrm
datetime.cpython-34.pyc562640644editdlrm
datetime.cpython-34.pyo542960644editdlrm
decimal.cpython-34.pyc1725260644editdlrm
decimal.cpython-34.pyo1725260644editdlrm
difflib.cpython-34.pyc605150644editdlrm
difflib.cpython-34.pyo604670644editdlrm
dis.cpython-34.pyc145870644editdlrm
dis.cpython-34.pyo145870644editdlrm
doctest.cpython-34.pyc801100644editdlrm
doctest.cpython-34.pyo798370644editdlrm
dummy_threading.cpython-34.pyc12140644editdlrm
dummy_threading.cpython-34.pyo12140644editdlrm
enum.cpython-34.pyc163390644editdlrm
enum.cpython-34.pyo163390644editdlrm
filecmp.cpython-34.pyc91200644editdlrm
filecmp.cpython-34.pyo91200644editdlrm
fileinput.cpython-34.pyc142970644editdlrm
fileinput.cpython-34.pyo142970644editdlrm
fnmatch.cpython-34.pyc31460644editdlrm
fnmatch.cpython-34.pyo31460644editdlrm
formatter.cpython-34.pyc189160644editdlrm
formatter.cpython-34.pyo189160644editdlrm
fractions.cpython-34.pyc192700644editdlrm
fractions.cpython-34.pyo192700644editdlrm
ftplib.cpython-34.pyc333220644editdlrm
ftplib.cpython-34.pyo333220644editdlrm
functools.cpython-34.pyc236140644editdlrm
functools.cpython-34.pyo236140644editdlrm
genericpath.cpython-34.pyc34930644editdlrm
genericpath.cpython-34.pyo34930644editdlrm
getopt.cpython-34.pyc67330644editdlrm
getopt.cpython-34.pyo66910644editdlrm
getpass.cpython-34.pyc46240644editdlrm
getpass.cpython-34.pyo46240644editdlrm
gettext.cpython-34.pyc151740644editdlrm
gettext.cpython-34.pyo151740644editdlrm
glob.cpython-34.pyc28800644editdlrm
glob.cpython-34.pyo28800644editdlrm
gzip.cpython-34.pyc194460644editdlrm
gzip.cpython-34.pyo193920644editdlrm
hashlib.cpython-34.pyc79440644editdlrm
hashlib.cpython-34.pyo79440644editdlrm
heapq.cpython-34.pyc139100644editdlrm
heapq.cpython-34.pyo139100644editdlrm
hmac.cpython-34.pyc51460644editdlrm
hmac.cpython-34.pyo51460644editdlrm
imaplib.cpython-34.pyc434790644editdlrm
imaplib.cpython-34.pyo409550644editdlrm
imghdr.cpython-34.pyc41430644editdlrm
imghdr.cpython-34.pyo41430644editdlrm
imp.cpython-34.pyc98670644editdlrm
imp.cpython-34.pyo98670644editdlrm
inspect.cpython-34.pyc763270644editdlrm
inspect.cpython-34.pyo760060644editdlrm
io.cpython-34.pyc34580644editdlrm
io.cpython-34.pyo34580644editdlrm
ipaddress.cpython-34.pyc629840644editdlrm
ipaddress.cpython-34.pyo629840644editdlrm
keyword.cpython-34.pyc19460644editdlrm
keyword.cpython-34.pyo19460644editdlrm
linecache.cpython-34.pyc31120644editdlrm
linecache.cpython-34.pyo31120644editdlrm
locale.cpython-34.pyc372760644editdlrm
locale.cpython-34.pyo372760644editdlrm
lzma.cpython-34.pyc159170644editdlrm
lzma.cpython-34.pyo159170644editdlrm
macpath.cpython-34.pyc60060644editdlrm
macpath.cpython-34.pyo60060644editdlrm
macurl2path.cpython-34.pyc21020644editdlrm
macurl2path.cpython-34.pyo21020644editdlrm
mailbox.cpython-34.pyc702880644editdlrm
mailbox.cpython-34.pyo701890644editdlrm
mailcap.cpython-34.pyc65440644editdlrm
mailcap.cpython-34.pyo65440644editdlrm
mimetypes.cpython-34.pyc168070644editdlrm
mimetypes.cpython-34.pyo168070644editdlrm
modulefinder.cpython-34.pyc173760644editdlrm
modulefinder.cpython-34.pyo172970644editdlrm
netrc.cpython-34.pyc42770644editdlrm
netrc.cpython-34.pyo42770644editdlrm
nntplib.cpython-34.pyc363100644editdlrm
nntplib.cpython-34.pyo363100644editdlrm
ntpath.cpython-34.pyc133050644editdlrm
ntpath.cpython-34.pyo133050644editdlrm
nturl2path.cpython-34.pyc17160644editdlrm
nturl2path.cpython-34.pyo17160644editdlrm
numbers.cpython-34.pyc126670644editdlrm
numbers.cpython-34.pyo126670644editdlrm
opcode.cpython-34.pyc51740644editdlrm
opcode.cpython-34.pyo51740644editdlrm
operator.cpython-34.pyc127780644editdlrm
operator.cpython-34.pyo127780644editdlrm
optparse.cpython-34.pyc515370644editdlrm
optparse.cpython-34.pyo514600644editdlrm
os.cpython-34.pyc295990644editdlrm
os.cpython-34.pyo295990644editdlrm
pathlib.cpython-34.pyc404830644editdlrm
pathlib.cpython-34.pyo404830644editdlrm
pdb.cpython-34.pyc494720644editdlrm
pdb.cpython-34.pyo494060644editdlrm
pickle.cpython-34.pyc469840644editdlrm
pickle.cpython-34.pyo468380644editdlrm
pickletools.cpython-34.pyc702540644editdlrm
pickletools.cpython-34.pyo691670644editdlrm
pipes.cpython-34.pyc84310644editdlrm
pipes.cpython-34.pyo84310644editdlrm
pkgutil.cpython-34.pyc176000644editdlrm
pkgutil.cpython-34.pyo176000644editdlrm
platform.cpython-34.pyc311720644editdlrm
platform.cpython-34.pyo311720644editdlrm
plistlib.cpython-34.pyc301510644editdlrm
plistlib.cpython-34.pyo300680644editdlrm
poplib.cpython-34.pyc137540644editdlrm
poplib.cpython-34.pyo137540644editdlrm
posixpath.cpython-34.pyc98090644editdlrm
posixpath.cpython-34.pyo98090644editdlrm
pprint.cpython-34.pyc114600644editdlrm
pprint.cpython-34.pyo112950644editdlrm
profile.cpython-34.pyc151510644editdlrm
profile.cpython-34.pyo148980644editdlrm
pstats.cpython-34.pyc236750644editdlrm
pstats.cpython-34.pyo236750644editdlrm
pty.cpython-34.pyc42250644editdlrm
pty.cpython-34.pyo42250644editdlrm
pyclbr.cpython-34.pyc91920644editdlrm
pyclbr.cpython-34.pyo91920644editdlrm
pydoc.cpython-34.pyc909150644editdlrm
pydoc.cpython-34.pyo908540644editdlrm
py_compile.cpython-34.pyc68570644editdlrm
py_compile.cpython-34.pyo68570644editdlrm
queue.cpython-34.pyc92620644editdlrm
queue.cpython-34.pyo92620644editdlrm
quopri.cpython-34.pyc64460644editdlrm
quopri.cpython-34.pyo62360644editdlrm
random.cpython-34.pyc190590644editdlrm
random.cpython-34.pyo190590644editdlrm
re.cpython-34.pyc145500644editdlrm
re.cpython-34.pyo145500644editdlrm
reprlib.cpython-34.pyc58720644editdlrm
reprlib.cpython-34.pyo58720644editdlrm
rlcompleter.cpython-34.pyc56950644editdlrm
rlcompleter.cpython-34.pyo56950644editdlrm
runpy.cpython-34.pyc77530644editdlrm
runpy.cpython-34.pyo77530644editdlrm
sched.cpython-34.pyc65730644editdlrm
sched.cpython-34.pyo65730644editdlrm
selectors.cpython-34.pyc167440644editdlrm
selectors.cpython-34.pyo167440644editdlrm
shelve.cpython-34.pyc99550644editdlrm
shelve.cpython-34.pyo99550644editdlrm
shlex.cpython-34.pyc75180644editdlrm
shlex.cpython-34.pyo75180644editdlrm
shutil.cpython-34.pyc330150644editdlrm
shutil.cpython-34.pyo330150644editdlrm
site.cpython-34.pyc179710644editdlrm
site.cpython-34.pyo179710644editdlrm
smtpd.cpython-34.pyc256690644editdlrm
smtpd.cpython-34.pyo256690644editdlrm
smtplib.cpython-34.pyc331290644editdlrm
smtplib.cpython-34.pyo330550644editdlrm
sndhdr.cpython-34.pyc67690644editdlrm
sndhdr.cpython-34.pyo67690644editdlrm
socket.cpython-34.pyc181110644editdlrm
socket.cpython-34.pyo180610644editdlrm
socketserver.cpython-34.pyc232550644editdlrm
socketserver.cpython-34.pyo232550644editdlrm
sre_compile.cpython-34.pyc119350644editdlrm
sre_compile.cpython-34.pyo117780644editdlrm
sre_constants.cpython-34.pyc55810644editdlrm
sre_constants.cpython-34.pyo55810644editdlrm
sre_parse.cpython-34.pyc202380644editdlrm
sre_parse.cpython-34.pyo202380644editdlrm
ssl.cpython-34.pyc276080644editdlrm
ssl.cpython-34.pyo276080644editdlrm
stat.cpython-34.pyc35780644editdlrm
stat.cpython-34.pyo35780644editdlrm
statistics.cpython-34.pyc171580644editdlrm
statistics.cpython-34.pyo168560644editdlrm
string.cpython-34.pyc83760644editdlrm
string.cpython-34.pyo83760644editdlrm
stringprep.cpython-34.pyc136360644editdlrm
stringprep.cpython-34.pyo135730644editdlrm
struct.cpython-34.pyc3470644editdlrm
struct.cpython-34.pyo3470644editdlrm
subprocess.cpython-34.pyc433590644editdlrm
subprocess.cpython-34.pyo432460644editdlrm
sunau.cpython-34.pyc183090644editdlrm
sunau.cpython-34.pyo183090644editdlrm
symbol.cpython-34.pyc26620644editdlrm
symbol.cpython-34.pyo26620644editdlrm
symtable.cpython-34.pyc113050644editdlrm
symtable.cpython-34.pyo111830644editdlrm
sysconfig.cpython-34.pyc172870644editdlrm
sysconfig.cpython-34.pyo172870644editdlrm
tabnanny.cpython-34.pyc77490644editdlrm
tabnanny.cpython-34.pyo77490644editdlrm
tarfile.cpython-34.pyc680400644editdlrm
tarfile.cpython-34.pyo680400644editdlrm
telnetlib.cpython-34.pyc193940644editdlrm
telnetlib.cpython-34.pyo193940644editdlrm
tempfile.cpython-34.pyc215760644editdlrm
tempfile.cpython-34.pyo215760644editdlrm
textwrap.cpython-34.pyc138000644editdlrm
textwrap.cpython-34.pyo137140644editdlrm
this.cpython-34.pyc13160644editdlrm
this.cpython-34.pyo13160644editdlrm
threading.cpython-34.pyc389650644editdlrm
threading.cpython-34.pyo382520644editdlrm
timeit.cpython-34.pyc110620644editdlrm
timeit.cpython-34.pyo110620644editdlrm
token.cpython-34.pyc36150644editdlrm
token.cpython-34.pyo36150644editdlrm
tokenize.cpython-34.pyc199510644editdlrm
tokenize.cpython-34.pyo199010644editdlrm
trace.cpython-34.pyc241840644editdlrm
trace.cpython-34.pyo241270644editdlrm
traceback.cpython-34.pyc110910644editdlrm
traceback.cpython-34.pyo110910644editdlrm
tracemalloc.cpython-34.pyc171300644editdlrm
tracemalloc.cpython-34.pyo171300644editdlrm
tty.cpython-34.pyc11460644editdlrm
tty.cpython-34.pyo11460644editdlrm
types.cpython-34.pyc55600644editdlrm
types.cpython-34.pyo55600644editdlrm
uu.cpython-34.pyc40210644editdlrm
uu.cpython-34.pyo40210644editdlrm
uuid.cpython-34.pyc218640644editdlrm
uuid.cpython-34.pyo218020644editdlrm
warnings.cpython-34.pyc122680644editdlrm
warnings.cpython-34.pyo115360644editdlrm
wave.cpython-34.pyc191350644editdlrm
wave.cpython-34.pyo190740644editdlrm
weakref.cpython-34.pyc203450644editdlrm
weakref.cpython-34.pyo203080644editdlrm
webbrowser.cpython-34.pyc171320644editdlrm
webbrowser.cpython-34.pyo170930644editdlrm
xdrlib.cpython-34.pyc90020644editdlrm
xdrlib.cpython-34.pyo90020644editdlrm
zipfile.cpython-34.pyc458200644editdlrm
zipfile.cpython-34.pyo457710644editdlrm
_bootlocale.cpython-34.pyc10470644editdlrm
_bootlocale.cpython-34.pyo10160644editdlrm
_collections_abc.cpython-34.pyc239490644editdlrm
_collections_abc.cpython-34.pyo239490644editdlrm
_compat_pickle.cpython-34.pyc75010644editdlrm
_compat_pickle.cpython-34.pyo74270644editdlrm
_dummy_thread.cpython-34.pyc48250644editdlrm
_dummy_thread.cpython-34.pyo48250644editdlrm
_markupbase.cpython-34.pyc89320644editdlrm
_markupbase.cpython-34.pyo87450644editdlrm
_osx_support.cpython-34.pyc106300644editdlrm
_osx_support.cpython-34.pyo106300644editdlrm
_pyio.cpython-34.pyc649330644editdlrm
_pyio.cpython-34.pyo649070644editdlrm
_sitebuiltins.cpython-34.pyc36770644editdlrm
_sitebuiltins.cpython-34.pyo36770644editdlrm
_strptime.cpython-34.pyc157790644editdlrm
_strptime.cpython-34.pyo157790644editdlrm
_sysconfigdata.cpython-34.pyc227000644editdlrm
_sysconfigdata.cpython-34.pyo227000644editdlrm
_threading_local.cpython-34.pyc69460644editdlrm
_threading_local.cpython-34.pyo69460644editdlrm
_weakrefset.cpython-34.pyc84650644editdlrm
_weakrefset.cpython-34.pyo84650644editdlrm
__future__.cpython-34.pyc41680644editdlrm
__future__.cpython-34.pyo41680644editdlrm
__phello__.foo.cpython-34.pyc1340644editdlrm
__phello__.foo.cpython-34.pyo1340644editdlrm
Edit: /opt/alt/python34/lib64/python3.4/__pycache__/pathlib.cpython-34.pyo (40483B)
f@sSddlZddlZddlZddlZddlZddlZddlZddlZddlm Z ddl m Z ddl m Z mZmZddlmZddlmZmZmZmZmZmZmZddlmZdZejd krUddlZej dd d dfkrFdd lm!Z!n d ZdZ!ndZddddddgZ"ddZ#Gddde$Z%Gddde%Z&Gddde%Z'e&Z(e'Z)GdddZ*Gddde*Z+e+Z,e d d!Z-d"d#Z.e/ed$rGej0e.Z.nGd%d&d&Z1Gd'd(d(Z2Gd)d*d*e1Z3Gd+d,d,e1Z4Gd-d.d.e1Z5Gd/d0d0e Z6Gd1dde$Z7Gd2dde7Z8Gd3dde7Z9Gd4dde7Z:Gd5dde:e8Z;Gd6dde:e9Z<dS)7N)Sequence)contextmanager)EINVALENOENTENOTDIR) attrgetter)S_ISDIRS_ISLNKS_ISREGS_ISSOCKS_ISBLKS_ISCHRS_ISFIFO)quote_from_bytesTnt)_getfinalpathnameFPurePath PurePosixPathPureWindowsPathPath PosixPath WindowsPathcCs"d|kp!d|kp!d|kS)N*?[)patrr,/opt/alt/python34/lib64/python3.4/pathlib.py_is_wildcard_pattern&sr c@s:eZdZdZddZddZddZdS) _FlavourzPA flavour implements a particular (platform-specific) set of path semantics.cCs|jj|_dS)N)sepjoin)selfrrr__init__0sz_Flavour.__init__c Csg}|j}|j}d}}t|}x@|D]8}|sGq5n|rb|j||}n|j|\}}} || krxvt| j|D]1} | r| dkr|jtj| qqWn+| r| dkr|jtj| n|s |r5|sixU|D]J}|s*qn|rE|j||}n|j|d}|rPqqWnPq5q5W|s}|r|j||n|j |||fS)N.r) r"altsepreversedreplace splitrootsplitappendsysinternreverse) r$partsZparsedr"r(drvrootitpartZrelxrrr parse_parts3s@            z_Flavour.parse_partscCs|r8| r|r||||g|ddfSn_|r||ksh|j||j|kr||||ddfSn||||fS|||fS)z Join the two paths represented by the respective (drive, root, parts) tuples. Return a new (drive, root, parts) tuple. N)casefold)r$r2r3r1Zdrv2Zroot2Zparts2rrrjoin_parsed_partsYs %*z_Flavour.join_parsed_partsN)__name__ __module__ __qualname____doc__r%r7r:rrrrr!,s   &r!c@sKeZdZdZdZdZeZej dkZ e dde e de dd De d de e d e d d DBZd Zddddhdde d dDBdde d dDBZeddZddZddZddZeddZd d!Zd"d#Zd$d%Zd&S)'_WindowsFlavour\/Trccs|]}t|VqdS)N)chr).0r6rrr wsz_WindowsFlavour.azr8ccs|]}t|VqdS)N)rB)rCr6rrrrDxsAZz\\?\ZCONZPRNZAUXZNULcCsh|]}d|qS)zCOM%dr)rCirrr ~s z_WindowsFlavour. cCsh|]}d|qS)zLPT%dr)rCrIrrrrJs c Cs|dd}|dd}||krp||krp|j|\}}|dd}|dd}nd}|dd}||krf||krf||krf|j|d}|dkrf|j||d}||dkrc|dkr t|}n|r8||d||||ddfS|d||||ddfSqcqfnd} } |dkr||jkr|dd} |dd}|}n||kr|} |j|}n|| | |fS) Nrr8rr&:rN)_split_extended_pathfindlen drive_letterslstrip) r$r5r"firstsecondprefixZthirdindexZindex2r2r3rrrr+s6$  ).   z_WindowsFlavour.splitrootcCs |jS)N)lower)r$srrrr9sz_WindowsFlavour.casefoldcCsdd|DS)NcSsg|]}|jqSr)rX)rCprrr s z2_WindowsFlavour.casefold_parts..r)r$r1rrrcasefold_partssz_WindowsFlavour.casefold_partscCs?t|}|stjStdk r;|jt|SdS)N)strosgetcwdr_ext_to_normal)r$pathrYrrrresolves    z_WindowsFlavour.resolvecCs|d}|j|rr|dd}|dd}|jdrr||dd7}d|dd}qrn||fS)Nr&zUNC\rLr@) startswith)r$rYZ ext_prefixrVrrrrOsz$_WindowsFlavour._split_extended_pathcCs|j|dS)Nr8)rO)r$rYrrrr`sz_WindowsFlavour._ext_to_normalcCsE|s dS|djdr!dS|djddj|jkS)NFrz\\r8r'rN)rd partitionupperreserved_names)r$r1rrr is_reserveds z_WindowsFlavour.is_reservedcCs|j}t|dkrg|ddkrg|jddjd}d|t|jdfSdt|jjdSdS)Nrr8rMrAz file:///%s/%szutf-8zfile:)driverQas_posixrSurlquote_from_bytesencode)r$rarirestrrrmake_uris  "z_WindowsFlavour.make_uriN)r;r<r=r"r(has_drvntpathpathmodr^name is_supportedsetrangeordrRZext_namespace_prefixrgr+r9r\rbrOr`rhrnrrrrr?ks$ /3) '     r?c@seZdZdZdZdZeZej dkZ eddZ ddZ d d Z d d Zd dZddZdS) _PosixFlavourrAr&FrcCss|rb|d|krb|j|}t|t|dkrRd|d|fSd||fSn dd|fSdS)Nrrr&)rSrQ)r$r5r"Z stripped_partrrrr+s z_PosixFlavour.splitrootcCs|S)Nr)r$rYrrrr9sz_PosixFlavour.casefoldcCs|S)Nr)r$r1rrrr\sz_PosixFlavour.casefold_partscsj|j|jifdd|jrEdn tj}|t|piS)Ncs;|jrd}nx|jD] }| s(|dkrGq(n|dkrq|j\}}}q(n||}|kr|}|dk rq(ntd|nyj|}Wn@tk r}z |jtkrn|}WYdd}~Xq(Xd|<||}||._resolver&)r" _accessor is_absoluter^r_r])r$rabaser)rrrr"rrbs   %z_PosixFlavour.resolvecCsdS)NFr)r$r1rrrrh.sz_PosixFlavour.is_reservedcCst|}dt|S)Nzfile://)bytesrk)r$raZbpathrrrrn1s z_PosixFlavour.make_uriN)r;r<r=r"r(ro posixpathrqr^rrrsr+r9r\rbrhrnrrrrrws    , rwc@seZdZdZdS) _AccessorzjAn accessor implements a particular (system-specific or not) way of accessing paths on the filesystem.N)r;r<r=r>rrrrr<s rc@sEeZdZddZddZeejZeejZeejZeej Z eej Z e edreej Z n ddZ eej Z eejZeejZeejZeejZerereejZq&dd Zned d ZeejZd d Zd S)_NormalAccessorcs+tjfdd}t|S)Ncst||S)N)r])pathobjargs)strfuncrrwrappedDsz._NormalAccessor._wrap_strfunc..wrapped) functoolswraps staticmethod)rrr)rr _wrap_strfuncCs!z_NormalAccessor._wrap_strfunccs+tjfdd}t|S)Ncst|t||S)N)r])ZpathobjAZpathobjBr)rrrrJsz5_NormalAccessor._wrap_binary_strfunc..wrapped)rrr)rrr)rr_wrap_binary_strfuncIs!z$_NormalAccessor._wrap_binary_strfunclchmodcCstddS)Nz%lchmod() not available on this system)NotImplementedError)r$rmoderrrr\sz_NormalAccessor.lchmodcCstddS)Nz&symlink() not available on this system)r)rEbtarget_is_directoryrrrsymlinkmsz_NormalAccessor.symlinkcCstjt|t|S)N)r^rr])rErrrrrrqscCs tj|S)N)r^rz)r$rarrrrzxsz_NormalAccessor.readlinkN)r;r<r=rrr^statlstatopenlistdirchmodhasattrrmkdirunlinkrmdirrenamer*rsupports_symlinksrrutimerzrrrrrAs,    rc#sdyjVWnMtk r_ifdd}d|_z |VWdjXYnXdS)Nc s=y |SWn*tk r8|}|<|SYnXdS)N)KeyError)rvalue)cachefuncrrwrappers   z_cached..wrapperT) __cached__AttributeErrorclear)rrr)rrr_cacheds    rcCsr|d}|dd}|dkr/t}n6d|krJtdnt|r_t}nt}|||S)Nrr8z**z:Invalid pattern: '**' can only be an entire path component)_RecursiveWildcardSelector ValueErrorr _WildcardSelector_PreciseSelector) pattern_partsr child_partsclsrrr_make_selectors      r lru_cachec@s.eZdZdZddZddZdS) _SelectorzYA selector matches a specific glob pattern part against the children of a given path.cCs1||_|r!t||_n t|_dS)N)rr successor_TerminatingSelector)r$rrrrr%s z_Selector.__init__cCs@t|}|j}|j}|jj}|j||||S)zuIterate over all child paths of `parent_path` matched by this selector. This can contain parent_path itself.)typeis_direxistsrr _select_from)r$ parent_pathZpath_clsrrrrrr select_froms     z_Selector.select_fromN)r;r<r=r>r%rrrrrrs  rc@seZdZddZdS)rccs |VdS)Nr)r$rrrrrrrrsz!_TerminatingSelector._select_fromN)r;r<r=rrrrrrs rc@s(eZdZddZddZdS)rcCs||_tj||dS)N)rrrr%)r$rrrrrrr%s z_PreciseSelector.__init__c cs}y`||sdS|j|j}||r_x+|jj||||D] }|VqMWnWntk rxdSYnXdS)N)_make_child_relpathrrrrPermissionError)r$rrrrrarZrrrrs  " z_PreciseSelector._select_fromN)r;r<r=r%rrrrrrs  rc@s(eZdZddZddZdS)rcCs/tjtj||_tj||dS)N)recompilefnmatch translaterrr%)r$rrrrrr%sz_WildcardSelector.__init__c csy||sdS|jj}xo||D]a}||}|jj|r,|j|}x+|jj||||D] } | Vq{Wq,q,WWntk rdSYnXdS)N)_flavourr9rmatchrrrr) r$rrrrcfrrZ casefoldedrarZrrrrs   " z_WildcardSelector._select_fromN)r;r<r=r%rrrrrrs  rc@s4eZdZddZddZddZdS)rcCstj||dS)N)rr%)r$rrrrrr%sz#_RecursiveWildcardSelector.__init__c cs|Vykxd||D]V}|j|}||r|j rx%|j|||D] }|VqYWqqWWntk rdSYnXdS)N)r is_symlink_iterate_directoriesr)r$rrrrrrarZrrrrs z/_RecursiveWildcardSelector._iterate_directoriesc csy||sdSt|}t}zq|jj}x^|j|||D]G}x>|||||D]'}||krl|V|j|qlqlWqPWWd|jXWdQXWntk rdSYnXdS)N)rrtrrraddrr) r$rrrrZyieldedZsuccessor_selectZstarting_pointrZrrrrs     z'_RecursiveWildcardSelector._select_fromN)r;r<r=r%rrrrrrrs   rc@sLeZdZdZdZddZdd Zd d Zd d ZdS) _PathParentszvThis object provides sequence-like access to the logical ancestors of a path. Don't try to construct it yourself._pathcls_drv_root_partscCs7t||_|j|_|j|_|j|_dS)N)rrrrr)r$rarrrr%s  z_PathParents.__init__cCs4|js|jr#t|jdSt|jSdS)Nr8)rrrQr)r$rrr__len__sz_PathParents.__len__cCs[|dks|t|kr-t|n|jj|j|j|jd| dS)Nrr8)rQ IndexErrorr_from_parsed_partsrrr)r$idxrrr __getitem__#sz_PathParents.__getitem__cCsdj|jjS)Nz <{}.parents>)formatrr;)r$rrr__repr__)sz_PathParents.__repr__N)z_pathclsz_drvz_rootz_parts) r;r<r=r> __slots__r%rrrrrrrrs    rc@s\eZdZdZdXZd d Zd d Zed dZedddZ edddZ eddZ ddZ ddZ ddZddZddZd d!Zd"d#Zed$d%Zd&d'Zd(d)Zd*d+Zd,d-Zd.d/Zd0d1Zeedd2d3Zeedd2d4Zed5d6Zed7d8Zed9d:Z ed;d<Z!ed=d>Z"d?d@Z#dAdBZ$dCdDZ%edEdFZ&dGdHZ'dIdJZ(dKdLZ)edMdNZ*edOdPZ+dQdRZ,dSdTZ-dUdVZ.dWS)YraHPurePath represents a filesystem path and offers operations which don't imply any actual filesystem I/O. Depending on your system, instantiating a PurePath will return either a PurePosixPath or a PureWindowsPath object. You can also instantiate either of these classes directly, regardless of your system. rrr_str_hash_pparts_cached_cpartscGs7|tkr*tjdkr!tnt}n|j|S)zConstruct a PurePath from one or several strings and or existing PurePath objects. The strings and path objects are combined so as to yield a canonicalized path, which is incorporated into the new PurePath object. r)rr^rrrr _from_parts)rrrrr__new__9s zPurePath.__new__cCs|jt|jfS)N) __class__tupler)r$rrr __reduce__CszPurePath.__reduce__cCsg}xh|D]`}t|tr2||j7}q t|trW|jt|q tdt|q W|jj|S)Nz/argument should be a path or str object, not %r) isinstancerrr]r- TypeErrorrrr7)rrr1rErrr _parse_argsHs zPurePath._parse_argsTcCsYtj|}|j|\}}}||_||_||_|rU|jn|S)N)objectrrrrr_init)rrinitr$r2r3r1rrrrYs    zPurePath._from_partscCsAtj|}||_||_||_|r=|jn|S)N)rrrrrr)rr2r3r1rr$rrrrfs    zPurePath._from_parsed_partscCsB|s |r.|||jj|ddS|jj|SdS)Nr8)rr#)rr2r3r1rrr_format_parsed_partsps "zPurePath._format_parsed_partscCsdS)Nr)r$rrrrwszPurePath._initcCs^|j|\}}}|jj|j|j|j|||\}}}|j|||S)N)rrr:rrrr)r$rr2r3r1rrr _make_child{s *zPurePath._make_childc CsRy |jSWn@tk rM|j|j|j|jp<d|_|jSYnXdS)z[Return the string representation of the path, suitable for passing to system calls.r'N)rrrrrr)r$rrr__str__s   zPurePath.__str__cCs"|j}t|j|jdS)zNReturn the string representation of the path with forward (/) slashes.rA)rr]r*r")r$frrrrjs zPurePath.as_posixcCstjt|S)zaReturn the bytes representation of the path. This is only recommended to use under Unix.)r^fsencoder])r$rrr __bytes__szPurePath.__bytes__cCsdj|jj|jS)Nz{}({!r}))rrr;rj)r$rrrrszPurePath.__repr__cCs+|jstdn|jj|S)z Return the path as a 'file' URI.z.relative path can't be expressed as a file URI)rrrrn)r$rrras_uris zPurePath.as_uric CsCy |jSWn1tk r>|jj|j|_|jSYnXdS)N)rrrr\r)r$rrr_cpartss   zPurePath._cpartscCs5t|tstS|j|jko4|j|jkS)N)rrNotImplementedrr)r$otherrrr__eq__szPurePath.__eq__c CsCy |jSWn1tk r>tt|j|_|jSYnXdS)N)rrhashrr)r$rrr__hash__s   zPurePath.__hash__cCs6t|t s"|j|jk r&tS|j|jkS)N)rrrrr)r$rrrr__lt__s"zPurePath.__lt__cCs6t|t s"|j|jk r&tS|j|jkS)N)rrrrr)r$rrrr__le__s"zPurePath.__le__cCs6t|t s"|j|jk r&tS|j|jkS)N)rrrrr)r$rrrr__gt__s"zPurePath.__gt__cCs6t|t s"|j|jk r&tS|j|jkS)N)rrrrr)r$rrrr__ge__s"zPurePath.__ge__docz.The drive prefix (letter or UNC path), if any.zThe root of the path, if any.cCs|j|j}|S)z/The concatenation of the drive and root, or ''.)rr)r$anchorrrrrszPurePath.anchorcCs?|j}t||js$|jr*dndkr7dS|dS)z!The final path component, if any.r8rr&rN)rrQrr)r$r1rrrrrs *z PurePath.namecCsT|j}|jd}d|ko9t|dknrL||dSdSdS)z*The final component's last suffix, if any.r'rr8Nr&)rrrfindrQ)r$rrrIrrrsuffixs  &zPurePath.suffixcCsO|j}|jdrgS|jd}dd|jdddDS)z1A list of the final component's suffixes, if any.r'cSsg|]}d|qS)r'r)rCrrrrr[s z%PurePath.suffixes..r8N)rrendswithrSr,)r$rrrrrsuffixess  zPurePath.suffixescCsT|j}|jd}d|ko9t|dknrL|d|S|SdS)z0The final path component, minus its last suffix.r'rr8N)rrrrQ)r$rrrIrrrstems  &z PurePath.stemcCs|jstd|fn|jj|f\}}}| s|d|jj|jjgks|s|st|dkrtd|n|j|j|j |j dd|gS)z-Return a new path with the file name changed.z%r has an empty namer8zInvalid name %rNrNrN) rrrrr7r"r(rQrrrr)r$rrr2r3r1rrr with_names )zPurePath.with_namecCs|j}|j|ks0|jrC|j|krCtd|n|rY|jd se|dkrxtd|n|j}|std|fn|j}|s||}n|dt| |}|j|j |j |j dd|gS)zCReturn a new path with the file suffix changed (or added, if none).zInvalid suffix %rr'z%r has an empty nameNr8rN) rr"r(rrdrrrrQrrrr)r$rrrrZ old_suffixrrr with_suffixs '"   zPurePath.with_suffixc GsW|stdn|j}|j}|j}|rS||g|dd}n|}|j|\}}}|r||g|dd} n|} t| } |jj} | dkr|p|n| |d| | | kr(|j|||} t dj t |t | n|j d| dkrC|nd|| dS)zReturn the relative path to another path identified by the passed arguments. If the operation is not possible (because this is not a subpath of the other path), raise ValueError. zneed at least one argumentr8Nrz{!r} does not start with {!r}r&) rrrrrrQrr\rrrr]r) r$rr1r2r3Z abs_partsZto_drvZto_rootZto_partsZ to_abs_partsnrZ formattedrrr relative_tos(      : zPurePath.relative_toc Cs=y |jSWn+tk r8t|j|_|jSYnXdS)zZAn object providing sequence-like access to the components in the filesystem path.N)rrrr)r$rrrr17s   zPurePath.partscGs |j|S)zCombine this path with one or several arguments, and return a new path representing either a subpath (if all arguments are relative paths) or a totally different path (if one of the arguments is anchored). )r)r$rrrrjoinpathCszPurePath.joinpathcCs|j|fS)N)r)r$keyrrr __truediv__KszPurePath.__truediv__cCs|j|g|jS)N)rr)r$rrrr __rtruediv__NszPurePath.__rtruediv__cCsZ|j}|j}|j}t|dkr=|s9|r=|S|j|||ddS)zThe logical parent of the path.r8NrN)rrrrQr)r$r2r3r1rrrparentQs    zPurePath.parentcCs t|S)z*A sequence of this path's logical parents.)r)r$rrrparents[szPurePath.parentscCs'|js dS|jj p&t|jS)zSTrue if the path is absolute (has both a root and, if applicable, a drive).F)rrroboolr)r$rrrr`s zPurePath.is_absolutecCs|jj|jS)zaReturn True if the path contains one of the special names reserved by the system, if any.)rrhr)r$rrrrhgszPurePath.is_reservedc Cs/|jj}||}|jj|f\}}}|sKtdn|rj|||jkrjdS|r|||jkrdS|j}|s|rt|t|krdS|dd}nt|t|krdSx?tt |t |D]"\}}t j ||sdSqWdS)zE Return True if this path matches the given pattern. z empty patternFr8NT) rr9r7rrrrrQzipr)rZ fnmatchcase) r$Z path_patternrr2r3Z pat_partsr1r5rrrrrls(    (zPurePath.matchN)z_drvz_rootz_partsz_strz_hashz_ppartsz_cached_cparts)/r;r<r=r>rrr classmethodrrrrrrrrjrrrpropertyrrrrrrrrrir3rrrrrrrrrr1rrrr r rrhrrrrrr-s\                            c@seZdZeZfZdS)rN)r;r<r=_posix_flavourrrrrrrrs c@seZdZeZfZdS)rN)r;r<r=_windows_flavourrrrrrrrs c@seZdZdRZddZdddZdd Zd d Zd d ZddZ dddZ dddZ e ddZ ddZddZddZddZd d!Zd"d#Zd$d%Zd&d'Zd(dSdddd*d+Zdd,d-d.Zdd/d0d1Zd2d3Zd4d5Zd6d7Zd8d9Zd:d;Zd<d=Zd>d?Zd/d@dAZ dBdCZ!dDdEZ"dFdGZ#dHdIZ$dJdKZ%dLdMZ&dNdOZ'dPdQZ(dS)Trr_closedcOsr|tkr*tjdkr!tnt}n|j|dd}|jjsdtd|j fn|j |S)NrrFz$cannot instantiate %r on your system) rr^rrrrrrrsrr;r)rrkwargsr$rrrrs   z Path.__new__NcCs1d|_|dk r$|j|_n t|_dS)NF)rr_normal_accessor)r$templaterrrrs  z Path._initcCs)|j|g}|j|j|j|S)N)rrrr)r$r5r1rrrrszPath._make_child_relpathcCs|jr|jn|S)N)r _raise_closed)r$rrr __enter__s  zPath.__enter__cCs d|_dS)NT)r)r$tvtbrrr__exit__sz Path.__exit__cCstddS)NzI/O operation on closed path)r)r$rrrrszPath._raise_closedicCs|jj|||S)N)rr)r$rrflagsrrrr_openersz Path._openericCs,|jr|jn|jj|||S)zm Open the file pointed by this path and return a file descriptor, as os.open() does. )rrrr)r$rrrrr _raw_opens  zPath._raw_opencCs|tjS)zjReturn a new path pointing to the current working directory (as returned by os.getcwd()). )r^r_)rrrrcwdszPath.cwdccsm|jr|jnxP|jj|D]<}|dkrAq)n|j|V|jr)|jq)q)WdS)zyIterate over the files in this directory. Does not yield any result for the special paths '.' and '..'. r'..N>r'r)rrrrr)r$rrrrriterdirs    z Path.iterdirccs|jj|}|jj|f\}}}|s<|rKtdntt|}x|j|D] }|VqmWdS)zIterate over this subtree and yield all existing files (of any kind, including directories) matching the given pattern. z%Non-relative patterns are unsupportedN)rr9r7rrrr)r$patternr2r3rselectorrZrrrglobs z Path.globccs|jj|}|jj|f\}}}|s<|rKtdntdt|}x|j|D] }|VqqWdS)zRecursively yield all existing files (of any kind, including directories) matching the given pattern, anywhere in this subtree. z%Non-relative patterns are unsupported**N)r$)rr9r7rrrr)r$r!r2r3rr"rZrrrrglobs z Path.rglobcCs_|jr|jn|jr&|S|jtjg|jdd}|jd||S)aReturn an absolute version of this path. This function works even if the path doesn't point to anything. No normalization is done, i.e. all '.' and '..' will be kept along. Use resolve() to get the canonical path to a file. rFr)rrrrr^r_rr)r$objrrrabsolutes   %z Path.absolutecCs|jr|jn|jj|}|dkrS|jt|j}n|jjj|}|j |fdd}|j d||S)z Make the path absolute, resolving all symlinks on the way and also normalizing it (for example turning slashes into backslashes under Windows). NrFr) rrrrbrr]r'rqnormpathrr)r$rYZnormedr&rrrrb s    z Path.resolvecCs|jj|S)zh Return the result of the stat() system call on this path, like os.stat() does. )rr)r$rrrr sz Path.statcCs%ddl}|j|jjjS)z: Return the login name of the file owner. rN)pwdgetpwuidrst_uidZpw_name)r$r)rrrowner's z Path.ownercCs%ddl}|j|jjjS)z8 Return the group name of the file gid. rN)grpZgetgrgidrst_gidZgr_name)r$r-rrrgroup.s z Path.grouprr8c CsA|jr|jntjt||||||d|jS)z| Open the file pointed by this path and return a file object, as the built-in open() function does. Zopener)rriorr]r)r$r bufferingencodingerrorsnewlinerrrr5s  !z Path.openTc Cs|jr|jn|rOy|jj|dWntk rGYqOXdSntjtjB}|su|tjO}n|j ||}tj |dS)zS Create this file with the given access mode, if it doesn't exist. N) rrrrr{r^O_CREATO_WRONLYO_EXCLrclose)r$rexist_okrfdrrrtouch@s   z Path.touchFcCs|jr|jn|s2|jj||nzy|jj||Wn`tk r}z@|jtkrsn|jjdd|jj||WYdd}~XnXdS)Nr T)rrrrr{r|rr )r$rr rrrrrWs  z Path.mkdircCs-|jr|jn|jj||dS)zF Change the permissions of the path, like os.chmod(). N)rrrr)r$rrrrres  z Path.chmodcCs-|jr|jn|jj||dS)z Like chmod(), except if the path points to a symlink, the symlink's permissions are changed, rather than its target's. N)rrrr)r$rrrrrms  z Path.lchmodcCs*|jr|jn|jj|dS)zd Remove this file or link. If the path is a directory, use rmdir() instead. N)rrrr)r$rrrrvs  z Path.unlinkcCs*|jr|jn|jj|dS)zF Remove this directory. The directory must be empty. N)rrrr)r$rrrrs  z Path.rmdircCs&|jr|jn|jj|S)z Like stat(), except if the path points to a symlink, the symlink's status information is returned, rather than its target's. )rrrr)r$rrrrs  z Path.lstatcCs-|jr|jn|jj||dS)z5 Rename this path to the given path. N)rrrr)r$rrrrrs  z Path.renamecCs-|jr|jn|jj||dS)zo Rename this path to the given path, clobbering the existing destination if it exists. N)rrrr*)r$rrrrr*s  z Path.replacecCs0|jr|jn|jj|||dS)z Make this path a symlink pointing to the given path. Note the order of arguments (self, target) is the reverse of os.symlink's. N)rrrr)r$rrrrr symlink_tos  zPath.symlink_tocCsYy|jWnDtk rT}z$|jttfkr>ndSWYdd}~XnXdS)z+ Whether this path exists. FNT)rr{r|rr)r$rrrrrsz Path.existscCsbyt|jjSWnDtk r]}z$|jttfkrGndSWYdd}~XnXdS)z3 Whether this path is a directory. FN)rrst_moder{r|rr)r$rrrrrs z Path.is_dircCsbyt|jjSWnDtk r]}z$|jttfkrGndSWYdd}~XnXdS)zq Whether this path is a regular file (also True for symlinks pointing to regular files). FN)r rr>r{r|rr)r$rrrris_files z Path.is_filecCsbyt|jjSWnDtk r]}z$|jttfkrGndSWYdd}~XnXdS)z7 Whether this path is a symbolic link. FN)r rr>r{r|rr)r$rrrrrs zPath.is_symlinkcCsbyt|jjSWnDtk r]}z$|jttfkrGndSWYdd}~XnXdS)z6 Whether this path is a block device. FN)r rr>r{r|rr)r$rrrris_block_devices zPath.is_block_devicecCsbyt|jjSWnDtk r]}z$|jttfkrGndSWYdd}~XnXdS)z: Whether this path is a character device. FN)r rr>r{r|rr)r$rrrris_char_devices zPath.is_char_devicecCsbyt|jjSWnDtk r]}z$|jttfkrGndSWYdd}~XnXdS)z. Whether this path is a FIFO. FN)rrr>r{r|rr)r$rrrris_fifos z Path.is_fifocCsbyt|jjSWnDtk r]}z$|jttfkrGndSWYdd}~XnXdS)z0 Whether this path is a socket. FN)r rr>r{r|rr)r$rrrr is_sockets zPath.is_socket)z _accessorz_closedrN))r;r<r=rrrrrrrrrr rr r#r%r'rbrr,r/rr<rrrrrrrr*r=rrr?rr@rArBrCrrrrrsN                     c@seZdZfZdS)rN)r;r<r=rrrrrrs c@seZdZfZdS)rN)r;r<r=rrrrrrs )=rrr1rpr^rrr. collectionsr contextlibrr|rrroperatorrrrr r r r r rZ urllib.parserrkrrrrZgetwindowsversionr__all__r rr!r?rwrrrrrrrrrrrrrrrrrrrrrrrrrsd        4 "   ?zS  ;  'Z