Format: application/octet-stream
⬇ Download File (1.7 KB)
   1  import sys
   2  from array import array
   3  from typing import Any, Union
   4  
   5  DEFLATED: int
   6  DEF_MEM_LEVEL: int
   7  MAX_WBITS: int
   8  ZLIB_VERSION: str
   9  Z_BEST_COMPRESSION: int
  10  Z_BEST_SPEED: int
  11  Z_DEFAULT_COMPRESSION: int
  12  Z_DEFAULT_STRATEGY: int
  13  Z_FILTERED: int
  14  Z_FINISH: int
  15  Z_FULL_FLUSH: int
  16  Z_HUFFMAN_ONLY: int
  17  Z_NO_FLUSH: int
  18  Z_SYNC_FLUSH: int
  19  if sys.version_info >= (3,):
  20      DEF_BUF_SIZE: int
  21      ZLIB_RUNTIME_VERSION: str
  22  
  23  class error(Exception): ...
  24  
  25  class _Compress:
  26      def compress(self, data: bytes) -> bytes: ...
  27      def flush(self, mode: int = ...) -> bytes: ...
  28      def copy(self) -> _Compress: ...
  29  
  30  class _Decompress:
  31      unused_data: bytes
  32      unconsumed_tail: bytes
  33      if sys.version_info >= (3,):
  34          eof: bool
  35      def decompress(self, data: bytes, max_length: int = ...) -> bytes: ...
  36      def flush(self, length: int = ...) -> bytes: ...
  37      def copy(self) -> _Decompress: ...
  38  
  39  def adler32(__data: bytes, __value: int = ...) -> int: ...
  40  def compress(__data: bytes, level: int = ...) -> bytes: ...
  41  
  42  if sys.version_info >= (3,):
  43      def compressobj(
  44          level: int = ..., method: int = ..., wbits: int = ..., memLevel: int = ..., strategy: int = ..., zdict: bytes = ...
  45      ) -> _Compress: ...
  46  
  47  else:
  48      def compressobj(
  49          level: int = ..., method: int = ..., wbits: int = ..., memlevel: int = ..., strategy: int = ...
  50      ) -> _Compress: ...
  51  
  52  def crc32(__data: Union[array[Any], bytes], __value: int = ...) -> int: ...
  53  def decompress(__data: bytes, wbits: int = ..., bufsize: int = ...) -> bytes: ...
  54  
  55  if sys.version_info >= (3,):
  56      def decompressobj(wbits: int = ..., zdict: bytes = ...) -> _Decompress: ...
  57  
  58  else:
  59      def decompressobj(wbits: int = ...) -> _Decompress: ...
  60