add py3 version to zipimport (#305)

This commit is contained in:
Valérian Rousset
2016-07-18 06:05:05 +02:00
committed by Guido van Rossum
parent d5938ee76c
commit 61f232c7d8

View File

@@ -0,0 +1,19 @@
"""Stub file for the 'zipimport' module."""
from typing import Optional
from types import CodeType, ModuleType
class ZipImportError(ImportError): ...
class zipimporter(object):
archive = ... # type: str
prefix = ... # type: str
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, pathname: str) -> str: ...
def get_filename(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: ...