# coding: utf-8

"""
    Singlearity Baseball API

    Baseball optimization API using machine learning  # noqa: E501

    The version of the OpenAPI document: 0.1.1
    Generated by: https://openapi-generator.tech
"""


import pprint
import re  # noqa: F401

import six

from singlearity.configuration import Configuration


class Player(object):
    """NOTE: This class is auto generated by OpenAPI Generator.
    Ref: https://openapi-generator.tech

    Do not edit the class manually.
    """

    """
    Attributes:
      openapi_types (dict): The key is attribute name
                            and the value is attribute type.
      attribute_map (dict): The key is attribute name
                            and the value is json key in definition.
    """
    openapi_types = {
        'full_name': 'str',
        'position': 'str',
        'mlb_id': 'int',
        'debut_date': 'str',
        'team_id': 'int',
        'team_abbrev': 'str',
        'active': 'bool',
        'bat_side': 'str',
        'pitch_hand': 'str',
        'birth_country': 'str',
        'birth_date': 'str',
        'current_age': 'int',
        'photo_url': 'str'
    }

    attribute_map = {
        'full_name': 'full_name',
        'position': 'position',
        'mlb_id': 'mlb_id',
        'debut_date': 'debut_date',
        'team_id': 'team_id',
        'team_abbrev': 'team_abbrev',
        'active': 'active',
        'bat_side': 'bat_side',
        'pitch_hand': 'pitch_hand',
        'birth_country': 'birth_country',
        'birth_date': 'birth_date',
        'current_age': 'current_age',
        'photo_url': 'photo_url'
    }

    def __init__(self, full_name=None, position=None, mlb_id=None, debut_date=None, team_id=None, team_abbrev=None, active=None, bat_side=None, pitch_hand=None, birth_country=None, birth_date=None, current_age=None, photo_url=None, local_vars_configuration=None):  # noqa: E501
        """Player - a model defined in OpenAPI"""  # noqa: E501
        if local_vars_configuration is None:
            local_vars_configuration = Configuration()
        self.local_vars_configuration = local_vars_configuration

        self._full_name = None
        self._position = None
        self._mlb_id = None
        self._debut_date = None
        self._team_id = None
        self._team_abbrev = None
        self._active = None
        self._bat_side = None
        self._pitch_hand = None
        self._birth_country = None
        self._birth_date = None
        self._current_age = None
        self._photo_url = None
        self.discriminator = None

        self.full_name = full_name
        self.position = position
        self.mlb_id = mlb_id
        self.debut_date = debut_date
        self.team_id = team_id
        self.team_abbrev = team_abbrev
        self.active = active
        self.bat_side = bat_side
        self.pitch_hand = pitch_hand
        self.birth_country = birth_country
        self.birth_date = birth_date
        self.current_age = current_age
        self.photo_url = photo_url

    @property
    def full_name(self):
        """Gets the full_name of this Player.  # noqa: E501


        :return: The full_name of this Player.  # noqa: E501
        :rtype: str
        """
        return self._full_name

    @full_name.setter
    def full_name(self, full_name):
        """Sets the full_name of this Player.


        :param full_name: The full_name of this Player.  # noqa: E501
        :type: str
        """
        if self.local_vars_configuration.client_side_validation and full_name is None:  # noqa: E501
            raise ValueError("Invalid value for `full_name`, must not be `None`")  # noqa: E501

        self._full_name = full_name

    @property
    def position(self):
        """Gets the position of this Player.  # noqa: E501

        Primary position.  One of P, C, 1B, 2B, 3B, SS, LF, RF, CF, LF, DH  # noqa: E501

        :return: The position of this Player.  # noqa: E501
        :rtype: str
        """
        return self._position

    @position.setter
    def position(self, position):
        """Sets the position of this Player.

        Primary position.  One of P, C, 1B, 2B, 3B, SS, LF, RF, CF, LF, DH  # noqa: E501

        :param position: The position of this Player.  # noqa: E501
        :type: str
        """
        if self.local_vars_configuration.client_side_validation and position is None:  # noqa: E501
            raise ValueError("Invalid value for `position`, must not be `None`")  # noqa: E501

        self._position = position

    @property
    def mlb_id(self):
        """Gets the mlb_id of this Player.  # noqa: E501

        MLB player ID  # noqa: E501

        :return: The mlb_id of this Player.  # noqa: E501
        :rtype: int
        """
        return self._mlb_id

    @mlb_id.setter
    def mlb_id(self, mlb_id):
        """Sets the mlb_id of this Player.

        MLB player ID  # noqa: E501

        :param mlb_id: The mlb_id of this Player.  # noqa: E501
        :type: int
        """
        if self.local_vars_configuration.client_side_validation and mlb_id is None:  # noqa: E501
            raise ValueError("Invalid value for `mlb_id`, must not be `None`")  # noqa: E501

        self._mlb_id = mlb_id

    @property
    def debut_date(self):
        """Gets the debut_date of this Player.  # noqa: E501

        MLB debut date  # noqa: E501

        :return: The debut_date of this Player.  # noqa: E501
        :rtype: str
        """
        return self._debut_date

    @debut_date.setter
    def debut_date(self, debut_date):
        """Sets the debut_date of this Player.

        MLB debut date  # noqa: E501

        :param debut_date: The debut_date of this Player.  # noqa: E501
        :type: str
        """
        if self.local_vars_configuration.client_side_validation and debut_date is None:  # noqa: E501
            raise ValueError("Invalid value for `debut_date`, must not be `None`")  # noqa: E501

        self._debut_date = debut_date

    @property
    def team_id(self):
        """Gets the team_id of this Player.  # noqa: E501


        :return: The team_id of this Player.  # noqa: E501
        :rtype: int
        """
        return self._team_id

    @team_id.setter
    def team_id(self, team_id):
        """Sets the team_id of this Player.


        :param team_id: The team_id of this Player.  # noqa: E501
        :type: int
        """
        if self.local_vars_configuration.client_side_validation and team_id is None:  # noqa: E501
            raise ValueError("Invalid value for `team_id`, must not be `None`")  # noqa: E501

        self._team_id = team_id

    @property
    def team_abbrev(self):
        """Gets the team_abbrev of this Player.  # noqa: E501


        :return: The team_abbrev of this Player.  # noqa: E501
        :rtype: str
        """
        return self._team_abbrev

    @team_abbrev.setter
    def team_abbrev(self, team_abbrev):
        """Sets the team_abbrev of this Player.


        :param team_abbrev: The team_abbrev of this Player.  # noqa: E501
        :type: str
        """
        if self.local_vars_configuration.client_side_validation and team_abbrev is None:  # noqa: E501
            raise ValueError("Invalid value for `team_abbrev`, must not be `None`")  # noqa: E501

        self._team_abbrev = team_abbrev

    @property
    def active(self):
        """Gets the active of this Player.  # noqa: E501

        True if player is currently active  # noqa: E501

        :return: The active of this Player.  # noqa: E501
        :rtype: bool
        """
        return self._active

    @active.setter
    def active(self, active):
        """Sets the active of this Player.

        True if player is currently active  # noqa: E501

        :param active: The active of this Player.  # noqa: E501
        :type: bool
        """
        if self.local_vars_configuration.client_side_validation and active is None:  # noqa: E501
            raise ValueError("Invalid value for `active`, must not be `None`")  # noqa: E501

        self._active = active

    @property
    def bat_side(self):
        """Gets the bat_side of this Player.  # noqa: E501

        One of L, R, S  # noqa: E501

        :return: The bat_side of this Player.  # noqa: E501
        :rtype: str
        """
        return self._bat_side

    @bat_side.setter
    def bat_side(self, bat_side):
        """Sets the bat_side of this Player.

        One of L, R, S  # noqa: E501

        :param bat_side: The bat_side of this Player.  # noqa: E501
        :type: str
        """
        if self.local_vars_configuration.client_side_validation and bat_side is None:  # noqa: E501
            raise ValueError("Invalid value for `bat_side`, must not be `None`")  # noqa: E501

        self._bat_side = bat_side

    @property
    def pitch_hand(self):
        """Gets the pitch_hand of this Player.  # noqa: E501

        One of L, R, S  # noqa: E501

        :return: The pitch_hand of this Player.  # noqa: E501
        :rtype: str
        """
        return self._pitch_hand

    @pitch_hand.setter
    def pitch_hand(self, pitch_hand):
        """Sets the pitch_hand of this Player.

        One of L, R, S  # noqa: E501

        :param pitch_hand: The pitch_hand of this Player.  # noqa: E501
        :type: str
        """
        if self.local_vars_configuration.client_side_validation and pitch_hand is None:  # noqa: E501
            raise ValueError("Invalid value for `pitch_hand`, must not be `None`")  # noqa: E501

        self._pitch_hand = pitch_hand

    @property
    def birth_country(self):
        """Gets the birth_country of this Player.  # noqa: E501


        :return: The birth_country of this Player.  # noqa: E501
        :rtype: str
        """
        return self._birth_country

    @birth_country.setter
    def birth_country(self, birth_country):
        """Sets the birth_country of this Player.


        :param birth_country: The birth_country of this Player.  # noqa: E501
        :type: str
        """
        if self.local_vars_configuration.client_side_validation and birth_country is None:  # noqa: E501
            raise ValueError("Invalid value for `birth_country`, must not be `None`")  # noqa: E501

        self._birth_country = birth_country

    @property
    def birth_date(self):
        """Gets the birth_date of this Player.  # noqa: E501


        :return: The birth_date of this Player.  # noqa: E501
        :rtype: str
        """
        return self._birth_date

    @birth_date.setter
    def birth_date(self, birth_date):
        """Sets the birth_date of this Player.


        :param birth_date: The birth_date of this Player.  # noqa: E501
        :type: str
        """
        if self.local_vars_configuration.client_side_validation and birth_date is None:  # noqa: E501
            raise ValueError("Invalid value for `birth_date`, must not be `None`")  # noqa: E501

        self._birth_date = birth_date

    @property
    def current_age(self):
        """Gets the current_age of this Player.  # noqa: E501


        :return: The current_age of this Player.  # noqa: E501
        :rtype: int
        """
        return self._current_age

    @current_age.setter
    def current_age(self, current_age):
        """Sets the current_age of this Player.


        :param current_age: The current_age of this Player.  # noqa: E501
        :type: int
        """
        if self.local_vars_configuration.client_side_validation and current_age is None:  # noqa: E501
            raise ValueError("Invalid value for `current_age`, must not be `None`")  # noqa: E501

        self._current_age = current_age

    @property
    def photo_url(self):
        """Gets the photo_url of this Player.  # noqa: E501


        :return: The photo_url of this Player.  # noqa: E501
        :rtype: str
        """
        return self._photo_url

    @photo_url.setter
    def photo_url(self, photo_url):
        """Sets the photo_url of this Player.


        :param photo_url: The photo_url of this Player.  # noqa: E501
        :type: str
        """
        if self.local_vars_configuration.client_side_validation and photo_url is None:  # noqa: E501
            raise ValueError("Invalid value for `photo_url`, must not be `None`")  # noqa: E501

        self._photo_url = photo_url

    def to_dict(self):
        """Returns the model properties as a dict"""
        result = {}

        for attr, _ in six.iteritems(self.openapi_types):
            value = getattr(self, attr)
            if isinstance(value, list):
                result[attr] = list(map(
                    lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
                    value
                ))
            elif hasattr(value, "to_dict"):
                result[attr] = value.to_dict()
            elif isinstance(value, dict):
                result[attr] = dict(map(
                    lambda item: (item[0], item[1].to_dict())
                    if hasattr(item[1], "to_dict") else item,
                    value.items()
                ))
            else:
                result[attr] = value

        return result

    def to_str(self):
        """Returns the string representation of the model"""
        return pprint.pformat(self.to_dict())

    def __repr__(self):
        """For `print` and `pprint`"""
        return self.to_str()

    def __eq__(self, other):
        """Returns true if both objects are equal"""
        if not isinstance(other, Player):
            return False

        return self.to_dict() == other.to_dict()

    def __ne__(self, other):
        """Returns true if both objects are not equal"""
        if not isinstance(other, Player):
            return True

        return self.to_dict() != other.to_dict()
