|
1 | 1 | from _typeshed import SupportsWrite |
2 | 2 | from array import array |
3 | | -from collections.abc import Callable, Sequence |
| 3 | +from collections.abc import Callable, Generator, Sequence |
4 | 4 | from typing import Any, Final, Literal, overload |
5 | 5 |
|
6 | 6 | from .biffh import * |
@@ -43,10 +43,10 @@ ctype_text: Final[dict[int, str]] |
43 | 43 |
|
44 | 44 | class Cell(BaseObject): |
45 | 45 | __slots__ = ["ctype", "value", "xf_index"] |
46 | | - ctype: int |
47 | | - value: str |
| 46 | + ctype: Literal[0, 1, 2, 3, 4, 5, 6] |
| 47 | + value: str | float |
48 | 48 | xf_index: int | None |
49 | | - def __init__(self, ctype: int, value: str, xf_index: int | None = None) -> None: ... |
| 49 | + def __init__(self, ctype: Literal[0, 1, 2, 3, 4, 5, 6], value: str, xf_index: int | None = None) -> None: ... |
50 | 50 |
|
51 | 51 | empty_cell: Final[Cell] |
52 | 52 |
|
@@ -147,7 +147,7 @@ class Sheet(BaseObject): |
147 | 147 | def __getitem__(self, item: int) -> list[Cell]: ... |
148 | 148 | @overload |
149 | 149 | def __getitem__(self, item: tuple[int, int]) -> Cell: ... |
150 | | - def get_rows(self) -> tuple[list[Cell], ...]: ... |
| 150 | + def get_rows(self) -> Generator[list[Cell]]: ... |
151 | 151 | __iter__ = get_rows |
152 | 152 | def row_types(self, rowx: int, start_colx: int = 0, end_colx: int | None = None) -> Sequence[int]: ... |
153 | 153 | def row_values(self, rowx: int, start_colx: int = 0, end_colx: int | None = None) -> Sequence[str]: ... |
|
0 commit comments