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

from typing import Any, TYPE_CHECKING
from pandas._typing import FilePath, ReadBuffer, Scalar, StorageOptions, WriteExcelBuffer
from pandas.util._decorators import doc
from pandas.core.shared_docs import _shared_docs
from pandas.io.excel._base import BaseExcelReader, ExcelWriter
from openpyxl.workbook import Workbook

if TYPE_CHECKING:
    ...
class OpenpyxlWriter(ExcelWriter):
    _engine = ...
    _supported_extensions = ...
    def __init__(self, path: FilePath | WriteExcelBuffer | ExcelWriter, engine: str | None = ..., date_format: str | None = ..., datetime_format: str | None = ..., mode: str = ..., storage_options: StorageOptions = ..., if_sheet_exists: str | None = ..., engine_kwargs: dict[str, Any] | None = ..., **kwargs) -> None:
        ...
    
    @property
    def book(self) -> Workbook:
        """
        Book instance of class openpyxl.workbook.Workbook.

        This attribute can be used to access engine-specific features.
        """
        ...
    
    @property
    def sheets(self) -> dict[str, Any]:
        """Mapping of sheet names to sheet objects."""
        ...
    


class OpenpyxlReader(BaseExcelReader):
    @doc(storage_options=_shared_docs["storage_options"])
    def __init__(self, filepath_or_buffer: FilePath | ReadBuffer[bytes], storage_options: StorageOptions = ...) -> None:
        """
        Reader using openpyxl engine.

        Parameters
        ----------
        filepath_or_buffer : str, path object or Workbook
            Object to be parsed.
        {storage_options}
        """
        ...
    
    def load_workbook(self, filepath_or_buffer: FilePath | ReadBuffer[bytes]):
        ...
    
    @property
    def sheet_names(self) -> list[str]:
        ...
    
    def get_sheet_by_name(self, name: str):
        ...
    
    def get_sheet_by_index(self, index: int):
        ...
    
    def get_sheet_data(self, sheet, convert_float: bool, file_rows_needed: int | None = ...) -> list[list[Scalar]]:
        ...
    


