# coding: utf-8

"""
    Cyclos 4.11.5 API

    The REST API for Cyclos 4.11.5  # noqa: E501

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


import pprint
import re  # noqa: F401

import six

from swagger_client.configuration import Configuration


class VoucherBoughtResult(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 = {
        'vouchers': 'list[str]',
        'voucher_status': 'VoucherStatusEnum'
    }

    attribute_map = {
        'vouchers': 'vouchers',
        'voucher_status': 'voucherStatus'
    }

    def __init__(self, vouchers=None, voucher_status=None, _configuration=None):  # noqa: E501
        """VoucherBoughtResult - a model defined in Swagger"""  # noqa: E501
        if _configuration is None:
            _configuration = Configuration()
        self._configuration = _configuration

        self._vouchers = None
        self._voucher_status = None
        self.discriminator = None

        if vouchers is not None:
            self.vouchers = vouchers
        if voucher_status is not None:
            self.voucher_status = voucher_status

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

        The identifiers of all bought vouchers.  # noqa: E501

        :return: The vouchers of this VoucherBoughtResult.  # noqa: E501
        :rtype: list[str]
        """
        return self._vouchers

    @vouchers.setter
    def vouchers(self, vouchers):
        """Sets the vouchers of this VoucherBoughtResult.

        The identifiers of all bought vouchers.  # noqa: E501

        :param vouchers: The vouchers of this VoucherBoughtResult.  # noqa: E501
        :type: list[str]
        """

        self._vouchers = vouchers

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

        The status of all bought vouchers. Possible values are: * canceled: The voucher was canceled, and cannot be further used * expired: The voucher has expired without being redeemed * open: The voucher has been generated / bought, and is open * pending: The voucher has been bought, and the corresponding payment is pending for authorization * redeemed: The voucher has been redeemed, and the corresponding payment was done   # noqa: E501

        :return: The voucher_status of this VoucherBoughtResult.  # noqa: E501
        :rtype: VoucherStatusEnum
        """
        return self._voucher_status

    @voucher_status.setter
    def voucher_status(self, voucher_status):
        """Sets the voucher_status of this VoucherBoughtResult.

        The status of all bought vouchers. Possible values are: * canceled: The voucher was canceled, and cannot be further used * expired: The voucher has expired without being redeemed * open: The voucher has been generated / bought, and is open * pending: The voucher has been bought, and the corresponding payment is pending for authorization * redeemed: The voucher has been redeemed, and the corresponding payment was done   # noqa: E501

        :param voucher_status: The voucher_status of this VoucherBoughtResult.  # noqa: E501
        :type: VoucherStatusEnum
        """

        self._voucher_status = voucher_status

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

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