# 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 OfferAttachmentInfo(object):
    _types = {
        "id": str,
        "name": str,
        "size": int,
        "common_attachment_id": str,
    }

    def __init__(self, d=None):
        self.id: Optional[str] = None
        self.name: Optional[str] = None
        self.size: Optional[int] = None
        self.common_attachment_id: Optional[str] = None
        init(self, d, self._types)

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


class OfferAttachmentInfoBuilder(object):
    def __init__(self) -> None:
        self._offer_attachment_info = OfferAttachmentInfo()

    def id(self, id: str) -> "OfferAttachmentInfoBuilder":
        self._offer_attachment_info.id = id
        return self

    def name(self, name: str) -> "OfferAttachmentInfoBuilder":
        self._offer_attachment_info.name = name
        return self

    def size(self, size: int) -> "OfferAttachmentInfoBuilder":
        self._offer_attachment_info.size = size
        return self

    def common_attachment_id(self, common_attachment_id: str) -> "OfferAttachmentInfoBuilder":
        self._offer_attachment_info.common_attachment_id = common_attachment_id
        return self

    def build(self) -> "OfferAttachmentInfo":
        return self._offer_attachment_info
