# coding: utf-8

"""
    paddlehelix_dev

    No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)  # noqa: E501

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


import pprint
import re  # noqa: F401

import six

from paddlehelix.configuration import Configuration


class GetVoucherListResponseDataItems(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 = {
        'id': 'int',
        'admin_id': 'bool',
        'user_id': 'int',
        'task_type': 'int',
        'amount': 'float',
        'rest_amount': 'float',
        'status': 'int',
        'start_time': 'int',
        'end_time': 'int'
    }

    attribute_map = {
        'id': 'id',
        'admin_id': 'admin_id',
        'user_id': 'user_id',
        'task_type': 'task_type',
        'amount': 'amount',
        'rest_amount': 'rest_amount',
        'status': 'status',
        'start_time': 'start_time',
        'end_time': 'end_time'
    }

    def __init__(self, id=None, admin_id=None, user_id=None, task_type=None, amount=None, rest_amount=None, status=None, start_time=None, end_time=None, local_vars_configuration=None):  # noqa: E501
        """GetVoucherListResponseDataItems - 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._id = None
        self._admin_id = None
        self._user_id = None
        self._task_type = None
        self._amount = None
        self._rest_amount = None
        self._status = None
        self._start_time = None
        self._end_time = None
        self.discriminator = None

        self.id = id
        self.admin_id = admin_id
        self.user_id = user_id
        self.task_type = task_type
        self.amount = amount
        self.rest_amount = rest_amount
        self.status = status
        self.start_time = start_time
        self.end_time = end_time

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

        点券ID  # noqa: E501

        :return: The id of this GetVoucherListResponseDataItems.  # noqa: E501
        :rtype: int
        """
        return self._id

    @id.setter
    def id(self, id):
        """Sets the id of this GetVoucherListResponseDataItems.

        点券ID  # noqa: E501

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

        self._id = id

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

        授予点券的管理员ID  # noqa: E501

        :return: The admin_id of this GetVoucherListResponseDataItems.  # noqa: E501
        :rtype: bool
        """
        return self._admin_id

    @admin_id.setter
    def admin_id(self, admin_id):
        """Sets the admin_id of this GetVoucherListResponseDataItems.

        授予点券的管理员ID  # noqa: E501

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

        self._admin_id = admin_id

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

        用户ID  # noqa: E501

        :return: The user_id of this GetVoucherListResponseDataItems.  # noqa: E501
        :rtype: int
        """
        return self._user_id

    @user_id.setter
    def user_id(self, user_id):
        """Sets the user_id of this GetVoucherListResponseDataItems.

        用户ID  # noqa: E501

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

        self._user_id = user_id

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

        适用任务类型 0代表适用全部  # noqa: E501

        :return: The task_type of this GetVoucherListResponseDataItems.  # noqa: E501
        :rtype: int
        """
        return self._task_type

    @task_type.setter
    def task_type(self, task_type):
        """Sets the task_type of this GetVoucherListResponseDataItems.

        适用任务类型 0代表适用全部  # noqa: E501

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

        self._task_type = task_type

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

        总数  # noqa: E501

        :return: The amount of this GetVoucherListResponseDataItems.  # noqa: E501
        :rtype: float
        """
        return self._amount

    @amount.setter
    def amount(self, amount):
        """Sets the amount of this GetVoucherListResponseDataItems.

        总数  # noqa: E501

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

        self._amount = amount

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

        剩余数  # noqa: E501

        :return: The rest_amount of this GetVoucherListResponseDataItems.  # noqa: E501
        :rtype: float
        """
        return self._rest_amount

    @rest_amount.setter
    def rest_amount(self, rest_amount):
        """Sets the rest_amount of this GetVoucherListResponseDataItems.

        剩余数  # noqa: E501

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

        self._rest_amount = rest_amount

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

        状态 10:正常 1:停用 -1:删除  # noqa: E501

        :return: The status of this GetVoucherListResponseDataItems.  # noqa: E501
        :rtype: int
        """
        return self._status

    @status.setter
    def status(self, status):
        """Sets the status of this GetVoucherListResponseDataItems.

        状态 10:正常 1:停用 -1:删除  # noqa: E501

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

        self._status = status

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

        生效时间  # noqa: E501

        :return: The start_time of this GetVoucherListResponseDataItems.  # noqa: E501
        :rtype: int
        """
        return self._start_time

    @start_time.setter
    def start_time(self, start_time):
        """Sets the start_time of this GetVoucherListResponseDataItems.

        生效时间  # noqa: E501

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

        self._start_time = start_time

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

        失效时间  # noqa: E501

        :return: The end_time of this GetVoucherListResponseDataItems.  # noqa: E501
        :rtype: int
        """
        return self._end_time

    @end_time.setter
    def end_time(self, end_time):
        """Sets the end_time of this GetVoucherListResponseDataItems.

        失效时间  # noqa: E501

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

        self._end_time = end_time

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

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