massive update, probably broken
[dotfiles/.git] / .config / coc / extensions / node_modules / coc-pyright / node_modules / pyright / dist / typeshed-fallback / stubs / aiofiles / aiofiles / os.pyi
1 import sys
2 from _typeshed import StrOrBytesPath
3 from os import stat_result
4 from typing import Sequence, Union, overload
5
6 _FdOrAnyPath = Union[int, StrOrBytesPath]
7
8 async def stat(path: _FdOrAnyPath, *, dir_fd: int | None = ..., follow_symlinks: bool = ...) -> stat_result: ...
9 async def rename(
10     src: StrOrBytesPath, dst: StrOrBytesPath, *, src_dir_fd: int | None = ..., dst_dir_fd: int | None = ...
11 ) -> None: ...
12 async def remove(path: StrOrBytesPath, *, dir_fd: int | None = ...) -> None: ...
13 async def mkdir(path: StrOrBytesPath, mode: int = ..., *, dir_fd: int | None = ...) -> None: ...
14 async def rmdir(path: StrOrBytesPath, *, dir_fd: int | None = ...) -> None: ...
15
16 if sys.platform != "win32":
17     @overload
18     async def sendfile(__out_fd: int, __in_fd: int, offset: int | None, count: int) -> int: ...
19     @overload
20     async def sendfile(
21         __out_fd: int,
22         __in_fd: int,
23         offset: int,
24         count: int,
25         headers: Sequence[bytes] = ...,
26         trailers: Sequence[bytes] = ...,
27         flags: int = ...,
28     ) -> int: ...