mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-20 19:01:15 +08:00
quopri: improve types (#9074)
This commit is contained in:
@@ -1,8 +1,11 @@
|
||||
from typing import BinaryIO
|
||||
from _typeshed import ReadableBuffer, SupportsNoArgReadline, SupportsRead, SupportsWrite
|
||||
from typing import Protocol
|
||||
|
||||
__all__ = ["encode", "decode", "encodestring", "decodestring"]
|
||||
|
||||
def encode(input: BinaryIO, output: BinaryIO, quotetabs: int, header: int = ...) -> None: ...
|
||||
def encodestring(s: bytes, quotetabs: int = ..., header: int = ...) -> bytes: ...
|
||||
def decode(input: BinaryIO, output: BinaryIO, header: int = ...) -> None: ...
|
||||
def decodestring(s: bytes, header: int = ...) -> bytes: ...
|
||||
class _Input(SupportsRead[bytes], SupportsNoArgReadline[bytes], Protocol): ...
|
||||
|
||||
def encode(input: _Input, output: SupportsWrite[bytes], quotetabs: int, header: int = ...) -> None: ...
|
||||
def encodestring(s: ReadableBuffer, quotetabs: int = ..., header: int = ...) -> bytes: ...
|
||||
def decode(input: _Input, output: SupportsWrite[bytes], header: int = ...) -> None: ...
|
||||
def decodestring(s: str | ReadableBuffer, header: int = ...) -> bytes: ...
|
||||
|
||||
Reference in New Issue
Block a user