# 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 RangeFilter(object):
    _types = {
        "from_": str,
        "to": str,
    }

    def __init__(self, d=None):
        self.from_: Optional[str] = None
        self.to: Optional[str] = None
        init(self, d, self._types)

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


class RangeFilterBuilder(object):
    def __init__(self) -> None:
        self._range_filter = RangeFilter()

    def from_(self, from_: str) -> "RangeFilterBuilder":
        self._range_filter.from_ = from_
        return self

    def to(self, to: str) -> "RangeFilterBuilder":
        self._range_filter.to = to
        return self

    def build(self) -> "RangeFilter":
        return self._range_filter
