24 lines
374 B
Python
24 lines
374 B
Python
from typing import *
|
|
from uuid import UUID
|
|
from enum import Enum
|
|
|
|
from pydantic import BaseModel
|
|
|
|
|
|
class ComputerType(str, Enum):
|
|
COMPUTER = "computer"
|
|
TURTLE = "turtle"
|
|
POCKET = "pocket"
|
|
|
|
|
|
class Computer(BaseModel):
|
|
type: ComputerType
|
|
is_advanced: bool
|
|
uuid: UUID
|
|
label: Optional[str]
|
|
group: str
|
|
|
|
|
|
class State:
|
|
computers: List[Computer]
|