# 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 AppFeedNotify(object):
    _types = {
        "close_notify": bool,
        "custom_sound_text": str,
        "with_custom_sound": bool,
    }

    def __init__(self, d=None):
        self.close_notify: Optional[bool] = None
        self.custom_sound_text: Optional[str] = None
        self.with_custom_sound: Optional[bool] = None
        init(self, d, self._types)

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


class AppFeedNotifyBuilder(object):
    def __init__(self) -> None:
        self._app_feed_notify = AppFeedNotify()

    def close_notify(self, close_notify: bool) -> "AppFeedNotifyBuilder":
        self._app_feed_notify.close_notify = close_notify
        return self

    def custom_sound_text(self, custom_sound_text: str) -> "AppFeedNotifyBuilder":
        self._app_feed_notify.custom_sound_text = custom_sound_text
        return self

    def with_custom_sound(self, with_custom_sound: bool) -> "AppFeedNotifyBuilder":
        self._app_feed_notify.with_custom_sound = with_custom_sound
        return self

    def build(self) -> "AppFeedNotify":
        return self._app_feed_notify
