File: grp.pyi

package info (click to toggle)
typeshed 0.0~git20241223.ea91db2-4
  • links: PTS, VCS
  • area: main
  • in suites: forky
  • size: 28,824 kB
  • sloc: python: 7,745; makefile: 21; sh: 18
file content (22 lines) | stat: -rw-r--r-- 702 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
import sys
from _typeshed import structseq
from typing import Any, Final, final

if sys.platform != "win32":
    @final
    class struct_group(structseq[Any], tuple[str, str | None, int, list[str]]):
        if sys.version_info >= (3, 10):
            __match_args__: Final = ("gr_name", "gr_passwd", "gr_gid", "gr_mem")

        @property
        def gr_name(self) -> str: ...
        @property
        def gr_passwd(self) -> str | None: ...
        @property
        def gr_gid(self) -> int: ...
        @property
        def gr_mem(self) -> list[str]: ...

    def getgrall() -> list[struct_group]: ...
    def getgrgid(id: int) -> struct_group: ...
    def getgrnam(name: str) -> struct_group: ...