# 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 AnnualReportMapFloat(object):
    _types = {
        "year": str,
        "num": float,
    }

    def __init__(self, d=None):
        self.year: Optional[str] = None
        self.num: Optional[float] = None
        init(self, d, self._types)

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


class AnnualReportMapFloatBuilder(object):
    def __init__(self) -> None:
        self._annual_report_map_float = AnnualReportMapFloat()

    def year(self, year: str) -> "AnnualReportMapFloatBuilder":
        self._annual_report_map_float.year = year
        return self

    def num(self, num: float) -> "AnnualReportMapFloatBuilder":
        self._annual_report_map_float.num = num
        return self

    def build(self) -> "AnnualReportMapFloat":
        return self._annual_report_map_float
