# This file was generated by liblab | https://liblab.com/

from .utils.json_map import JsonMap
from .base import BaseModel


@JsonMap({"id_": "id", "tri_code": "triCode"})
class GameLinescoreTeamTeam(BaseModel):
    """GameLinescoreTeamTeam

    :param id_: id_, defaults to None
    :type id_: float, optional
    :param name: name, defaults to None
    :type name: str, optional
    :param link: link, defaults to None
    :type link: str, optional
    :param abbreviation: abbreviation, defaults to None
    :type abbreviation: str, optional
    :param tri_code: tri_code, defaults to None
    :type tri_code: str, optional
    """

    def __init__(
        self,
        id_: float = None,
        name: str = None,
        link: str = None,
        abbreviation: str = None,
        tri_code: str = None,
    ):
        if id_ is not None:
            self.id_ = id_
        if name is not None:
            self.name = name
        if link is not None:
            self.link = link
        if abbreviation is not None:
            self.abbreviation = abbreviation
        if tri_code is not None:
            self.tri_code = tri_code


@JsonMap(
    {
        "shots_on_goal": "shotsOnGoal",
        "goalie_pulled": "goaliePulled",
        "num_skaters": "numSkaters",
        "power_play": "powerPlay",
    }
)
class GameLinescoreTeam(BaseModel):
    """GameLinescoreTeam

    :param team: team, defaults to None
    :type team: GameLinescoreTeamTeam, optional
    :param goals: goals, defaults to None
    :type goals: float, optional
    :param shots_on_goal: shots_on_goal, defaults to None
    :type shots_on_goal: float, optional
    :param goalie_pulled: goalie_pulled, defaults to None
    :type goalie_pulled: bool, optional
    :param num_skaters: num_skaters, defaults to None
    :type num_skaters: float, optional
    :param power_play: power_play, defaults to None
    :type power_play: bool, optional
    """

    def __init__(
        self,
        team: GameLinescoreTeamTeam = None,
        goals: float = None,
        shots_on_goal: float = None,
        goalie_pulled: bool = None,
        num_skaters: float = None,
        power_play: bool = None,
    ):
        if team is not None:
            self.team = self._define_object(team, GameLinescoreTeamTeam)
        if goals is not None:
            self.goals = goals
        if shots_on_goal is not None:
            self.shots_on_goal = shots_on_goal
        if goalie_pulled is not None:
            self.goalie_pulled = goalie_pulled
        if num_skaters is not None:
            self.num_skaters = num_skaters
        if power_play is not None:
            self.power_play = power_play
