# 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 KnowledgeSourceSpaceFilter(object):
    _types = {
        "doc_tokens": List[str],
        "folder_tokens": List[str],
    }

    def __init__(self, d=None):
        self.doc_tokens: Optional[List[str]] = None
        self.folder_tokens: Optional[List[str]] = None
        init(self, d, self._types)

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


class KnowledgeSourceSpaceFilterBuilder(object):
    def __init__(self) -> None:
        self._knowledge_source_space_filter = KnowledgeSourceSpaceFilter()

    def doc_tokens(self, doc_tokens: List[str]) -> "KnowledgeSourceSpaceFilterBuilder":
        self._knowledge_source_space_filter.doc_tokens = doc_tokens
        return self

    def folder_tokens(self, folder_tokens: List[str]) -> "KnowledgeSourceSpaceFilterBuilder":
        self._knowledge_source_space_filter.folder_tokens = folder_tokens
        return self

    def build(self) -> "KnowledgeSourceSpaceFilter":
        return self._knowledge_source_space_filter
