SI_InteligentnyWozekWidlowy/data/Order.py
Aleksander Szamałek 522b29269d engine improvements
2022-05-22 16:27:36 +02:00

21 lines
596 B
Python

from itertools import count
from typing import List
from data.ClientParams import ClientParams
from data.Item import Item
from data.enum.Priority import Priority
class Order:
id_counter = count(start=0)
def __init__(self, time: int, items: [Item], priority: Priority, client_params: ClientParams):
self.id = next(self.id_counter)
self.time = time
self.items: List[Item] = items
self.client_params = client_params
self.priority = priority
def __repr__(self) -> str:
return "items: {} priority: {}".format(self.items, self.priority)