# 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 I18n(object):
    _types = {
        "language_code": str,
        "text": str,
    }

    def __init__(self, d=None):
        self.language_code: Optional[str] = None
        self.text: Optional[str] = None
        init(self, d, self._types)

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


class I18nBuilder(object):
    def __init__(self) -> None:
        self._i18n = I18n()

    def language_code(self, language_code: str) -> "I18nBuilder":
        self._i18n.language_code = language_code
        return self

    def text(self, text: str) -> "I18nBuilder":
        self._i18n.text = text
        return self

    def build(self) -> "I18n":
        return self._i18n
