| 1 | from _typeshed import ReadableBuffer, SupportsNoArgReadline, SupportsRead, SupportsWrite |
| 2 | from typing import Protocol, type_check_only |
| 3 | |
| 4 | __all__ = ["encode", "decode", "encodestring", "decodestring"] |
| 5 | |
| 6 | @type_check_only |
| 7 | class _Input(SupportsRead[bytes], SupportsNoArgReadline[bytes], Protocol): ... |
| 8 | |
| 9 | def encode(input: _Input, output: SupportsWrite[bytes], quotetabs: int, header: bool = False) -> None: ... |
| 10 | def encodestring(s: ReadableBuffer, quotetabs: bool = False, header: bool = False) -> bytes: ... |
| 11 | def decode(input: _Input, output: SupportsWrite[bytes], header: bool = False) -> None: ... |
| 12 | def decodestring(s: str | ReadableBuffer, header: bool = False) -> bytes: ... |