# Code generated by Lark OpenAPI.

from typing import Any, Optional, Union, Dict, List, Set, IO, Callable, Type
from lark_oapi.core.construct import init


class PermissionNameInfo(object):
    _types = {
        "id": int,
        "name": str,
    }

    def __init__(self, d=None):
        self.id: Optional[int] = None
        self.name: Optional[str] = None
        init(self, d, self._types)

    @staticmethod
    def builder() -> "PermissionNameInfoBuilder":
        return PermissionNameInfoBuilder()


class PermissionNameInfoBuilder(object):
    def __init__(self) -> None:
        self._permission_name_info = PermissionNameInfo()

    def id(self, id: int) -> "PermissionNameInfoBuilder":
        self._permission_name_info.id = id
        return self

    def name(self, name: str) -> "PermissionNameInfoBuilder":
        self._permission_name_info.name = name
        return self

    def build(self) -> "PermissionNameInfo":
        return self._permission_name_info
