# Code generated by Lark OpenAPI.

from typing import Optional

from lark_oapi.core.construct import init
from .unit import Unit


class GetUnitResponseBody(object):
    _types = {
        "unit": Unit,
    }

    def __init__(self, d=None):
        self.unit: Optional[Unit] = None
        init(self, d, self._types)

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


class GetUnitResponseBodyBuilder(object):
    def __init__(self) -> None:
        self._get_unit_response_body = GetUnitResponseBody()

    def unit(self, unit: Unit) -> "GetUnitResponseBodyBuilder":
        self._get_unit_response_body.unit = unit
        return self

    def build(self) -> "GetUnitResponseBody":
        return self._get_unit_response_body
