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/constructor.py

25 lines
555 B
Python
Raw Normal View History

""" Constructor class """
2022-06-01 15:31:52 +02:00
from dataclasses import dataclass
from ergast_py.models.model import Model
2022-06-01 15:31:52 +02:00
@dataclass
class Constructor(Model):
2022-06-01 15:31:52 +02:00
"""
Representation of a Formula One Team
2022-06-01 15:31:52 +02:00
Constructors may contain:
constructor_id: String
2022-06-01 15:31:52 +02:00
url: String
name: String
nationality: String
"""
def __init__(self, constructor_id: str, url: str, name: str, nationality: str) -> None:
self.constructor_id = constructor_id
2022-06-01 15:31:52 +02:00
self.url = url
self.name = name
self.nationality = nationality