This repository has been archived on 2022-08-24. You can view files and clone it, but cannot push or open issues or pull requests.
ergast-py/ergast_py/models/status.py
2022-06-01 14:31:52 +01:00

23 lines
652 B
Python

from dataclasses import dataclass
@dataclass
class Status:
"""
Representation of the finishing status of a Driver in a Race
Statuses may contain:
statusId: Integer
count: Integer
status: String
"""
def __init__(self, statusId: int, count: int, status: str) -> None:
self.statusId = statusId
self.count = count
self.status = status
pass
def __str__(self):
return f"Status(statusId={self.statusId}, count={self.count}, status={self.status})"
def __repr__(self):
return f"Status(statusId={self.statusId}, count={self.count}, status={self.status})"