Files
typeshed/stdlib/3/abc.pyi
2018-06-27 20:14:57 -07:00

20 lines
619 B
Python

from typing import Any, Callable, Type, TypeVar
# Stubs for abc.
_T = TypeVar('_T')
_FuncT = TypeVar('_FuncT', bound=Callable[..., Any])
# Thesee definitions have special processing in mypy
class ABCMeta(type):
def register(cls: "ABCMeta", subclass: Type[_T]) -> Type[_T]: ...
def abstractmethod(callable: _FuncT) -> _FuncT: ...
class abstractproperty(property): ...
# These two are deprecated and not supported by mypy
def abstractstaticmethod(callable: _FuncT) -> _FuncT: ...
def abstractclassmethod(callable: _FuncT) -> _FuncT: ...
class ABC(metaclass=ABCMeta):
pass
def get_cache_token() -> object: ...