-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
277 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,14 @@ | ||
from _typeshed import Incomplete | ||
from typing import IO, AnyStr, Generic, Literal | ||
|
||
class ContainerIO: | ||
fh: Incomplete | ||
class ContainerIO(Generic[AnyStr]): | ||
fh: IO[AnyStr] | ||
pos: int | ||
offset: Incomplete | ||
length: Incomplete | ||
def __init__(self, file, offset, length) -> None: ... | ||
def isatty(self): ... | ||
def seek(self, offset, mode=0) -> None: ... | ||
def tell(self): ... | ||
def read(self, n: int = 0): ... | ||
def readline(self): ... | ||
def readlines(self): ... | ||
offset: int | ||
length: int | ||
def __init__(self, file: IO[AnyStr], offset: int, length: int) -> None: ... | ||
def isatty(self) -> bool: ... | ||
def seek(self, offset: int, mode: Literal[0, 1, 2] = 0) -> None: ... | ||
def tell(self) -> int: ... | ||
def read(self, n: int = 0) -> AnyStr: ... | ||
def readline(self) -> AnyStr: ... | ||
def readlines(self) -> list[AnyStr]: ... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,23 @@ | ||
from _typeshed import Incomplete | ||
from typing import ClassVar, Literal | ||
from collections.abc import Iterable | ||
from typing import ClassVar, Final, Literal | ||
from typing_extensions import deprecated | ||
|
||
from ._imaging import _PixelAccessor | ||
from .ImageFile import ImageFile | ||
|
||
COMPRESSION: Incomplete | ||
PAD: Incomplete | ||
COMPRESSION: dict[int, str] | ||
PAD: Final[bytes] | ||
|
||
def i(c): ... | ||
def dump(c) -> None: ... | ||
@deprecated("Deprecated since 10.2.0") | ||
def i(c: bytes) -> int: ... | ||
@deprecated("Deprecated since 10.2.0") | ||
def dump(c: Iterable[int | bytes]) -> None: ... | ||
|
||
class IptcImageFile(ImageFile): | ||
format: ClassVar[Literal["IPTC"]] | ||
format_description: ClassVar[str] | ||
def getint(self, key): ... | ||
def field(self): ... | ||
im: Incomplete | ||
def getint(self, key: tuple[int, int]) -> int: ... | ||
def field(self) -> tuple[tuple[int, int] | None, int]: ... | ||
def load(self) -> _PixelAccessor: ... | ||
|
||
def getiptcinfo(im): ... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,12 @@ | ||
from _typeshed import Incomplete, Unused | ||
from types import TracebackType | ||
from typing_extensions import Self | ||
|
||
from .ContainerIO import ContainerIO | ||
|
||
class TarIO(ContainerIO): | ||
fh: Incomplete | ||
def __init__(self, tarfile, file) -> None: ... | ||
def __enter__(self): ... | ||
def __exit__(self, *args: Unused) -> None: ... | ||
class TarIO(ContainerIO[bytes]): | ||
def __init__(self, tarfile: str, file: str) -> None: ... | ||
def __enter__(self) -> Self: ... | ||
def __exit__( | ||
self, exc_type: type[BaseException] | None, exc_val: BaseException | None, exc_tb: TracebackType | None | ||
) -> None: ... | ||
def close(self) -> None: ... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters