
    /gEY                    6   S SK Jr  S SKrS SKrS SKrS SKJrJrJrJ	r	J
r
  S SKJr  S SKJr  S SKJr  S SKJrJrJrJrJrJrJr  SS	KJr  SS
KJr  \(       a  S SKJrJrJrJ r   O\!=r=r=rr  " S S\\\   5      r"\      S                 SS jj5       r#\       S                 SS jj5       r#       S                 SS jjr#SS jr$\" SS9 " S S\S   5      5       r% " S S5      r&\RN                  " \&5        g)    )annotationsN)AsyncIteratorCallableIterableIteratorSequence)	dataclass)partial)PathLike)IOTYPE_CHECKINGAnyAnyStrFinalGenericoverload   )	to_thread)AsyncResource)OpenBinaryModeOpenTextModeReadableBufferWriteableBufferc                  N   \ rS rSrSrSS jrSS jr\SS j5       rSS jr	SS jr
SS S jjrSS!S	 jjrS"S
 jrS#S jrS$S jrS$S jr\S%S j5       r\S&S j5       rS'S jr\      S(S j5       r\S)S j5       rS*S jrS+S,S jjr\R,                  4S-S jjrS.S jrSS jrSrg)/	AsyncFile#   au  
An asynchronous file object.

This class wraps a standard file object and provides async friendly versions of the
following blocking methods (where available on the original file object):

* read
* read1
* readline
* readlines
* readinto
* readinto1
* write
* writelines
* truncate
* seek
* tell
* flush

All other methods are directly passed through.

This class supports the asynchronous context manager protocol which closes the
underlying file at the end of the context block.

This class also supports asynchronous iteration::

    async with await open_file(...) as f:
        async for line in f:
            print(line)
c                    Xl         g N_fp)selffps     5/usr/lib/python3/dist-packages/anyio/_core/_fileio.py__init__AsyncFile.__init__C   s        c                .    [        U R                  U5      $ r   )getattrr    r!   names     r#   __getattr__AsyncFile.__getattr__F   s    txx&&r&   c                    U R                   $ )zThe wrapped file object.r   r!   s    r#   wrappedAsyncFile.wrappedI   s     xxr&   c               `   #     U R                  5       I S h  vN nU(       a  U7v   Og M(   N7fr   )readline)r!   lines     r#   	__aiter__AsyncFile.__aiter__N   s)     (D
 (s   .,.c                r   #    [         R                  " U R                  R                  5      I S h  vN $  N7fr   )r   run_syncr    closer.   s    r#   acloseAsyncFile.acloseV   $     ''7777   .757c                t   #    [         R                  " U R                  R                  U5      I S h  vN $  N7fr   )r   r7   r    readr!   sizes     r#   r>   AsyncFile.readY   s&     ''t<<<<   /868c                t   #    [         R                  " U R                  R                  U5      I S h  vN $  N7fr   )r   r7   r    read1r?   s     r#   rD   AsyncFile.read1\   s&     ''====rB   c                r   #    [         R                  " U R                  R                  5      I S h  vN $  N7fr   )r   r7   r    r2   r.   s    r#   r2   AsyncFile.readline_   s&     ''(9(9::::r<   c                r   #    [         R                  " U R                  R                  5      I S h  vN $  N7fr   )r   r7   r    	readlinesr.   s    r#   rI   AsyncFile.readlinesb   s&     ''(:(:;;;;r<   c                t   #    [         R                  " U R                  R                  U5      I S h  vN $  N7fr   )r   r7   r    readintor!   bs     r#   rL   AsyncFile.readintoe   s(     ''(9(91====rB   c                t   #    [         R                  " U R                  R                  U5      I S h  vN $  N7fr   )r   r7   r    	readinto1rM   s     r#   rQ   AsyncFile.readinto1h   s(     ''(:(:A>>>>rB   c                   #    g 7fr    rM   s     r#   writeAsyncFile.writek   s     GJ   c                   #    g 7fr   rT   rM   s     r#   rU   rV   n   s     :=rW   c                t   #    [         R                  " U R                  R                  U5      I S h  vN $  N7fr   )r   r7   r    rU   rM   s     r#   rU   rV   q   s&     ''::::rB   c                   #    g 7fr   rT   r!   liness     r#   
writelinesAsyncFile.writelinest   s
      rW   c                   #    g 7fr   rT   r[   s     r#   r]   r^   y   s     NQrW   c                t   #    [         R                  " U R                  R                  U5      I S h  vN $  N7fr   )r   r7   r    r]   r[   s     r#   r]   r^   |   s(     ''(;(;UCCCCrB   Nc                t   #    [         R                  " U R                  R                  U5      I S h  vN $  N7fr   )r   r7   r    truncater?   s     r#   rb   AsyncFile.truncate   s(     ''(9(94@@@@rB   c                t   #    [         R                  " U R                  R                  X5      I S h  vN $  N7fr   )r   r7   r    seek)r!   offsetwhences      r#   re   AsyncFile.seek   s&     ''vFFFFrB   c                r   #    [         R                  " U R                  R                  5      I S h  vN $  N7fr   )r   r7   r    tellr.   s    r#   rj   AsyncFile.tell   s$     ''6666r<   c                r   #    [         R                  " U R                  R                  5      I S h  vN $  N7fr   )r   r7   r    flushr.   s    r#   rm   AsyncFile.flush   r;   r<   r   )r"   
IO[AnyStr]returnNone)r*   strrp   object)rp   ro   )rp   zAsyncIterator[AnyStr]rp   rq   ))r@   intrp   r   )r!   AsyncFile[bytes]r@   rv   rp   bytes)rp   r   )rp   zlist[AnyStr])r!   rw   rN   r   rp   rv   )r!   rw   rN   r   rp   rv   )r!   AsyncFile[str]rN   rr   rp   rv   )rN   zReadableBuffer | strrp   rv   )r!   rw   r\   zIterable[ReadableBuffer]rp   rq   )r!   ry   r\   zIterable[str]rp   rq   )r\   z(Iterable[ReadableBuffer] | Iterable[str]rp   rq   r   )r@   
int | Nonerp   rv   )rf   rv   rg   rz   rp   rv   rp   rv   )__name__
__module____qualname____firstlineno____doc__r$   r+   propertyr/   r4   r9   r>   rD   r2   rI   rL   rQ   r   rU   r]   rb   osSEEK_SETre   rj   rm   __static_attributes__rT   r&   r#   r   r   #   s    >'  8=>;<>? J J= =; '?	  Q QDA <>;; G78r&   r   c                   #    g 7fr   rT   filemode	bufferingencodingerrorsnewlineclosefdopeners           r#   	open_filer      s
      rW   c                   #    g 7fr   rT   r   s           r#   r   r      s
      rW   c                p   #    [         R                  " [        XX#XEXg5	      I Sh  vN n[        U5      $  N7f)z
Open a file asynchronously.

The arguments are exactly the same as for the builtin :func:`open`.

:return: an asynchronous file object

N)r   r7   openr   )	r   r   r   r   r   r   r   r   r"   s	            r#   r   r      s8     $ !!d)v 
B R=
s   "646c                    [        U 5      $ )z
Wrap an existing file as an asynchronous file.

:param file: an existing file-like object
:return: an asynchronous file object

)r   )r   s    r#   	wrap_filer      s     T?r&   F)eqc                  *    \ rS rSr% S\S'   SS jrSrg)_PathIterator   zIterator[PathLike[str]]iteratorc                   #    [         R                  " [        U R                  S SS9I S h  vN nUc  [        S e[        U5      $  N7fNTabandon_on_cancel)r   r7   nextr   StopAsyncIterationPath)r!   nextvals     r#   	__anext___PathIterator.__anext__   sE     !**$--
 
 ?$$.G}
s   )AAArT   Nrp   r   )r|   r}   r~   r   __annotations__r   r   rT   r&   r#   r   r      s    %%r&   r   r   c                  P   \ rS rSr% SrSrS\S'   SfS jrSgS jrSgS jr	SgS	 jr
ShS
 jrSiS jrSjS jrSkS jrSkS jrSkS jrSkS jrSlS jrSlS jr\SmS j5       r\SgS j5       r\SgS j5       r\SgS j5       r\SnS j5       r\SoS j5       r\SgS j5       r\SgS j5       r\SpS j5       r\SgS j5       rSoS jrSgS jr SgS jr!\"RF                  S :  a=  \$RJ                  RL                  r&\'SqS! j5       r(S"S#.     SrS$ jjr)S"S#.     SrS% jjr*OSsS& jr*\"RF                  S':  a6  S(S)S)S*.         StS+ jjr+S(S)S)S*.         SuS, jjr,SvS- jr-    SwS. jr.SxS/ jr/S(S0.SyS1 jjr0\'SoS2 j5       r1SzS3 jr2SoS4 jr3S{S5 jr4SgS6 jr5    S|S7 jr6\'SoS8 j5       r7SzS9 jr8SzS: jr9SzS; jr:SzS< jr;SzS= jr<SzS> jr=\"RF                  S?:  a  SzS@ jr>SzSA jr?SzSB jr@SzSC jrASzSD jrBS}SE jrCS~SF jrDSSG jrESSH jrF S       SSI jjrG\H    S           SSJ jj5       rI\H     S           SSK jj5       rI     S           SSL jjrISgSM jrJShSN jrK S     SSO jjrL\"RF                  S?:  a  S)SP.     SSQ jjrMOSlSR jrMSoSS jrNSST jrOSSU jrPSSSV jjrQS{SW jrRSSX jrSSSY jrTS(S0.SSZ jjrU S     SS[ jjrVSSS\ jjrWSSS] jjrX\"RF                  S?:  a     S       SS^ jjrYSS_ jrZSS` jr[SSa jr\SSb jr]SSc jr^   S         SSd jjr_Ser`g")r      ad
  
An asynchronous version of :class:`pathlib.Path`.

This class cannot be substituted for :class:`pathlib.Path` or
:class:`pathlib.PurePath`, but it is compatible with the :class:`os.PathLike`
interface.

It implements the Python 3.10 version of :class:`pathlib.Path` interface, except for
the deprecated :meth:`~pathlib.Path.link_to` method.

Some methods may be unavailable or have limited functionality, based on the Python
version:

* :meth:`~pathlib.Path.copy` (available on Python 3.14 or later)
* :meth:`~pathlib.Path.copy_into` (available on Python 3.14 or later)
* :meth:`~pathlib.Path.from_uri` (available on Python 3.13 or later)
* :meth:`~pathlib.Path.full_match` (available on Python 3.13 or later)
* :meth:`~pathlib.Path.is_junction` (available on Python 3.12 or later)
* :meth:`~pathlib.Path.match` (the ``case_sensitive`` paramater is only available on
  Python 3.13 or later)
* :meth:`~pathlib.Path.move` (available on Python 3.14 or later)
* :meth:`~pathlib.Path.move_into` (available on Python 3.14 or later)
* :meth:`~pathlib.Path.relative_to` (the ``walk_up`` parameter is only available on
  Python 3.12 or later)
* :meth:`~pathlib.Path.walk` (available on Python 3.12 or later)

Any methods that do disk I/O need to be awaited on. These methods are:

* :meth:`~pathlib.Path.absolute`
* :meth:`~pathlib.Path.chmod`
* :meth:`~pathlib.Path.cwd`
* :meth:`~pathlib.Path.exists`
* :meth:`~pathlib.Path.expanduser`
* :meth:`~pathlib.Path.group`
* :meth:`~pathlib.Path.hardlink_to`
* :meth:`~pathlib.Path.home`
* :meth:`~pathlib.Path.is_block_device`
* :meth:`~pathlib.Path.is_char_device`
* :meth:`~pathlib.Path.is_dir`
* :meth:`~pathlib.Path.is_fifo`
* :meth:`~pathlib.Path.is_file`
* :meth:`~pathlib.Path.is_junction`
* :meth:`~pathlib.Path.is_mount`
* :meth:`~pathlib.Path.is_socket`
* :meth:`~pathlib.Path.is_symlink`
* :meth:`~pathlib.Path.lchmod`
* :meth:`~pathlib.Path.lstat`
* :meth:`~pathlib.Path.mkdir`
* :meth:`~pathlib.Path.open`
* :meth:`~pathlib.Path.owner`
* :meth:`~pathlib.Path.read_bytes`
* :meth:`~pathlib.Path.read_text`
* :meth:`~pathlib.Path.readlink`
* :meth:`~pathlib.Path.rename`
* :meth:`~pathlib.Path.replace`
* :meth:`~pathlib.Path.resolve`
* :meth:`~pathlib.Path.rmdir`
* :meth:`~pathlib.Path.samefile`
* :meth:`~pathlib.Path.stat`
* :meth:`~pathlib.Path.symlink_to`
* :meth:`~pathlib.Path.touch`
* :meth:`~pathlib.Path.unlink`
* :meth:`~pathlib.Path.walk`
* :meth:`~pathlib.Path.write_bytes`
* :meth:`~pathlib.Path.write_text`

Additionally, the following methods return an async iterator yielding
:class:`~.Path` objects:

* :meth:`~pathlib.Path.glob`
* :meth:`~pathlib.Path.iterdir`
* :meth:`~pathlib.Path.rglob`
)_path__weakref__r   r   c                4    [         R                  " U6 U l        g r   )pathlibr   r   r!   argss     r#   r$   Path.__init__&  s    *1,,*=
r&   c                6    U R                   R                  5       $ r   )r   
__fspath__r.   s    r#   r   Path.__fspath__)  s    zz$$&&r&   c                6    U R                   R                  5       $ r   )r   __str__r.   s    r#   r   Path.__str__,  s    zz!!##r&   c                X    U R                   R                   SU R                  5       < S3$ )N())	__class__r|   as_posixr.   s    r#   __repr__Path.__repr__/  s'    ..))*!DMMO+>a@@r&   c                6    U R                   R                  5       $ r   )r   	__bytes__r.   s    r#   r   Path.__bytes__2  s    zz##%%r&   c                6    U R                   R                  5       $ r   )r   __hash__r.   s    r#   r   Path.__hash__5      zz""$$r&   c                ~    [        U[        5      (       a  UR                  OUnU R                  R                  U5      $ r   )
isinstancer   r   __eq__r!   othertargets      r#   r   Path.__eq__8  .     *5$ 7 7Uzz  ((r&   c                ~    [        U[        5      (       a  UR                  OUnU R                  R                  U5      $ r   )r   r   r   __lt__r   s      r#   r   Path.__lt__<  r   r&   c                ~    [        U[        5      (       a  UR                  OUnU R                  R                  U5      $ r   )r   r   r   __le__r   s      r#   r   Path.__le__@  r   r&   c                ~    [        U[        5      (       a  UR                  OUnU R                  R                  U5      $ r   )r   r   r   __gt__r   s      r#   r   Path.__gt__D  r   r&   c                ~    [        U[        5      (       a  UR                  OUnU R                  R                  U5      $ r   )r   r   r   __ge__r   s      r#   r   Path.__ge__H  r   r&   c                2    [        U R                  U-  5      $ r   )r   r   r!   r   s     r#   __truediv__Path.__truediv__L  s    DJJ&''r&   c                    [        U5      U -  $ r   r   r   s     r#   __rtruediv__Path.__rtruediv__O  s    E{T!!r&   c                .    U R                   R                  $ r   )r   partsr.   s    r#   r   
Path.partsR      zzr&   c                .    U R                   R                  $ r   )r   driver.   s    r#   r   
Path.driveV  r   r&   c                .    U R                   R                  $ r   )r   rootr.   s    r#   r   	Path.rootZ      zzr&   c                .    U R                   R                  $ r   )r   anchorr.   s    r#   r   Path.anchor^      zz   r&   c                N    [        S U R                  R                   5       5      $ )Nc              3  8   #    U  H  n[        U5      v   M     g 7fr   r   ).0ps     r#   	<genexpr>Path.parents.<locals>.<genexpr>d  s     9&8T!WW&8s   )tupler   parentsr.   s    r#   r   Path.parentsb  s    9djj&8&8999r&   c                @    [        U R                  R                  5      $ r   )r   r   parentr.   s    r#   r   Path.parentf  s    DJJ%%&&r&   c                .    U R                   R                  $ r   )r   r*   r.   s    r#   r*   	Path.namej  r   r&   c                .    U R                   R                  $ r   )r   suffixr.   s    r#   r   Path.suffixn  r   r&   c                .    U R                   R                  $ r   )r   suffixesr.   s    r#   r   Path.suffixesr  s    zz"""r&   c                .    U R                   R                  $ r   )r   stemr.   s    r#   r  	Path.stemv  r   r&   c                   #    [         R                  " U R                  R                  5      I S h  vN n[	        U5      $  N7fr   )r   r7   r   absoluter   )r!   paths     r#   r  Path.absolutez  s1     ''

(;(;<<Dz =s   .AA Ac                6    U R                   R                  5       $ r   )r   r   r.   s    r#   r   Path.as_posix~  r   r&   c                6    U R                   R                  5       $ r   )r   as_urir.   s    r#   r  Path.as_uri  s    zz  ""r&   )      c                R    [        [        R                   R                  U5      5      $ r   )r   r   from_uri)clsuris     r#   r  Path.from_uri  s    --c233r&   Ncase_sensitivec               4    U R                   R                  XS9$ Nr  )r   
full_matchr!   path_patternr  s      r#   r  Path.full_match  s     ::(((UUr&   c               4    U R                   R                  XS9$ r  r   matchr  s      r#   r  
Path.match  s     ::##L#PPr&   c                8    U R                   R                  U5      $ r   r  )r!   r  s     r#   r  r     s    ::##L11r&   )r     TFfollow_symlinksdirs_exist_okpreserve_metadatac                  #    [        U R                  R                  UUUS9n[        [        R
                  " XQ5      I S h  vN 5      $  N7fNr#  )r
   r   copyr   r   r7   )r!   r   r$  r%  r&  funcs         r#   r)  	Path.copy  sC      

 /+"3	D i00>>??>   ?AA
	Ac                  #    [        U R                  R                  UUUS9n[        [        R
                  " XQ5      I S h  vN 5      $  N7fr(  )r
   r   	copy_intor   r   r7   )r!   
target_dirr$  r%  r&  r*  s         r#   r.  Path.copy_into  sE      

$$ /+"3	D i00BBCCBr,  c                   #    [         R                  " U5      n[        [        R                  " U R                  R
                  U5      I S h  vN 5      $  N7fr   )r   r   r   r7   r   mover!   r   s     r#   r2  	Path.move  s9     \\&)Fi00&IIJJIs   A
AA	Ac                   #    [        [        R                  " U R                  R                  U5      I S h  vN 5      $  N7fr   )r   r   r7   r   	move_into)r!   r/  s     r#   r6  Path.move_into  s/      i001E1EzRRSSRs   4A?	Ac                H     U R                  U5        g! [         a     gf = f)NTF)relative_to
ValueErrorr   s     r#   is_relative_toPath.is_relative_to  s*    	U# 		s    
!!r$  c                  #    [        [        R                  US9n[        R                  " X0R
                  U5      I S h  vN $  N7f)Nr=  )r
   r   chmodr   r7   r   )r!   r   r$  r*  s       r#   r?  
Path.chmod  s2     rxxA''jj$????s   =AA Ac                   #    [         R                  " [        R                  R                  5      I S h  vN nU " U5      $  N7fr   )r   r7   r   r   cwd)r  r  s     r#   rB  Path.cwd  s1     ''(8(8994y :   2AAAc                p   #    [         R                  " U R                  R                  SS9I S h  vN $  N7fr   )r   r7   r   existsr.   s    r#   rF  Path.exists  (     ''

(9(9TRRRR   -646c                   #    [        [        R                  " U R                  R                  SS9I S h  vN 5      $  N7fr   )r   r   r7   r   
expanduserr.   s    r#   rK  Path.expanduser  s2     $$TZZ%:%:dSS
 	
Ss   2?=	?c                N    U R                   R                  U5      n[        U5      $ r   )r   globr   r!   patterngens      r#   rN  	Path.glob  s    jjoog&S!!r&   c                p   #    [         R                  " U R                  R                  SS9I S h  vN $  N7fr   )r   r7   r   groupr.   s    r#   rT  
Path.group  (     ''

(8(8DQQQQrI  c                   #    [        U[        5      (       a  UR                  n[        R                  " [
        R                  X5      I S h  vN   g  N7fr   )r   r   r   r   r7   r   linkr3  s     r#   hardlink_toPath.hardlink_to  s7      fd##\\F  &777s   A
AAAc                   #    [         R                  " [        R                  R                  5      I S h  vN nU " U5      $  N7fr   )r   r7   r   r   home)r  	home_paths     r#   r\  	Path.home  s2     #,,W\\->->??	9~ @rD  c                6    U R                   R                  5       $ r   )r   is_absoluter.   s    r#   r`  Path.is_absolute      zz%%''r&   c                p   #    [         R                  " U R                  R                  SS9I S h  vN $  N7fr   )r   r7   r   is_block_devicer.   s    r#   rd  Path.is_block_device  s1     ''JJ&&$
 
 	
 
rI  c                p   #    [         R                  " U R                  R                  SS9I S h  vN $  N7fr   )r   r7   r   is_char_devicer.   s    r#   rg  Path.is_char_device  s1     ''JJ%%
 
 	
 
rI  c                p   #    [         R                  " U R                  R                  SS9I S h  vN $  N7fr   )r   r7   r   is_dirr.   s    r#   rj  Path.is_dir  rH  rI  c                p   #    [         R                  " U R                  R                  SS9I S h  vN $  N7fr   )r   r7   r   is_fifor.   s    r#   rm  Path.is_fifo  (     ''

(:(:dSSSSrI  c                p   #    [         R                  " U R                  R                  SS9I S h  vN $  N7fr   )r   r7   r   is_filer.   s    r#   rq  Path.is_file  ro  rI  )r     c                r   #    [         R                  " U R                  R                  5      I S h  vN $  N7fr   )r   r7   r   is_junctionr.   s    r#   ru  Path.is_junction
  s&     "++DJJ,B,BCCCCr<   c                   #    [         R                  " [        R                  R                  U R
                  SS9I S h  vN $  N7fr   )r   r7   r   r  ismountr   r.   s    r#   is_mountPath.is_mount  s5     ''GGOOTZZ4
 
 	
 
s   <AAAc                6    U R                   R                  5       $ r   )r   is_reservedr.   s    r#   r|  Path.is_reserved  rb  r&   c                p   #    [         R                  " U R                  R                  SS9I S h  vN $  N7fr   )r   r7   r   	is_socketr.   s    r#   r  Path.is_socket  s)     ''

(<(<PTUUUUrI  c                p   #    [         R                  " U R                  R                  SS9I S h  vN $  N7fr   )r   r7   r   
is_symlinkr.   s    r#   r  Path.is_symlink  s)     ''

(=(=QUVVVVrI  c                L    U R                   R                  5       n[        U5      $ r   )r   iterdirr   )r!   rQ  s     r#   r  Path.iterdir  s    jj  "S!!r&   c                F    [        U R                  R                  " U6 5      $ r   )r   r   joinpathr   s     r#   r  Path.joinpath  s    DJJ''.//r&   c                v   #    [         R                  " U R                  R                  U5      I S h  vN   g  N7fr   )r   r7   r   lchmod)r!   r   s     r#   r  Path.lchmod"  s%       !2!2D999   /979c                p   #    [         R                  " U R                  R                  SS9I S h  vN $  N7fr   )r   r7   r   lstatr.   s    r#   r  
Path.lstat%  rV  rI  c                x   #    [         R                  " U R                  R                  XU5      I S h  vN   g  N7fr   )r   r7   r   mkdir)r!   r   r   exist_oks       r#   r  
Path.mkdir(  s)        !1!14(KKKs   0:8:c                   #    g 7fr   rT   r!   r   r   r   r   r   s         r#   r   	Path.open-  s
      rW   c                   #    g 7fr   rT   r  s         r#   r   r  7  s
      rW   c                   #    [         R                  " U R                  R                  XX4U5      I S h  vN n[	        U5      $  N7fr   )r   r7   r   r   r   )r!   r   r   r   r   r   r"   s          r#   r   r  A  s>      %%JJOOTh
 
 }
s   1AAAc                p   #    [         R                  " U R                  R                  SS9I S h  vN $  N7fr   )r   r7   r   ownerr.   s    r#   r  
Path.ownerN  rV  rI  c                r   #    [         R                  " U R                  R                  5      I S h  vN $  N7fr   )r   r7   r   
read_bytesr.   s    r#   r  Path.read_bytesQ  s&     ''

(=(=>>>>r<   c                t   #    [         R                  " U R                  R                  X5      I S h  vN $  N7fr   )r   r7   r   	read_text)r!   r   r   s      r#   r  Path.read_textT  s*      ''

(<(<hOOOOrB   )walk_upc               L    [        U R                  R                  " USU065      $ )Nr  r   r   r9  )r!   r  r   s      r#   r9  Path.relative_to[  s#     

..GwGHHr&   c                F    [        U R                  R                  " U6 5      $ r   r  r   s     r#   r9  r  b  s    

..677r&   c                   #    [         R                  " [        R                  U R                  5      I S h  vN n[        U5      $  N7fr   )r   r7   r   readlinkr   r   r3  s     r#   r  Path.readlinke  s2      ))"++tzzBBF| Cs   3AAAc                   #    [        U[        5      (       a  UR                  n[        R                  " U R                  R
                  U5      I S h  vN   [        U5      $  N7fr   )r   r   r   r   r7   renamer3  s     r#   r  Path.renamei  sJ     fd##\\F  !2!2F;;;F| 	<   AA$A"A$c                   #    [        U[        5      (       a  UR                  n[        R                  " U R                  R
                  U5      I S h  vN   [        U5      $  N7fr   )r   r   r   r   r7   replacer3  s     r#   r  Path.replacep  sJ     fd##\\F  !3!3V<<<F| 	=r  c                   #    [        U R                  R                  US9n[        [        R
                  " USS9I S h  vN 5      $  N7f)N)strictTr   )r
   r   resolver   r   r7   )r!   r  r*  s      r#   r  Path.resolvew  s9     tzz))&9),,TTJJKKJs   <A	A	A	c                N    U R                   R                  U5      n[        U5      $ r   )r   rglobr   rO  s      r#   r  
Path.rglob{  s!    jjw'S!!r&   c                t   #    [         R                  " U R                  R                  5      I S h  vN   g  N7fr   )r   r7   r   rmdirr.   s    r#   r  
Path.rmdir  s#       !1!1222s   .868c                   #    [        U[        5      (       a  UR                  n[        R                  " U R                  R
                  USS9I S h  vN $  N7fr   )r   r   r   r   r7   samefile)r!   
other_paths     r#   r  Path.samefile  sK     j$''#))J''JJt
 
 	
 
s   AAAAc                  #    [        [        R                  US9n[        R                  " X R
                  SS9I S h  vN $  N7f)Nr=  Tr   )r
   r   statr   r7   r   )r!   r$  r*  s      r#   r  	Path.stat  s2     rww@''jjDQQQQs   ;AAAc                   #    [        U[        5      (       a  UR                  n[        R                  " U R                  R
                  X5      I S h  vN   g  N7fr   )r   r   r   r   r7   
symlink_to)r!   r   target_is_directorys      r#   r  Path.symlink_to  s=     
 fd##\\F  !6!6TTTs   AAAAc                v   #    [         R                  " U R                  R                  X5      I S h  vN   g  N7fr   )r   r7   r   touch)r!   r   r  s      r#   r  
Path.touch  s%       !1!14BBBr  c                   #     [         R                  " U R                  R                  5      I S h  vN   g  N! [         a    U(       d  e  g f = f7fr   )r   r7   r   unlinkFileNotFoundError)r!   
missing_oks     r#   r  Path.unlink  sA     	$$TZZ%6%6777  	 	s1   A-9 79 A9 AAAAc                  ^	#    SU	4S jjnU R                   R                  XU5      m	 [        R                  " U5      I S h  vN nUc  g Uu  pgn[	        U5      Xx47v   M9   N7f)Nc                 <   >  [        T 5      $ ! [         a     g f = fr   )r   StopIteration)rQ  s   r#   get_next_value!Path.walk.<locals>.get_next_value  s$     9$$   s   
 
)rp   z0tuple[pathlib.Path, list[str], list[str]] | None)r   walkr   r7   r   )
r!   top_downon_errorr$  r  valuer   dirspathsrQ  s
            @r#   r  	Path.walk  s`       **//(oFC'00@@=$)!E4j$-- @s   ?A$A" A$c                J    [        U R                  R                  U5      5      $ r   )r   r   	with_namer)   s     r#   r  Path.with_name  s    DJJ((.//r&   c                v    [        U R                  R                  XR                  R                  -   5      5      $ r   )r   r   r  r   )r!   r  s     r#   	with_stemPath.with_stem  s)    DJJ((

0A0A)ABCCr&   c                J    [        U R                  R                  U5      5      $ r   )r   r   with_suffix)r!   r   s     r#   r  Path.with_suffix  s    DJJ**6233r&   c                    [        U6 $ r   r   )r!   pathsegmentss     r#   with_segmentsPath.with_segments  s    \""r&   c                t   #    [         R                  " U R                  R                  U5      I S h  vN $  N7fr   )r   r7   r   write_bytes)r!   datas     r#   r  Path.write_bytes  s(     ''

(>(>EEEErB   c                l   ^ ^^^^#    SUUUUU 4S jjn[         R                  " U5      I S h  vN $  N7f)Nc                    > TR                   R                  STTTS9 n U R                  T5      sS S S 5        $ ! , (       d  f       g = f)Nw)r   r   r   )r   r   rU   )r"   r  r   r   r   r!   s    r#   sync_write_text(Path.write_text.<locals>.sync_write_text  s?    hvw ! xx~  s	   9
Ar{   )r   r7   )r!   r  r   r   r   r  s   ````` r#   
write_textPath.write_text  s)     	& 	& ''8888s   &424)r   )r   str | PathLike[str]rp   rq   )rp   rr   )rp   rx   r{   )r   rs   rp   bool)r   zpathlib.PurePath | Pathrp   r  )r   r  rp   r   )rp   ztuple[str, ...])rp   zSequence[Path]r   )rp   z	list[str])r  rr   rp   r   )r  rr   r  zbool | Nonerp   r  )r  rr   rp   r  )
r   str | os.PathLike[str]r$  r  r%  r  r&  r  rp   r   )
r/  r  r$  r  r%  r  r&  r  rp   r   )r   r  rp   r   )r/  r  rp   r   )r   r  rp   r  )r   rv   r$  r  rp   rq   )rp   r  )rP  rr   rp   AsyncIterator[Path])r   -str | bytes | PathLike[str] | PathLike[bytes]rp   rq   )rp   r  )r   r  rp   r   )r   rv   rp   rq   )rp   os.stat_result)i  FF)r   rv   r   r  r  r  rp   rq   )....)r   r   r   rv   r   
str | Noner   r  r   r  rp   rw   ).....)r   r   r   rv   r   r  r   r  r   r  rp   ry   )rru   NNN)r   rr   r   rv   r   r  r   r  r   r  rp   AsyncFile[Any])NN)r   r  r   r  rp   rr   )r   r  r  r  rp   r   )r   zstr | pathlib.PurePath | Pathrp   r   )F)r  r  rp   r   rt   )r  r  rp   r  )r$  r  rp   r  )r   r  r  r  rp   rq   )i  T)r   rv   r  r  rp   rq   )r  r  rp   rq   )TNF)r  r  r  z"Callable[[OSError], object] | Noner$  r  rp   z0AsyncIterator[tuple[Path, list[str], list[str]]])r*   rr   rp   r   )r  rr   rp   r   )r   rr   rp   r   )r  r  rp   r   )r  rx   rp   rv   )NNN)
r  rr   r   r  r   r  r   r  rp   rv   )ar|   r}   r~   r   r   	__slots__r   r$   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r*   r   r   r  r  r   r  sysversion_infor   r   parserclassmethodr  r  r  r)  r.  r2  r6  r;  r?  rB  rF  rK  rN  rT  rY  r\  r`  rd  rg  rj  rm  rq  ru  ry  r|  r  r  r  r  r  r  r  r   r   r  r  r  r9  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r   rT   r&   r#   r   r      s   HT 'I>'$A&%)))))("           ! ! : : ' '   ! ! # #  %# 7"$$		4 
	4 GK	V #	V8C	V	V GK	Q #	Q8C	Q	Q	2 7" %)"'&+	@*	@ "		@
  	@  $	@ 	@( %)"'&+	D.	D "		D
  	D  $	D 	D 	K
	T.	T 	T AE @  S

"R8C8	8  (



STT 7"	D

(VW"0:R JOLL*.LBFL	L
  " !  	
   
   !" !  	
   
  #!"  	
   
R? AEP"P3=P	P
 7" @E	I-	I8<	I	I	8L"3
 59 R %*U=U "U 
	UC 7" ";?$)		.	. 9	. "		.
 >	.*0D4#F  $!"99 9 	9
 9 
9 9r&   )......)r   str | PathLike[str] | intr   r   r   rv   r   r  r   r  r   r  r   r  r    Callable[[str, int], int] | Nonerp   rw   ).......)r   r  r   r   r   rv   r   r  r   r  r   r  r   r  r   r  rp   ry   )r  ru   NNNTN)r   r  r   rr   r   rv   r   r  r   r  r   r  r   r  r   r  rp   r  )r   ro   rp   zAsyncFile[AnyStr])(
__future__r   r   r   r  collections.abcr   r   r   r   r   dataclassesr	   	functoolsr
   r   typingr   r   r   r   r   r   r    r   abcr   	_typeshedr   r   r   r   rs   r   r   r   r   r   registerrT   r&   r#   <module>r     s'   " 	  
  "      WWGMMNM^Ml_f8wv f8R 
 /2	
#	
	 	 		
 	 	 	 -	 	 
	 
 /2	
#	
	 	 		
 	 	 	 -	 	 
	 /3
#
  	
    - 0 e
M&) 
 
9 9D 	  $ r&   