"""
This type stub file was generated by pyright.
"""

from typing import Callable, IO, TYPE_CHECKING
from collections.abc import Iterator
from sphinx.builders import Builder
from sphinx.environment import BuildEnvironment
from sphinx.util.typing import Inventory

"""Inventory utility functions for Sphinx."""
BUFSIZE = ...
logger = ...
if TYPE_CHECKING:
    ...
class InventoryFileReader:
    """A file reader for an inventory file.

    This reader supports mixture of texts and compressed texts.
    """
    def __init__(self, stream: IO) -> None:
        ...
    
    def read_buffer(self) -> None:
        ...
    
    def readline(self) -> str:
        ...
    
    def readlines(self) -> Iterator[str]:
        ...
    
    def read_compressed_chunks(self) -> Iterator[bytes]:
        ...
    
    def read_compressed_lines(self) -> Iterator[str]:
        ...
    


class InventoryFile:
    @classmethod
    def load(cls, stream: IO, uri: str, joinfunc: Callable) -> Inventory:
        ...
    
    @classmethod
    def load_v1(cls, stream: InventoryFileReader, uri: str, join: Callable) -> Inventory:
        ...
    
    @classmethod
    def load_v2(cls, stream: InventoryFileReader, uri: str, join: Callable) -> Inventory:
        ...
    
    @classmethod
    def dump(cls, filename: str, env: BuildEnvironment, builder: Builder) -> None:
        ...
    


