# coding: utf-8

"""
    Allegro REST API

    https://developer.allegro.pl/about  # noqa: E501

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


import pprint
import re  # noqa: F401

import six

from allegro_api.configuration import Configuration


class MyBidResponse(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 = {
        'max_amount': 'MaxPrice',
        'minimal_price_met': 'bool',
        'high_bidder': 'bool',
        'auction': 'AuctionDetails'
    }

    attribute_map = {
        'max_amount': 'maxAmount',
        'minimal_price_met': 'minimalPriceMet',
        'high_bidder': 'highBidder',
        'auction': 'auction'
    }

    def __init__(self, max_amount=None, minimal_price_met=None, high_bidder=None, auction=None, local_vars_configuration=None):  # noqa: E501
        """MyBidResponse - 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._max_amount = None
        self._minimal_price_met = None
        self._high_bidder = None
        self._auction = None
        self.discriminator = None

        self.max_amount = max_amount
        if minimal_price_met is not None:
            self.minimal_price_met = minimal_price_met
        self.high_bidder = high_bidder
        self.auction = auction

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


        :return: The max_amount of this MyBidResponse.  # noqa: E501
        :rtype: MaxPrice
        """
        return self._max_amount

    @max_amount.setter
    def max_amount(self, max_amount):
        """Sets the max_amount of this MyBidResponse.


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

        self._max_amount = max_amount

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

        This indicates if the minimal price of the auction has been met or is not set at all. A minimal price can be set by the seller and is the minimum amount the seller is willing to sell the item for. If the highest bid is not higher than the minimal price when the auction ends, the listing ends and the item is not sold.  # noqa: E501

        :return: The minimal_price_met of this MyBidResponse.  # noqa: E501
        :rtype: bool
        """
        return self._minimal_price_met

    @minimal_price_met.setter
    def minimal_price_met(self, minimal_price_met):
        """Sets the minimal_price_met of this MyBidResponse.

        This indicates if the minimal price of the auction has been met or is not set at all. A minimal price can be set by the seller and is the minimum amount the seller is willing to sell the item for. If the highest bid is not higher than the minimal price when the auction ends, the listing ends and the item is not sold.  # noqa: E501

        :param minimal_price_met: The minimal_price_met of this MyBidResponse.  # noqa: E501
        :type: bool
        """

        self._minimal_price_met = minimal_price_met

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

        Is this bid currently winning?  # noqa: E501

        :return: The high_bidder of this MyBidResponse.  # noqa: E501
        :rtype: bool
        """
        return self._high_bidder

    @high_bidder.setter
    def high_bidder(self, high_bidder):
        """Sets the high_bidder of this MyBidResponse.

        Is this bid currently winning?  # noqa: E501

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

        self._high_bidder = high_bidder

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


        :return: The auction of this MyBidResponse.  # noqa: E501
        :rtype: AuctionDetails
        """
        return self._auction

    @auction.setter
    def auction(self, auction):
        """Sets the auction of this MyBidResponse.


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

        self._auction = auction

    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, MyBidResponse):
            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, MyBidResponse):
            return True

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