# 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 TaskDependency(object):
    _types = {
        "type": str,
        "task_guid": str,
    }

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

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


class TaskDependencyBuilder(object):
    def __init__(self) -> None:
        self._task_dependency = TaskDependency()

    def type(self, type: str) -> "TaskDependencyBuilder":
        self._task_dependency.type = type
        return self

    def task_guid(self, task_guid: str) -> "TaskDependencyBuilder":
        self._task_dependency.task_guid = task_guid
        return self

    def build(self) -> "TaskDependency":
        return self._task_dependency
