# 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 .enum import Enum


class SignatureTemplateFilterItem(object):
    _types = {
        "left": str,
        "rights": List[str],
        "op": Enum,
    }

    def __init__(self, d=None):
        self.left: Optional[str] = None
        self.rights: Optional[List[str]] = None
        self.op: Optional[Enum] = None
        init(self, d, self._types)

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


class SignatureTemplateFilterItemBuilder(object):
    def __init__(self) -> None:
        self._signature_template_filter_item = SignatureTemplateFilterItem()

    def left(self, left: str) -> "SignatureTemplateFilterItemBuilder":
        self._signature_template_filter_item.left = left
        return self

    def rights(self, rights: List[str]) -> "SignatureTemplateFilterItemBuilder":
        self._signature_template_filter_item.rights = rights
        return self

    def op(self, op: Enum) -> "SignatureTemplateFilterItemBuilder":
        self._signature_template_filter_item.op = op
        return self

    def build(self) -> "SignatureTemplateFilterItem":
        return self._signature_template_filter_item
