# coding: utf-8

"""
    Lotus API

    Lotus is an open-core pricing and billing engine. We enable API companies to automate and optimize their custom usage-based pricing for any metric.  # noqa: E501

    OpenAPI spec version: 0.9.3
    
    Generated by: https://github.com/swagger-api/swagger-codegen.git
"""

import pprint
import re  # noqa: F401

import six

class PriceAdjustment(object):
    """NOTE: This class is auto generated by the swagger code generator program.

    Do not edit the class manually.
    """
    """
    Attributes:
      swagger_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.
    """
    swagger_types = {
        'price_adjustment_name': 'str',
        'price_adjustment_description': 'str',
        'price_adjustment_type': 'str',
        'price_adjustment_amount': 'float'
    }

    attribute_map = {
        'price_adjustment_name': 'price_adjustment_name',
        'price_adjustment_description': 'price_adjustment_description',
        'price_adjustment_type': 'price_adjustment_type',
        'price_adjustment_amount': 'price_adjustment_amount'
    }

    def __init__(self, price_adjustment_name=None, price_adjustment_description=None, price_adjustment_type=None, price_adjustment_amount=None):  # noqa: E501
        """PriceAdjustment - a model defined in Swagger"""  # noqa: E501
        self._price_adjustment_name = None
        self._price_adjustment_description = None
        self._price_adjustment_type = None
        self._price_adjustment_amount = None
        self.discriminator = None
        self.price_adjustment_name = price_adjustment_name
        self.price_adjustment_description = price_adjustment_description
        self.price_adjustment_type = price_adjustment_type
        self.price_adjustment_amount = price_adjustment_amount

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


        :return: The price_adjustment_name of this PriceAdjustment.  # noqa: E501
        :rtype: str
        """
        return self._price_adjustment_name

    @price_adjustment_name.setter
    def price_adjustment_name(self, price_adjustment_name):
        """Sets the price_adjustment_name of this PriceAdjustment.


        :param price_adjustment_name: The price_adjustment_name of this PriceAdjustment.  # noqa: E501
        :type: str
        """
        if price_adjustment_name is None:
            raise ValueError("Invalid value for `price_adjustment_name`, must not be `None`")  # noqa: E501

        self._price_adjustment_name = price_adjustment_name

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


        :return: The price_adjustment_description of this PriceAdjustment.  # noqa: E501
        :rtype: str
        """
        return self._price_adjustment_description

    @price_adjustment_description.setter
    def price_adjustment_description(self, price_adjustment_description):
        """Sets the price_adjustment_description of this PriceAdjustment.


        :param price_adjustment_description: The price_adjustment_description of this PriceAdjustment.  # noqa: E501
        :type: str
        """
        if price_adjustment_description is None:
            raise ValueError("Invalid value for `price_adjustment_description`, must not be `None`")  # noqa: E501

        self._price_adjustment_description = price_adjustment_description

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

        * `percentage` - Percentage * `fixed` - Fixed * `price_override` - Price Override  # noqa: E501

        :return: The price_adjustment_type of this PriceAdjustment.  # noqa: E501
        :rtype: str
        """
        return self._price_adjustment_type

    @price_adjustment_type.setter
    def price_adjustment_type(self, price_adjustment_type):
        """Sets the price_adjustment_type of this PriceAdjustment.

        * `percentage` - Percentage * `fixed` - Fixed * `price_override` - Price Override  # noqa: E501

        :param price_adjustment_type: The price_adjustment_type of this PriceAdjustment.  # noqa: E501
        :type: str
        """
        if price_adjustment_type is None:
            raise ValueError("Invalid value for `price_adjustment_type`, must not be `None`")  # noqa: E501
        allowed_values = ["percentage", "fixed", "price_override"]  # noqa: E501
        if price_adjustment_type not in allowed_values:
            raise ValueError(
                "Invalid value for `price_adjustment_type` ({0}), must be one of {1}"  # noqa: E501
                .format(price_adjustment_type, allowed_values)
            )

        self._price_adjustment_type = price_adjustment_type

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


        :return: The price_adjustment_amount of this PriceAdjustment.  # noqa: E501
        :rtype: float
        """
        return self._price_adjustment_amount

    @price_adjustment_amount.setter
    def price_adjustment_amount(self, price_adjustment_amount):
        """Sets the price_adjustment_amount of this PriceAdjustment.


        :param price_adjustment_amount: The price_adjustment_amount of this PriceAdjustment.  # noqa: E501
        :type: float
        """
        if price_adjustment_amount is None:
            raise ValueError("Invalid value for `price_adjustment_amount`, must not be `None`")  # noqa: E501

        self._price_adjustment_amount = price_adjustment_amount

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

        for attr, _ in six.iteritems(self.swagger_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
        if issubclass(PriceAdjustment, dict):
            for key, value in self.items():
                result[key] = 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, PriceAdjustment):
            return False

        return self.__dict__ == other.__dict__

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