# WARNING: Please don't edit this file. It was generated by Python/WinRT v1.0.0-beta.7

import enum
import datetime
import sys
import types
import typing

import winsdk._winrt as _winrt
import winsdk.windows.foundation
import winsdk.windows.storage.streams

class CompressAlgorithm(enum.IntEnum):
    INVALID_ALGORITHM = 0
    NULL_ALGORITHM = 1
    MSZIP = 2
    XPRESS = 3
    XPRESS_HUFF = 4
    LZMS = 5

Self = typing.TypeVar('Self')

class Compressor(_winrt.Object):
    def __enter__(self: Self) -> Self: ...
    def __exit__(self, *args) -> None: ...
    @staticmethod
    def _from(obj: _winrt.Object) -> Compressor: ...
    @typing.overload
    def __new__(cls: typing.Type[Compressor], underlying_stream: typing.Optional[winsdk.windows.storage.streams.IOutputStream]) -> Compressor:...
    @typing.overload
    def __new__(cls: typing.Type[Compressor], underlying_stream: typing.Optional[winsdk.windows.storage.streams.IOutputStream], algorithm: CompressAlgorithm, block_size: _winrt.UInt32) -> Compressor:...
    def close(self) -> None: ...
    def detach_stream(self) -> typing.Optional[winsdk.windows.storage.streams.IOutputStream]: ...
    def finish_async(self) -> winsdk.windows.foundation.IAsyncOperation[_winrt.Boolean]: ...
    def flush_async(self) -> winsdk.windows.foundation.IAsyncOperation[_winrt.Boolean]: ...
    def write_async(self, buffer: typing.Optional[winsdk.windows.storage.streams.IBuffer]) -> winsdk.windows.foundation.IAsyncOperationWithProgress[_winrt.UInt32, _winrt.UInt32]: ...

class Decompressor(_winrt.Object):
    def __enter__(self: Self) -> Self: ...
    def __exit__(self, *args) -> None: ...
    @staticmethod
    def _from(obj: _winrt.Object) -> Decompressor: ...
    def __new__(cls: typing.Type[Decompressor], underlying_stream: typing.Optional[winsdk.windows.storage.streams.IInputStream]) -> Decompressor:...
    def close(self) -> None: ...
    def detach_stream(self) -> typing.Optional[winsdk.windows.storage.streams.IInputStream]: ...
    def read_async(self, buffer: typing.Optional[winsdk.windows.storage.streams.IBuffer], count: _winrt.UInt32, options: winsdk.windows.storage.streams.InputStreamOptions) -> winsdk.windows.foundation.IAsyncOperationWithProgress[winsdk.windows.storage.streams.IBuffer, _winrt.UInt32]: ...

