# coding: utf-8

"""
    Midgard Public API

    The Midgard Public API queries THORChain and any chains linked via the Bifröst and prepares information about the network to be readily available for public users. The API parses transaction event data from THORChain and stores them in a time-series database to make time-dependent queries easy. Midgard does not hold critical information. To interact with THORChain protocol, users should query THORNode directly.  # noqa: E501

    OpenAPI spec version: 2.31.0
    Contact: devs@thorchain.org
    Generated by: https://github.com/swagger-api/swagger-codegen.git
"""

import pprint
import re  # noqa: F401

import six

class ThornameMetadata(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 = {
        'address': 'str',
        'chain': 'str',
        'expire': 'str',
        'fund_amount': 'str',
        'memo': 'str',
        'owner': 'str',
        'registration_fee': 'str',
        'thorname': 'str',
        'tx_type': 'str'
    }

    attribute_map = {
        'address': 'address',
        'chain': 'chain',
        'expire': 'expire',
        'fund_amount': 'fundAmount',
        'memo': 'memo',
        'owner': 'owner',
        'registration_fee': 'registrationFee',
        'thorname': 'thorname',
        'tx_type': 'txType'
    }

    def __init__(self, address=None, chain=None, expire=None, fund_amount=None, memo=None, owner=None, registration_fee=None, thorname=None, tx_type=None):  # noqa: E501
        """ThornameMetadata - a model defined in Swagger"""  # noqa: E501
        self._address = None
        self._chain = None
        self._expire = None
        self._fund_amount = None
        self._memo = None
        self._owner = None
        self._registration_fee = None
        self._thorname = None
        self._tx_type = None
        self.discriminator = None
        self.address = address
        self.chain = chain
        self.expire = expire
        self.fund_amount = fund_amount
        self.memo = memo
        self.owner = owner
        self.registration_fee = registration_fee
        self.thorname = thorname
        self.tx_type = tx_type

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

        The CHAIN address thorname has been registered to.  # noqa: E501

        :return: The address of this ThornameMetadata.  # noqa: E501
        :rtype: str
        """
        return self._address

    @address.setter
    def address(self, address):
        """Sets the address of this ThornameMetadata.

        The CHAIN address thorname has been registered to.  # noqa: E501

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

        self._address = address

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

        The thorname's chain.  # noqa: E501

        :return: The chain of this ThornameMetadata.  # noqa: E501
        :rtype: str
        """
        return self._chain

    @chain.setter
    def chain(self, chain):
        """Sets the chain of this ThornameMetadata.

        The thorname's chain.  # noqa: E501

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

        self._chain = chain

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

        Int64, THORChain block height in which THORName expires.  # noqa: E501

        :return: The expire of this ThornameMetadata.  # noqa: E501
        :rtype: str
        """
        return self._expire

    @expire.setter
    def expire(self, expire):
        """Sets the expire of this ThornameMetadata.

        Int64, THORChain block height in which THORName expires.  # noqa: E501

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

        self._expire = expire

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

        Int64, the amount of funding for the THORName registration.  # noqa: E501

        :return: The fund_amount of this ThornameMetadata.  # noqa: E501
        :rtype: str
        """
        return self._fund_amount

    @fund_amount.setter
    def fund_amount(self, fund_amount):
        """Sets the fund_amount of this ThornameMetadata.

        Int64, the amount of funding for the THORName registration.  # noqa: E501

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

        self._fund_amount = fund_amount

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

        Transaction memo of thorname deposit message.  # noqa: E501

        :return: The memo of this ThornameMetadata.  # noqa: E501
        :rtype: str
        """
        return self._memo

    @memo.setter
    def memo(self, memo):
        """Sets the memo of this ThornameMetadata.

        Transaction memo of thorname deposit message.  # noqa: E501

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

        self._memo = memo

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

        owner's THOR address.  # noqa: E501

        :return: The owner of this ThornameMetadata.  # noqa: E501
        :rtype: str
        """
        return self._owner

    @owner.setter
    def owner(self, owner):
        """Sets the owner of this ThornameMetadata.

        owner's THOR address.  # noqa: E501

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

        self._owner = owner

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

        Int64, the registration fee paid.  # noqa: E501

        :return: The registration_fee of this ThornameMetadata.  # noqa: E501
        :rtype: str
        """
        return self._registration_fee

    @registration_fee.setter
    def registration_fee(self, registration_fee):
        """Sets the registration_fee of this ThornameMetadata.

        Int64, the registration fee paid.  # noqa: E501

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

        self._registration_fee = registration_fee

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

        The thorname registered to the address.  # noqa: E501

        :return: The thorname of this ThornameMetadata.  # noqa: E501
        :rtype: str
        """
        return self._thorname

    @thorname.setter
    def thorname(self, thorname):
        """Sets the thorname of this ThornameMetadata.

        The thorname registered to the address.  # noqa: E501

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

        self._thorname = thorname

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

        The type of the transaction given from its Memo.  # noqa: E501

        :return: The tx_type of this ThornameMetadata.  # noqa: E501
        :rtype: str
        """
        return self._tx_type

    @tx_type.setter
    def tx_type(self, tx_type):
        """Sets the tx_type of this ThornameMetadata.

        The type of the transaction given from its Memo.  # noqa: E501

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

        self._tx_type = tx_type

    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(ThornameMetadata, 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, ThornameMetadata):
            return False

        return self.__dict__ == other.__dict__

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