# coding: utf-8

"""
    vault/kernel/core_api/proto/v1/accounts/core_api_account_schedule_tags.proto

    No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)  # noqa: E501

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

import pprint
import re  # noqa: F401

import six

class BalancesBalance(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 = {
        'id': 'str',
        'account_id': 'str',
        'account_address': 'str',
        'phase': 'V1PostingPhase',
        'asset': 'str',
        'denomination': 'str',
        'posting_instruction_batch_id': 'str',
        'update_posting_instruction_batch_id': 'str',
        'value_time': 'datetime',
        'amount': 'str',
        'total_debit': 'str',
        'total_credit': 'str'
    }

    attribute_map = {
        'id': 'id',
        'account_id': 'account_id',
        'account_address': 'account_address',
        'phase': 'phase',
        'asset': 'asset',
        'denomination': 'denomination',
        'posting_instruction_batch_id': 'posting_instruction_batch_id',
        'update_posting_instruction_batch_id': 'update_posting_instruction_batch_id',
        'value_time': 'value_time',
        'amount': 'amount',
        'total_debit': 'total_debit',
        'total_credit': 'total_credit'
    }

    def __init__(self, id=None, account_id=None, account_address=None, phase=None, asset=None, denomination=None, posting_instruction_batch_id=None, update_posting_instruction_batch_id=None, value_time=None, amount=None, total_debit=None, total_credit=None):  # noqa: E501
        """BalancesBalance - a model defined in Swagger"""  # noqa: E501
        self._id = None
        self._account_id = None
        self._account_address = None
        self._phase = None
        self._asset = None
        self._denomination = None
        self._posting_instruction_batch_id = None
        self._update_posting_instruction_batch_id = None
        self._value_time = None
        self._amount = None
        self._total_debit = None
        self._total_credit = None
        self.discriminator = None
        if id is not None:
            self.id = id
        if account_id is not None:
            self.account_id = account_id
        if account_address is not None:
            self.account_address = account_address
        if phase is not None:
            self.phase = phase
        if asset is not None:
            self.asset = asset
        if denomination is not None:
            self.denomination = denomination
        if posting_instruction_batch_id is not None:
            self.posting_instruction_batch_id = posting_instruction_batch_id
        if update_posting_instruction_batch_id is not None:
            self.update_posting_instruction_batch_id = update_posting_instruction_batch_id
        if value_time is not None:
            self.value_time = value_time
        if amount is not None:
            self.amount = amount
        if total_debit is not None:
            self.total_debit = total_debit
        if total_credit is not None:
            self.total_credit = total_credit

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

        The ID of the balance. Output only.  # noqa: E501

        :return: The id of this BalancesBalance.  # noqa: E501
        :rtype: str
        """
        return self._id

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

        The ID of the balance. Output only.  # noqa: E501

        :param id: The id of this BalancesBalance.  # noqa: E501
        :type: str
        """

        self._id = id

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

        The ID of the associated account.  # noqa: E501

        :return: The account_id of this BalancesBalance.  # noqa: E501
        :rtype: str
        """
        return self._account_id

    @account_id.setter
    def account_id(self, account_id):
        """Sets the account_id of this BalancesBalance.

        The ID of the associated account.  # noqa: E501

        :param account_id: The account_id of this BalancesBalance.  # noqa: E501
        :type: str
        """

        self._account_id = account_id

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

        The account address represents one partition of the total balances held on the account.  # noqa: E501

        :return: The account_address of this BalancesBalance.  # noqa: E501
        :rtype: str
        """
        return self._account_address

    @account_address.setter
    def account_address(self, account_address):
        """Sets the account_address of this BalancesBalance.

        The account address represents one partition of the total balances held on the account.  # noqa: E501

        :param account_address: The account_address of this BalancesBalance.  # noqa: E501
        :type: str
        """

        self._account_address = account_address

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


        :return: The phase of this BalancesBalance.  # noqa: E501
        :rtype: V1PostingPhase
        """
        return self._phase

    @phase.setter
    def phase(self, phase):
        """Sets the phase of this BalancesBalance.


        :param phase: The phase of this BalancesBalance.  # noqa: E501
        :type: V1PostingPhase
        """

        self._phase = phase

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

        The asset in which the balance is held.  # noqa: E501

        :return: The asset of this BalancesBalance.  # noqa: E501
        :rtype: str
        """
        return self._asset

    @asset.setter
    def asset(self, asset):
        """Sets the asset of this BalancesBalance.

        The asset in which the balance is held.  # noqa: E501

        :param asset: The asset of this BalancesBalance.  # noqa: E501
        :type: str
        """

        self._asset = asset

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

        The denomination in which the balance is held for the given asset.  # noqa: E501

        :return: The denomination of this BalancesBalance.  # noqa: E501
        :rtype: str
        """
        return self._denomination

    @denomination.setter
    def denomination(self, denomination):
        """Sets the denomination of this BalancesBalance.

        The denomination in which the balance is held for the given asset.  # noqa: E501

        :param denomination: The denomination of this BalancesBalance.  # noqa: E501
        :type: str
        """

        self._denomination = denomination

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

        The ID of the logical posting instruction batch which yielded this balance.  # noqa: E501

        :return: The posting_instruction_batch_id of this BalancesBalance.  # noqa: E501
        :rtype: str
        """
        return self._posting_instruction_batch_id

    @posting_instruction_batch_id.setter
    def posting_instruction_batch_id(self, posting_instruction_batch_id):
        """Sets the posting_instruction_batch_id of this BalancesBalance.

        The ID of the logical posting instruction batch which yielded this balance.  # noqa: E501

        :param posting_instruction_batch_id: The posting_instruction_batch_id of this BalancesBalance.  # noqa: E501
        :type: str
        """

        self._posting_instruction_batch_id = posting_instruction_batch_id

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

        A backdated posting will lead to new balance entries for every existing balance with a later value_time. The update_posting_instruction_batch_id refers to the backdated posting that has caused such an update to the logical balance entry, if any.  # noqa: E501

        :return: The update_posting_instruction_batch_id of this BalancesBalance.  # noqa: E501
        :rtype: str
        """
        return self._update_posting_instruction_batch_id

    @update_posting_instruction_batch_id.setter
    def update_posting_instruction_batch_id(self, update_posting_instruction_batch_id):
        """Sets the update_posting_instruction_batch_id of this BalancesBalance.

        A backdated posting will lead to new balance entries for every existing balance with a later value_time. The update_posting_instruction_batch_id refers to the backdated posting that has caused such an update to the logical balance entry, if any.  # noqa: E501

        :param update_posting_instruction_batch_id: The update_posting_instruction_batch_id of this BalancesBalance.  # noqa: E501
        :type: str
        """

        self._update_posting_instruction_batch_id = update_posting_instruction_batch_id

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

        The value time corresponding to that of the posting instruction batch ID in RFC 3339 format.  # noqa: E501

        :return: The value_time of this BalancesBalance.  # noqa: E501
        :rtype: datetime
        """
        return self._value_time

    @value_time.setter
    def value_time(self, value_time):
        """Sets the value_time of this BalancesBalance.

        The value time corresponding to that of the posting instruction batch ID in RFC 3339 format.  # noqa: E501

        :param value_time: The value_time of this BalancesBalance.  # noqa: E501
        :type: datetime
        """

        self._value_time = value_time

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

        The amount is the net value of the balance.  # noqa: E501

        :return: The amount of this BalancesBalance.  # noqa: E501
        :rtype: str
        """
        return self._amount

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

        The amount is the net value of the balance.  # noqa: E501

        :param amount: The amount of this BalancesBalance.  # noqa: E501
        :type: str
        """

        self._amount = amount

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

        The total sum of debits.  # noqa: E501

        :return: The total_debit of this BalancesBalance.  # noqa: E501
        :rtype: str
        """
        return self._total_debit

    @total_debit.setter
    def total_debit(self, total_debit):
        """Sets the total_debit of this BalancesBalance.

        The total sum of debits.  # noqa: E501

        :param total_debit: The total_debit of this BalancesBalance.  # noqa: E501
        :type: str
        """

        self._total_debit = total_debit

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

        The total sum of credits.  # noqa: E501

        :return: The total_credit of this BalancesBalance.  # noqa: E501
        :rtype: str
        """
        return self._total_credit

    @total_credit.setter
    def total_credit(self, total_credit):
        """Sets the total_credit of this BalancesBalance.

        The total sum of credits.  # noqa: E501

        :param total_credit: The total_credit of this BalancesBalance.  # noqa: E501
        :type: str
        """

        self._total_credit = total_credit

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

        return self.__dict__ == other.__dict__

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