from typing import Optional, List, Any

from .state import WorkflowState, WorkflowStateDto


class WorkflowToken[T: Any]:
  id: str
  parent: Optional[str]
  locked: Optional[bool]
  history: List[WorkflowState[T]]


# ----------------------------------------
# Data Transfer Object Interface
# ----------------------------------------


class WorkflowTokenDto[T: Any]:
  id: str
  parent: Optional[str]
  locked: Optional[bool]
  history: List[WorkflowStateDto[T]]
