File: frozenlist.pyi

package info (click to toggle)
python-aiohttp 3.5.1-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster, sid
  • size: 5,612 kB
  • sloc: python: 36,917; ansic: 15,734; makefile: 365; sh: 83
file content (54 lines) | stat: -rw-r--r-- 1,431 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
from typing import (Generic, Iterable, Iterator, List, MutableSequence,
                    Optional, TypeVar, Union, overload)

_T = TypeVar('_T')
_Arg = Union[List[_T], Iterable[_T]]


class FrozenList(MutableSequence[_T], Generic[_T]):

    def __init__(self, items: Optional[_Arg[_T]]=None) -> None: ...

    @property
    def frozen(self) -> bool: ...

    def freeze(self) -> None: ...

    @overload
    def __getitem__(self, i: int) -> _T: ...

    @overload
    def __getitem__(self, s: slice) -> FrozenList[_T]: ...

    @overload
    def __setitem__(self, i: int, o: _T) -> None: ...

    @overload
    def __setitem__(self, s: slice, o: Iterable[_T]) -> None: ...

    @overload
    def __delitem__(self, i: int) -> None: ...

    @overload
    def __delitem__(self, i: slice) -> None: ...

    def __len__(self) -> int: ...

    def __iter__(self) -> Iterator[_T]: ...

    def __reversed__(self) -> Iterator[_T]: ...

    def __eq__(self, other: object) -> bool: ...
    def __le__(self, other: FrozenList[_T]) -> bool: ...
    def __ne__(self, other: object) -> bool: ...
    def __lt__(self, other: FrozenList[_T]) -> bool: ...
    def __ge__(self, other: FrozenList[_T]) -> bool: ...
    def __gt__(self, other: FrozenList[_T]) -> bool: ...

    def insert(self, pos: int, item: _T) -> None: ...

    def __repr__(self) -> str: ...


# types for C accelerators are the same
CFrozenList = PyFrozenList = FrozenList