mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-09 21:46:42 +08:00
Add type hints to ElementInclude.pyi
This commit is contained in:
@@ -2,13 +2,18 @@
|
||||
#
|
||||
# NOTE: This dynamically typed stub was automatically generated by stubgen.
|
||||
|
||||
from typing import Any
|
||||
from typing import Union, Optional
|
||||
from .ElementTree import Element
|
||||
|
||||
XINCLUDE = ... # type: Any
|
||||
XINCLUDE_INCLUDE = ... # type: Any
|
||||
XINCLUDE_FALLBACK = ... # type: Any
|
||||
XINCLUDE = ... # type: str
|
||||
XINCLUDE_INCLUDE = ... # type: str
|
||||
XINCLUDE_FALLBACK = ... # type: str
|
||||
|
||||
class FatalIncludeError(SyntaxError): ...
|
||||
|
||||
def default_loader(href, parse, encoding=...): ...
|
||||
def include(elem, loader=...): ...
|
||||
def default_loader(href: Union[str, bytes, int], parse: str, encoding: Optional[str]=...) -> Union[str, Element]: ...
|
||||
|
||||
# TODO: loader is of type default_loader ie it takes a callable that has the
|
||||
# same signature as default_loader. But default_loader has a keyword argument
|
||||
# Which can't be represented using Callable...
|
||||
def include(elem: Element, loader=...) -> None: ...
|
||||
|
||||
Reference in New Issue
Block a user