# 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 AppliOfferOnboardProfileCity(object):
    _types = {
        "code": str,
        "name": str,
        "en_name": str,
        "location_type": int,
    }

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

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


class AppliOfferOnboardProfileCityBuilder(object):
    def __init__(self) -> None:
        self._appli_offer_onboard_profile_city = AppliOfferOnboardProfileCity()

    def code(self, code: str) -> "AppliOfferOnboardProfileCityBuilder":
        self._appli_offer_onboard_profile_city.code = code
        return self

    def name(self, name: str) -> "AppliOfferOnboardProfileCityBuilder":
        self._appli_offer_onboard_profile_city.name = name
        return self

    def en_name(self, en_name: str) -> "AppliOfferOnboardProfileCityBuilder":
        self._appli_offer_onboard_profile_city.en_name = en_name
        return self

    def location_type(self, location_type: int) -> "AppliOfferOnboardProfileCityBuilder":
        self._appli_offer_onboard_profile_city.location_type = location_type
        return self

    def build(self) -> "AppliOfferOnboardProfileCity":
        return self._appli_offer_onboard_profile_city
