-
Notifications
You must be signed in to change notification settings - Fork 0
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
1 parent
0093340
commit 3e9af4e
Showing
3 changed files
with
91 additions
and
4 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
""" | ||
This type stub file was generated by pyright. | ||
""" | ||
|
||
from collections.abc import Callable, Iterable, Iterator | ||
from dataclasses import dataclass | ||
from typing import Generic, TypeVar, overload | ||
|
||
_T0 = TypeVar("_T0") | ||
_T1 = TypeVar("_T1") | ||
_S = TypeVar("_S") | ||
@dataclass(frozen=True) | ||
class Group(Generic[_T0]): | ||
key: str | ||
value: Seq[_T0] | ||
... | ||
|
||
|
||
class Seq(Generic[_T0]): | ||
def __init__(self, iterable: Iterable[_T0]) -> None: | ||
... | ||
|
||
def count(self) -> int: | ||
... | ||
|
||
def to_list(self) -> list[_T0]: | ||
... | ||
|
||
def to_tuple(self) -> tuple[_T0, ...]: | ||
... | ||
|
||
def to_iter(self) -> Iterator[_T0]: | ||
... | ||
|
||
def to_set(self) -> set[_T0]: | ||
... | ||
|
||
def map(self, func: Callable[[_T0], _T1]) -> Seq[_T1]: | ||
... | ||
|
||
def filter(self, func: Callable[[_T0], bool]) -> Seq[_T0]: | ||
... | ||
|
||
def reduce(self, func: Callable[[_T0, _T0], _T0]) -> _T0: | ||
... | ||
|
||
def group_by(self, func: Callable[[_T0], str]) -> Seq[Group[_T0]]: | ||
... | ||
|
||
@overload | ||
def flatten(self: Seq[list[_S]]) -> Seq[_S]: | ||
... | ||
|
||
@overload | ||
def flatten(self: Seq[tuple[_S, ...]]) -> Seq[_S]: | ||
... | ||
|
||
@overload | ||
def flatten(self: Seq[_S]) -> Seq[_S]: | ||
... | ||
|
||
|
||
|
||
|
||
|
Empty file.
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