# 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 ReferenceObject(object):
    _types = {
        "api_name": str,
        "id": str,
    }

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

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


class ReferenceObjectBuilder(object):
    def __init__(self) -> None:
        self._reference_object = ReferenceObject()

    def api_name(self, api_name: str) -> "ReferenceObjectBuilder":
        self._reference_object.api_name = api_name
        return self

    def id(self, id: str) -> "ReferenceObjectBuilder":
        self._reference_object.id = id
        return self

    def build(self) -> "ReferenceObject":
        return self._reference_object
