1 from typing import Any, Iterable, List, Mapping, Optional, Tuple, overload
3 _Option = Tuple[str, Optional[str], str]
4 _GR = Tuple[List[str], OptionDummy]
7 options: list[_Option], negative_opt: Mapping[_Option, _Option], object: Any, args: list[str] | None
8 ) -> list[str] | _GR: ...
9 def wrap_text(text: str, width: int) -> list[str]: ...
12 def __init__(self, option_table: list[_Option] | None = ...) -> None: ...
13 # TODO kinda wrong, `getopt(object=object())` is invalid
15 def getopt(self, args: list[str] | None = ...) -> _GR: ...
17 def getopt(self, args: list[str] | None, object: Any) -> list[str]: ...
18 def get_option_order(self) -> list[tuple[str, str]]: ...
19 def generate_help(self, header: str | None = ...) -> list[str]: ...
22 def __init__(self, options: Iterable[str] = ...) -> None: ...