mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-16 00:37:10 +08:00
add py3 version to zipimport (#305)
This commit is contained in:
committed by
Guido van Rossum
parent
d5938ee76c
commit
61f232c7d8
@@ -1,25 +1,19 @@
|
||||
"""Stub file for the 'zipimport' module."""
|
||||
|
||||
from typing import Dict, Optional
|
||||
from typing import Optional
|
||||
from types import CodeType, ModuleType
|
||||
|
||||
class ZipImportError(ImportError):
|
||||
pass
|
||||
|
||||
_zip_directory_cache = ... # type: Dict[str, dict]
|
||||
class ZipImportError(ImportError): ...
|
||||
|
||||
class zipimporter(object):
|
||||
archive = ... # type: str
|
||||
prefix = ... # type: str
|
||||
_files = ... # type: Dict[str, tuple]
|
||||
def __init__(self, path: str) -> None:
|
||||
raise ZipImportError
|
||||
def find_module(self, fullname: str, path: str = ...) -> Optional['zipimporter']: ...
|
||||
def __init__(self, archivepath: str) -> None: ...
|
||||
def find_module(self, fullname: str, path: str = ...) -> Optional[zipimporter]: ...
|
||||
def get_code(self, fullname: str) -> CodeType: ...
|
||||
def get_data(self, fullname: str) -> str:
|
||||
raise IOError
|
||||
def get_data(self, pathname: str) -> str: ...
|
||||
def get_filename(self, fullname: str) -> str: ...
|
||||
def get_source(self, fullname: str) -> str: ...
|
||||
def get_source(self, fullname: str) -> Optional[str]: ...
|
||||
def is_package(self, fullname: str) -> bool: ...
|
||||
def load_module(self, fullname: str) -> ModuleType: ...
|
||||
|
||||
Reference in New Issue
Block a user