mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-06 12:14:27 +08:00
56
third_party/2/enum.pyi
vendored
56
third_party/2/enum.pyi
vendored
@@ -29,13 +29,12 @@ class Enum(metaclass=EnumMeta):
|
||||
_value2member_map_: Dict[int, Enum] # undocumented
|
||||
if sys.version_info >= (3, 7):
|
||||
_ignore_: Union[str, List[str]]
|
||||
if sys.version_info >= (3, 6):
|
||||
_order_: str
|
||||
__order__: str
|
||||
@classmethod
|
||||
def _missing_(cls, value: object) -> Any: ...
|
||||
@staticmethod
|
||||
def _generate_next_value_(name: str, start: int, count: int, last_values: List[Any]) -> Any: ...
|
||||
_order_: str
|
||||
__order__: str
|
||||
@classmethod
|
||||
def _missing_(cls, value: object) -> Any: ...
|
||||
@staticmethod
|
||||
def _generate_next_value_(name: str, start: int, count: int, last_values: List[Any]) -> Any: ...
|
||||
def __new__(cls: Type[_T], value: object) -> _T: ...
|
||||
def __repr__(self) -> str: ...
|
||||
def __str__(self) -> str: ...
|
||||
@@ -49,25 +48,26 @@ class IntEnum(int, Enum):
|
||||
|
||||
def unique(enumeration: _S) -> _S: ...
|
||||
|
||||
if sys.version_info >= (3, 6):
|
||||
_auto_null: Any
|
||||
_auto_null: Any
|
||||
|
||||
# subclassing IntFlag so it picks up all implemented base functions, best modeling behavior of enum.auto()
|
||||
class auto(IntFlag):
|
||||
value: Any
|
||||
class Flag(Enum):
|
||||
def __contains__(self: _T, other: _T) -> bool: ...
|
||||
def __repr__(self) -> str: ...
|
||||
def __str__(self) -> str: ...
|
||||
def __bool__(self) -> bool: ...
|
||||
def __or__(self: _T, other: _T) -> _T: ...
|
||||
def __and__(self: _T, other: _T) -> _T: ...
|
||||
def __xor__(self: _T, other: _T) -> _T: ...
|
||||
def __invert__(self: _T) -> _T: ...
|
||||
class IntFlag(int, Flag):
|
||||
def __or__(self: _T, other: Union[int, _T]) -> _T: ...
|
||||
def __and__(self: _T, other: Union[int, _T]) -> _T: ...
|
||||
def __xor__(self: _T, other: Union[int, _T]) -> _T: ...
|
||||
__ror__ = __or__
|
||||
__rand__ = __and__
|
||||
__rxor__ = __xor__
|
||||
# subclassing IntFlag so it picks up all implemented base functions, best modeling behavior of enum.auto()
|
||||
class auto(IntFlag):
|
||||
value: Any
|
||||
|
||||
class Flag(Enum):
|
||||
def __contains__(self: _T, other: _T) -> bool: ...
|
||||
def __repr__(self) -> str: ...
|
||||
def __str__(self) -> str: ...
|
||||
def __bool__(self) -> bool: ...
|
||||
def __or__(self: _T, other: _T) -> _T: ...
|
||||
def __and__(self: _T, other: _T) -> _T: ...
|
||||
def __xor__(self: _T, other: _T) -> _T: ...
|
||||
def __invert__(self: _T) -> _T: ...
|
||||
|
||||
class IntFlag(int, Flag):
|
||||
def __or__(self: _T, other: Union[int, _T]) -> _T: ...
|
||||
def __and__(self: _T, other: Union[int, _T]) -> _T: ...
|
||||
def __xor__(self: _T, other: Union[int, _T]) -> _T: ...
|
||||
__ror__ = __or__
|
||||
__rand__ = __and__
|
||||
__rxor__ = __xor__
|
||||
|
||||
2
third_party/2/tornado/web.pyi
vendored
2
third_party/2/tornado/web.pyi
vendored
@@ -8,7 +8,7 @@ MAX_SUPPORTED_SIGNED_VALUE_VERSION: Any
|
||||
DEFAULT_SIGNED_VALUE_VERSION: Any
|
||||
DEFAULT_SIGNED_VALUE_MIN_VERSION: Any
|
||||
|
||||
if sys.version_info[:2] >= (3, 5):
|
||||
if sys.version_info >= (3, 5):
|
||||
from typing import Awaitable
|
||||
|
||||
_MethodType = Callable[..., Optional[Awaitable[None]]]
|
||||
|
||||
Reference in New Issue
Block a user