mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-24 12:51:27 +08:00
Add __all__ for modules beginning with 'u', 'x', 'w' and 'z' (#7374)
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
from typing import Any, Iterable, TypeVar
|
||||
|
||||
__all__ = ["NodeList", "EmptyNodeList", "StringTypes", "defproperty"]
|
||||
|
||||
_T = TypeVar("_T")
|
||||
|
||||
StringTypes: tuple[type[str]]
|
||||
|
||||
@@ -4,6 +4,8 @@ from urllib.request import OpenerDirector
|
||||
from xml.dom.expatbuilder import ExpatBuilder, ExpatBuilderNS
|
||||
from xml.dom.minidom import Node
|
||||
|
||||
__all__ = ["DOMBuilder", "DOMEntityResolver", "DOMInputSource"]
|
||||
|
||||
# UNKNOWN TYPES:
|
||||
# - `Options.errorHandler`.
|
||||
# The same as `_DOMBuilderErrorHandlerType`?
|
||||
|
||||
@@ -17,6 +17,90 @@ from typing import (
|
||||
)
|
||||
from typing_extensions import Literal, SupportsIndex, TypeGuard
|
||||
|
||||
if sys.version_info >= (3, 9):
|
||||
__all__ = [
|
||||
"Comment",
|
||||
"dump",
|
||||
"Element",
|
||||
"ElementTree",
|
||||
"fromstring",
|
||||
"fromstringlist",
|
||||
"indent",
|
||||
"iselement",
|
||||
"iterparse",
|
||||
"parse",
|
||||
"ParseError",
|
||||
"PI",
|
||||
"ProcessingInstruction",
|
||||
"QName",
|
||||
"SubElement",
|
||||
"tostring",
|
||||
"tostringlist",
|
||||
"TreeBuilder",
|
||||
"VERSION",
|
||||
"XML",
|
||||
"XMLID",
|
||||
"XMLParser",
|
||||
"XMLPullParser",
|
||||
"register_namespace",
|
||||
"canonicalize",
|
||||
"C14NWriterTarget",
|
||||
]
|
||||
elif sys.version_info >= (3, 8):
|
||||
__all__ = [
|
||||
"Comment",
|
||||
"dump",
|
||||
"Element",
|
||||
"ElementTree",
|
||||
"fromstring",
|
||||
"fromstringlist",
|
||||
"iselement",
|
||||
"iterparse",
|
||||
"parse",
|
||||
"ParseError",
|
||||
"PI",
|
||||
"ProcessingInstruction",
|
||||
"QName",
|
||||
"SubElement",
|
||||
"tostring",
|
||||
"tostringlist",
|
||||
"TreeBuilder",
|
||||
"VERSION",
|
||||
"XML",
|
||||
"XMLID",
|
||||
"XMLParser",
|
||||
"XMLPullParser",
|
||||
"register_namespace",
|
||||
"canonicalize",
|
||||
"C14NWriterTarget",
|
||||
]
|
||||
else:
|
||||
__all__ = [
|
||||
"Comment",
|
||||
"dump",
|
||||
"Element",
|
||||
"ElementTree",
|
||||
"fromstring",
|
||||
"fromstringlist",
|
||||
"iselement",
|
||||
"iterparse",
|
||||
"parse",
|
||||
"ParseError",
|
||||
"PI",
|
||||
"ProcessingInstruction",
|
||||
"QName",
|
||||
"SubElement",
|
||||
"tostring",
|
||||
"tostringlist",
|
||||
"TreeBuilder",
|
||||
"VERSION",
|
||||
"XML",
|
||||
"XMLID",
|
||||
"XMLParser",
|
||||
"XMLPullParser",
|
||||
"register_namespace",
|
||||
]
|
||||
|
||||
_T = TypeVar("_T")
|
||||
_FileRead = Union[StrOrBytesPath, FileDescriptor, SupportsRead[bytes], SupportsRead[str]]
|
||||
_FileWriteC14N = Union[StrOrBytesPath, FileDescriptor, SupportsWrite[bytes]]
|
||||
|
||||
Reference in New Issue
Block a user