-
-
Notifications
You must be signed in to change notification settings - Fork 3.2k
Expand file tree
/
Copy pathdemo.pyi
More file actions
143 lines (121 loc) · 5.31 KB
/
demo.pyi
File metadata and controls
143 lines (121 loc) · 5.31 KB
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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
import enum
import typing
from typing import Callable, ClassVar, overload
PI: float
__version__: str
class Color(enum.Enum):
"""Color Enum"""
__new__: ClassVar[Callable] = ...
GREEN = 1
RED = 0
class Point:
class AngleUnit:
"""Members:
radian
degree"""
__members__: ClassVar[dict] = ... # read-only
__entries: ClassVar[dict] = ...
degree: ClassVar[Point.AngleUnit] = ...
radian: ClassVar[Point.AngleUnit] = ...
def __init__(self, value: typing.SupportsInt) -> None:
"""__init__(self: pybind11_fixtures.demo.Point.AngleUnit, value: typing.SupportsInt) -> None"""
def __eq__(self, other: object) -> bool:
"""__eq__(self: object, other: object, /) -> bool"""
def __hash__(self) -> int:
"""__hash__(self: object, /) -> int"""
def __index__(self) -> int:
"""__index__(self: pybind11_fixtures.demo.Point.AngleUnit, /) -> int"""
def __int__(self) -> int:
"""__int__(self: pybind11_fixtures.demo.Point.AngleUnit, /) -> int"""
def __ne__(self, other: object) -> bool:
"""__ne__(self: object, other: object, /) -> bool"""
@property
def name(self) -> str:
"""name(self: object, /) -> str
name(self: object, /) -> str
"""
@property
def value(self) -> int:
"""(arg0: pybind11_fixtures.demo.Point.AngleUnit) -> int"""
class LengthUnit:
"""Members:
mm
pixel
inch"""
__members__: ClassVar[dict] = ... # read-only
__entries: ClassVar[dict] = ...
inch: ClassVar[Point.LengthUnit] = ...
mm: ClassVar[Point.LengthUnit] = ...
pixel: ClassVar[Point.LengthUnit] = ...
def __init__(self, value: typing.SupportsInt) -> None:
"""__init__(self: pybind11_fixtures.demo.Point.LengthUnit, value: typing.SupportsInt) -> None"""
def __eq__(self, other: object) -> bool:
"""__eq__(self: object, other: object, /) -> bool"""
def __hash__(self) -> int:
"""__hash__(self: object, /) -> int"""
def __index__(self) -> int:
"""__index__(self: pybind11_fixtures.demo.Point.LengthUnit, /) -> int"""
def __int__(self) -> int:
"""__int__(self: pybind11_fixtures.demo.Point.LengthUnit, /) -> int"""
def __ne__(self, other: object) -> bool:
"""__ne__(self: object, other: object, /) -> bool"""
@property
def name(self) -> str:
"""name(self: object, /) -> str
name(self: object, /) -> str
"""
@property
def value(self) -> int:
"""(arg0: pybind11_fixtures.demo.Point.LengthUnit) -> int"""
angle_unit: ClassVar[Point.AngleUnit] = ...
length_unit: ClassVar[Point.LengthUnit] = ...
x_axis: ClassVar[Point] = ... # read-only
y_axis: ClassVar[Point] = ... # read-only
origin: ClassVar[Point] = ...
x: float
y: float
@overload
def __init__(self) -> None:
"""__init__(*args, **kwargs)
Overloaded function.
1. __init__(self: pybind11_fixtures.demo.Point) -> None
2. __init__(self: pybind11_fixtures.demo.Point, x: typing.SupportsFloat, y: typing.SupportsFloat) -> None
"""
@overload
def __init__(self, x: typing.SupportsFloat, y: typing.SupportsFloat) -> None:
"""__init__(*args, **kwargs)
Overloaded function.
1. __init__(self: pybind11_fixtures.demo.Point) -> None
2. __init__(self: pybind11_fixtures.demo.Point, x: typing.SupportsFloat, y: typing.SupportsFloat) -> None
"""
def as_list(self) -> list[float]:
"""as_list(self: pybind11_fixtures.demo.Point) -> list[float]"""
@overload
def distance_to(self, x: typing.SupportsFloat, y: typing.SupportsFloat) -> float:
"""distance_to(*args, **kwargs)
Overloaded function.
1. distance_to(self: pybind11_fixtures.demo.Point, x: typing.SupportsFloat, y: typing.SupportsFloat) -> float
2. distance_to(self: pybind11_fixtures.demo.Point, other: pybind11_fixtures.demo.Point) -> float
"""
@overload
def distance_to(self, other: Point) -> float:
"""distance_to(*args, **kwargs)
Overloaded function.
1. distance_to(self: pybind11_fixtures.demo.Point, x: typing.SupportsFloat, y: typing.SupportsFloat) -> float
2. distance_to(self: pybind11_fixtures.demo.Point, other: pybind11_fixtures.demo.Point) -> float
"""
@property
def length(self) -> float:
"""(arg0: pybind11_fixtures.demo.Point) -> float"""
def answer() -> int:
'''answer() -> int
answer docstring, with end quote"
'''
def midpoint(left: typing.SupportsFloat, right: typing.SupportsFloat) -> float:
"""midpoint(left: typing.SupportsFloat, right: typing.SupportsFloat) -> float"""
def sum(arg0: typing.SupportsInt, arg1: typing.SupportsInt) -> int:
'''sum(arg0: typing.SupportsInt, arg1: typing.SupportsInt) -> int
multiline docstring test, edge case quotes """\'\'\'
'''
def weighted_midpoint(left: typing.SupportsFloat, right: typing.SupportsFloat, alpha: typing.SupportsFloat = ...) -> float:
"""weighted_midpoint(left: typing.SupportsFloat, right: typing.SupportsFloat, alpha: typing.SupportsFloat = 0.5) -> float"""