# Code generated by Lark OpenAPI.

from typing import Any, Optional, Union, Dict, List, Set, IO, Callable, Type
from lark_oapi.core.construct import init
from .i18n import I18n
from .i18n import I18n


class Activity(object):
    _types = {
        "id": str,
        "name": I18n,
        "description": I18n,
        "semester_id": str,
        "mode": str,
        "progress": str,
        "create_time": str,
        "modify_time": str,
        "create_user_id": str,
        "modify_user_id": str,
    }

    def __init__(self, d=None):
        self.id: Optional[str] = None
        self.name: Optional[I18n] = None
        self.description: Optional[I18n] = None
        self.semester_id: Optional[str] = None
        self.mode: Optional[str] = None
        self.progress: Optional[str] = None
        self.create_time: Optional[str] = None
        self.modify_time: Optional[str] = None
        self.create_user_id: Optional[str] = None
        self.modify_user_id: Optional[str] = None
        init(self, d, self._types)

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


class ActivityBuilder(object):
    def __init__(self) -> None:
        self._activity = Activity()

    def id(self, id: str) -> "ActivityBuilder":
        self._activity.id = id
        return self

    def name(self, name: I18n) -> "ActivityBuilder":
        self._activity.name = name
        return self

    def description(self, description: I18n) -> "ActivityBuilder":
        self._activity.description = description
        return self

    def semester_id(self, semester_id: str) -> "ActivityBuilder":
        self._activity.semester_id = semester_id
        return self

    def mode(self, mode: str) -> "ActivityBuilder":
        self._activity.mode = mode
        return self

    def progress(self, progress: str) -> "ActivityBuilder":
        self._activity.progress = progress
        return self

    def create_time(self, create_time: str) -> "ActivityBuilder":
        self._activity.create_time = create_time
        return self

    def modify_time(self, modify_time: str) -> "ActivityBuilder":
        self._activity.modify_time = modify_time
        return self

    def create_user_id(self, create_user_id: str) -> "ActivityBuilder":
        self._activity.create_user_id = create_user_id
        return self

    def modify_user_id(self, modify_user_id: str) -> "ActivityBuilder":
        self._activity.modify_user_id = modify_user_id
        return self

    def build(self) -> "Activity":
        return self._activity
