
    i+%                       S SK Jr  S SKrS SKrS SKrS SKJrJr  S SKJ	r	  S SK
JrJrJrJrJrJrJrJrJr  S SKJrJr  S SKJr  S SKJr  \(       aE  S S	KJrJrJr  S S
KJ r J!r!J"r"J#r#J$r$  S SK%J&r&J'r'J(r(J)r)J*r*  S SK+J,r,J-r-  \," S5      r.\" SSS9r/\" S5      r0    SS jr1    SS jr2    SS jr3    S S jr4 " S S\Rj                  5      r6\6Rn                  Rp                  (       a5  \6Rn                  Rp                  Rs                  SS5      \6Rn                  l8        \ " S S\6\Rt                  5      5       r;\ " S S\6\Rx                  5      5       r=g)!    )annotationsN)partialupdate_wrapper)cleandoc)	IOTYPE_CHECKINGAnyBinaryIOClassVarConcatenateLiteralTypeVaroverload)AsyncIOWrapper	wrap_file)final)run_sync)	AwaitableCallableIterable)BufferedRandomBufferedReaderBufferedWriterFileIOTextIOWrapper)OpenBinaryModeOpenBinaryModeReadingOpenBinaryModeUpdatingOpenBinaryModeWritingOpenTextMode)	ParamSpecSelfPPathTPath)boundTc                   ^  SU 4S jjnU$ )Nc                8  >^  SU 4S jjn[        UT5        TR                  (       ar  TR                  nUR                  SS5      nUR                  SS5      nTR                  nUR                  SS5      nSU SU S	[        TR                  5       S
3Ul        U$ )Nc                 P   >#    [        [        T/U Q70 UD65      I S h  vN $  N7fN)r   r   )argskwargsfns     7C:\des-py\RoboSAPF\venv\Lib\site-packages\trio/_path.pywrapper0_wraps_async.<locals>.decorator.<locals>.wrapper/   s&     !'"">t">v">????s   &$&zpathlib._localpathlibzpathlib._abcPathBaser%   zLike :meth:`~.z`, but async.


)r,   P.argsr-   P.kwargsreturnr'   )r   __doc__
__module__replace__qualname__r   )r.   r0   modulenamewrappeds   `   r/   	decorator_wraps_async.<locals>.decorator.   s    	@ 	w(??''F^^$4i@F^^NI>F''D<<FD
  xq /GOO,-R1 O
     )r.   zCallable[P, T]r8   zCallable[P, Awaitable[T]] )r?   r@   s   ` r/   _wraps_asyncrD   +   s    . rB   c                4   ^  [        T 5      SU 4S jj5       nU$ )Nc               :   > T" U R                  U 5      /UQ70 UD6$ r+   )_wrapped_clsselfr,   r-   r.   s      r/   r0   _wrap_method.<locals>.wrapperK   s#    $##D);D;F;;rB   )rI   r%   r,   r6   r-   r7   r8   r'   rD   r.   r0   s   ` r/   _wrap_methodrM   H   s#     "< < NrB   c                4   ^  [        T 5      SU 4S jj5       nU$ )Nc               X   > U R                  T" U R                  U 5      /UQ70 UD65      $ r+   )	__class__rG   rH   s      r/   r0   "_wrap_method_path.<locals>.wrapperU   s,    ~~b!2!24!8J4J6JKKrB   )rI   r$   r,   r6   r-   r7   r8   r$   rK   rL   s   ` r/   _wrap_method_pathrR   R   s%     "L L NrB   c                   ^  [        T 5      SU 4S jj5       nUR                  (       a#  U=R                  ST R                   S3-  sl        U$ )Nc          	     f   > [        U R                  / T" U R                  U 5      /UQ70 UD6Q5      $ r+   )maprP   rG   rH   s      r/   r0   +_wrap_method_path_iterable.<locals>.wrapper_   s4    4>>#RR(9(9$(?%Q$%Q&%Q#RSSrB   z
This is an async method that returns a synchronous iterator, so you
use it like:

.. code:: python

    for subpath in await mypath.z():
        ...

.. note::

    The iterator is loaded into memory immediately during the initial
    call (see `issue #501
    <https://github.com/python-trio/trio/issues/501>`__ for discussion).
)rI   r$   r,   r6   r-   r7   r8   zIterable[PathT])rD   r9   __name__rL   s   ` r/   _wrap_method_path_iterablerX   \   sX     "T T / 02{{m <YZ	
  NrB   c                    ^  \ rS rSr% SrSrS\S'   SU 4S jjr\\	" \
R                  R                  5      SS j5       5       r\\	" \
R                  R                  5      SS j5       5       r\     S           SS	 jj5       r\   S           SS
 jj5       r\    S           SS jj5       r\    S           SS jj5       r\    S           SS jj5       r\    S           S S jj5       r\    S           S!S jj5       r\	" \
R                  R                  5      S"S j5       rS#S jr\" \
R                  R$                  5      r\" \
R                  R&                  5      r\" \
R                  R(                  5      r\" \
R                  R,                  5      r\" \
R                  R.                  5      r\" \
R                  R0                  5      r\" \
R                  R2                  5      r\" \
R                  R4                  5      r\" \
R                  R6                  5      r\" \
R                  R8                  5      r\" \
R                  R:                  5      r\" \
R                  R<                  5      r\R@                  S:  a  \" \
R                  RB                  5      r!\" \
R                  RD                  5      r"\" \
R                  RF                  5      r#\" \
R                  RH                  5      r$\" \
R                  RJ                  5      r%\RL                  S:w  a8  \" \
R                  RN                  5      r'\" \
R                  RP                  5      r(\RL                  S:w  d  \R@                  S:  a  \" \
R                  RR                  5      r)\*" \
R                  RV                  5      r+\*" \
R                  RX                  5      r,\*" \
R                  RZ                  5      r-\*" \
R                  R\                  5      r.\" \
R                  R^                  5      r/\" \
R                  R`                  5      r0\" \
R                  Rb                  5      r1\" \
R                  Rd                  5      r2\" \
R                  Rf                  5      r3\*" \
R                  Rh                  5      r4\*" \
R                  Rj                  5      r5\" \
R                  Rl                  5      r6\" \
R                  Rn                  5      r7\" \
R                  Rp                  5      r8\" \
R                  Rr                  5      r9\" \
R                  Rt                  5      r:\R@                  S:  a  \" \
R                  Rv                  5      r;\R@                  S:  a  \" \
R                  Rx                  5      r<S#S jr=Sr>U =r?$ )$r%   w   zAn async :class:`pathlib.Path` that executes blocking methods in :meth:`trio.to_thread.run_sync`.

Instantiating :class:`Path` returns a concrete platform-specific subclass, one of :class:`PosixPath` or
:class:`WindowsPath`.
rC   ClassVar[type[pathlib.Path]]rG   c                x   > U [         L a   [        R                  S:X  a  [        O[        n [
        TU ]  " U /UQ76 $ )Nnt)r%   osr>   WindowsPath	PosixPathsuper__new__)clsr,   rP   s     r/   rb   Path.__new__   s/    $;!#D+iCws*T**rB   c                J    U " [         R                  R                  5       5      $ r+   )r2   r%   cwdrc   s    r/   rf   Path.cwd   s     7<<##%&&rB   c                J    U " [         R                  R                  5       5      $ r+   )r2   r%   homerg   s    r/   rj   	Path.home   s     7<<$$&''rB   c                   #    g 7fr+   rC   rI   mode	bufferingencodingerrorsnewlines         r/   open	Path.open   s
      ),   c                   #    g 7fr+   rC   rm   s         r/   rs   rt      s
      "%ru   c                   #    g 7fr+   rC   rm   s         r/   rs   rt      
      *-ru   c                   #    g 7fr+   rC   rm   s         r/   rs   rt      rx   ru   c                   #    g 7fr+   rC   rm   s         r/   rs   rt      rx   ru   c                   #    g 7fr+   rC   rm   s         r/   rs   rt      s
      $'ru   c                   #    g 7fr+   rC   rm   s         r/   rs   rt      s
      #&ru   c                V    [        U R                  U 5      R                  " U0 UD65      $ r+   )r   rG   rs   )rI   r,   r-   s      r/   rs   rt      s(    **4055tFvFGGrB   c                "    S[        U 5      < S3$ )Nz
trio.Path())strrI   s    r/   __repr__Path.__repr__   s    CI=**rB   )      win32)r      c                @    [         R                  R                  U 5      $ r+   )r2   r%   as_urir   s    r/   r   Path.as_uri
  s    ||""4((rB   )r,   zstr | os.PathLike[str]r8   r"   )r8   r"   )rNNN)rn   r    ro   intrp   
str | Nonerq   r   rr   r   r8   zAsyncIOWrapper[TextIOWrapper])NNN)rn   r   ro   z
Literal[0]rp   Nonerq   r   rr   r   r8   zAsyncIOWrapper[FileIO])r   NNN)rn   r   ro   Literal[-1, 1]rp   r   rq   r   rr   r   r8   zAsyncIOWrapper[BufferedRandom])rn   r   ro   r   rp   r   rq   r   rr   r   r8   zAsyncIOWrapper[BufferedWriter])rn   r   ro   r   rp   r   rq   r   rr   r   r8   zAsyncIOWrapper[BufferedReader])rn   r   ro   r   rp   r   rq   r   rr   r   r8   zAsyncIOWrapper[BinaryIO])rn   r   ro   r   rp   r   rq   r   rr   r   r8   AsyncIOWrapper[IO[Any]])r,   r	   r-   r	   r8   r   )r8   r   )@rW   r:   r<   __firstlineno__r9   	__slots____annotations__rb   classmethodrD   r2   r%   rf   rj   r   rs   r   rM   statchmodexistsrX   globrglobis_diris_file
is_symlink	is_socketis_fifois_block_deviceis_char_devicesysversion_infois_junctioniterdirlchmodlstatmkdirplatformownergroupis_mountrR   readlinkrenamer;   resolvermdir
symlink_tohardlink_totouchunlinkabsolute
expanduser
read_bytes	read_textsamefilewrite_bytes
write_textlink_to
full_matchr   __static_attributes____classcell__)rP   s   @r/   r%   r%   w   sq    I..+
 ',,""#' $ ' ',,##$( % (  !#!",, , 	,
 , , 
', , 
 %% % 	%
 % % 
 % %  %'-$- "- 	-
 - - 
(- -  %'-#- "- 	-
 - - 
(- -  %'-#- "- 	-
 - - 
(- -  '' ' 	'
 ' ' 
"' '  #!"&& & 	&
 & & 
!& & ',,##$H %H+ ))*D++,E',,--.F%gll&7&78D&w||'9'9:E',,--.F7<<//0Ggll556JW\\334I7<<//0G"7<<#?#?@O!',,"="=>N
7""7<<#;#;<()=)=>G',,--.F++,E++,E
||wW\\//0W\\//0
||w#"2"2g"= 5 56 !6!67Hw||223F 4 45G 4 45G++,Egll556Jw||778K++,E',,--.F !6!67H"7<<#:#:;Jgll556JW\\334IGLL112Hw||778Kgll556J
'!w||334
7"!',,"9"9:
) )rB   z `..` z ``..`` c                  @    \ rS rSr% SrSr\R                  rS\	S'   Sr
g)r`   i  zfAn async :class:`pathlib.PosixPath` that executes blocking methods in :meth:`trio.to_thread.run_sync`.rC   r[   rG   N)rW   r:   r<   r   r9   r   r2   r`   rG   r   r   rC   rB   r/   r`   r`     s    pI181B1BL.BrB   r`   c                  @    \ rS rSr% SrSr\R                  rS\	S'   Sr
g)r_   i  zhAn async :class:`pathlib.WindowsPath` that executes blocking methods in :meth:`trio.to_thread.run_sync`.rC   r[   rG   N)rW   r:   r<   r   r9   r   r2   r_   rG   r   r   rC   rB   r/   r_   r_     s    rI181D1DL.DrB   r_   )r?   zCallable[..., object]r8   z5Callable[[Callable[P, T]], Callable[P, Awaitable[T]]])r.   z)Callable[Concatenate[pathlib.Path, P], T]r8   z,Callable[Concatenate[Path, P], Awaitable[T]])r.   z4Callable[Concatenate[pathlib.Path, P], pathlib.Path]r8   z1Callable[Concatenate[PathT, P], Awaitable[PathT]])r.   z>Callable[Concatenate[pathlib.Path, P], Iterable[pathlib.Path]]r8   z;Callable[Concatenate[PathT, P], Awaitable[Iterable[PathT]]])>
__future__r   r^   r2   r   	functoolsr   r   inspectr   typingr   r   r	   r
   r   r   r   r   r   trio._file_ior   r   
trio._utilr   trio.to_threadr   collections.abcr   r   r   ior   r   r   r   r   	_typeshedr   r   r   r   r    typing_extensionsr!   r"   r#   r$   r'   rD   rM   rR   rX   PurePathr%   relative_tor9   r;   PurePosixPathr`   PureWindowsPathr_   rC   rB   r/   <module>r      sZ   " 	  
 - 
 
 
 4  #==XX  2#AG6*EA"::11<6F@6T)7 T)n #//77??*UD Cg++ C C E$// E ErB   