# coding: utf-8

"""
    XMS API

    XMS is the controller of distributed storage system  # noqa: E501

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


import pprint
import re  # noqa: F401
import six


class ObjectStorageBucketStat(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 = {
        'allocated_objects': 'int',
        'allocated_size': 'int',
        'create': 'datetime',
        'del_ops_pm': 'float',
        'down_latency_us': 'float',
        'latency_down': 'int',
        'latency_up': 'int',
        'num_down': 'int',
        'num_up': 'int',
        'rx_bandwidth_kbyte': 'float',
        'rx_ops_pm': 'float',
        'total_del_ops': 'int',
        'total_del_success_ops': 'int',
        'total_rx_bytes': 'int',
        'total_rx_ops': 'int',
        'total_rx_success_ops': 'int',
        'total_tx_bytes': 'int',
        'total_tx_ops': 'int',
        'total_tx_success_ops': 'int',
        'tx_bandwidth_kbyte': 'float',
        'tx_ops_pm': 'float',
        'up_latency_us': 'float'
    }

    attribute_map = {
        'allocated_objects': 'allocated_objects',
        'allocated_size': 'allocated_size',
        'create': 'create',
        'del_ops_pm': 'del_ops_pm',
        'down_latency_us': 'down_latency_us',
        'latency_down': 'latency_down',
        'latency_up': 'latency_up',
        'num_down': 'num_down',
        'num_up': 'num_up',
        'rx_bandwidth_kbyte': 'rx_bandwidth_kbyte',
        'rx_ops_pm': 'rx_ops_pm',
        'total_del_ops': 'total_del_ops',
        'total_del_success_ops': 'total_del_success_ops',
        'total_rx_bytes': 'total_rx_bytes',
        'total_rx_ops': 'total_rx_ops',
        'total_rx_success_ops': 'total_rx_success_ops',
        'total_tx_bytes': 'total_tx_bytes',
        'total_tx_ops': 'total_tx_ops',
        'total_tx_success_ops': 'total_tx_success_ops',
        'tx_bandwidth_kbyte': 'tx_bandwidth_kbyte',
        'tx_ops_pm': 'tx_ops_pm',
        'up_latency_us': 'up_latency_us'
    }

    def __init__(self, allocated_objects=None, allocated_size=None, create=None, del_ops_pm=None, down_latency_us=None, latency_down=None, latency_up=None, num_down=None, num_up=None, rx_bandwidth_kbyte=None, rx_ops_pm=None, total_del_ops=None, total_del_success_ops=None, total_rx_bytes=None, total_rx_ops=None, total_rx_success_ops=None, total_tx_bytes=None, total_tx_ops=None, total_tx_success_ops=None, tx_bandwidth_kbyte=None, tx_ops_pm=None, up_latency_us=None):  # noqa: E501
        """ObjectStorageBucketStat - a model defined in Swagger"""  # noqa: E501

        self._allocated_objects = None
        self._allocated_size = None
        self._create = None
        self._del_ops_pm = None
        self._down_latency_us = None
        self._latency_down = None
        self._latency_up = None
        self._num_down = None
        self._num_up = None
        self._rx_bandwidth_kbyte = None
        self._rx_ops_pm = None
        self._total_del_ops = None
        self._total_del_success_ops = None
        self._total_rx_bytes = None
        self._total_rx_ops = None
        self._total_rx_success_ops = None
        self._total_tx_bytes = None
        self._total_tx_ops = None
        self._total_tx_success_ops = None
        self._tx_bandwidth_kbyte = None
        self._tx_ops_pm = None
        self._up_latency_us = None
        self.discriminator = None

        if allocated_objects is not None:
            self.allocated_objects = allocated_objects
        if allocated_size is not None:
            self.allocated_size = allocated_size
        if create is not None:
            self.create = create
        if del_ops_pm is not None:
            self.del_ops_pm = del_ops_pm
        if down_latency_us is not None:
            self.down_latency_us = down_latency_us
        if latency_down is not None:
            self.latency_down = latency_down
        if latency_up is not None:
            self.latency_up = latency_up
        if num_down is not None:
            self.num_down = num_down
        if num_up is not None:
            self.num_up = num_up
        if rx_bandwidth_kbyte is not None:
            self.rx_bandwidth_kbyte = rx_bandwidth_kbyte
        if rx_ops_pm is not None:
            self.rx_ops_pm = rx_ops_pm
        if total_del_ops is not None:
            self.total_del_ops = total_del_ops
        if total_del_success_ops is not None:
            self.total_del_success_ops = total_del_success_ops
        if total_rx_bytes is not None:
            self.total_rx_bytes = total_rx_bytes
        if total_rx_ops is not None:
            self.total_rx_ops = total_rx_ops
        if total_rx_success_ops is not None:
            self.total_rx_success_ops = total_rx_success_ops
        if total_tx_bytes is not None:
            self.total_tx_bytes = total_tx_bytes
        if total_tx_ops is not None:
            self.total_tx_ops = total_tx_ops
        if total_tx_success_ops is not None:
            self.total_tx_success_ops = total_tx_success_ops
        if tx_bandwidth_kbyte is not None:
            self.tx_bandwidth_kbyte = tx_bandwidth_kbyte
        if tx_ops_pm is not None:
            self.tx_ops_pm = tx_ops_pm
        if up_latency_us is not None:
            self.up_latency_us = up_latency_us

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


        :return: The allocated_objects of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: int
        """
        return self._allocated_objects

    @allocated_objects.setter
    def allocated_objects(self, allocated_objects):
        """Sets the allocated_objects of this ObjectStorageBucketStat.


        :param allocated_objects: The allocated_objects of this ObjectStorageBucketStat.  # noqa: E501
        :type: int
        """

        self._allocated_objects = allocated_objects

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


        :return: The allocated_size of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: int
        """
        return self._allocated_size

    @allocated_size.setter
    def allocated_size(self, allocated_size):
        """Sets the allocated_size of this ObjectStorageBucketStat.


        :param allocated_size: The allocated_size of this ObjectStorageBucketStat.  # noqa: E501
        :type: int
        """

        self._allocated_size = allocated_size

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


        :return: The create of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: datetime
        """
        return self._create

    @create.setter
    def create(self, create):
        """Sets the create of this ObjectStorageBucketStat.


        :param create: The create of this ObjectStorageBucketStat.  # noqa: E501
        :type: datetime
        """

        self._create = create

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


        :return: The del_ops_pm of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: float
        """
        return self._del_ops_pm

    @del_ops_pm.setter
    def del_ops_pm(self, del_ops_pm):
        """Sets the del_ops_pm of this ObjectStorageBucketStat.


        :param del_ops_pm: The del_ops_pm of this ObjectStorageBucketStat.  # noqa: E501
        :type: float
        """

        self._del_ops_pm = del_ops_pm

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


        :return: The down_latency_us of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: float
        """
        return self._down_latency_us

    @down_latency_us.setter
    def down_latency_us(self, down_latency_us):
        """Sets the down_latency_us of this ObjectStorageBucketStat.


        :param down_latency_us: The down_latency_us of this ObjectStorageBucketStat.  # noqa: E501
        :type: float
        """

        self._down_latency_us = down_latency_us

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


        :return: The latency_down of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: int
        """
        return self._latency_down

    @latency_down.setter
    def latency_down(self, latency_down):
        """Sets the latency_down of this ObjectStorageBucketStat.


        :param latency_down: The latency_down of this ObjectStorageBucketStat.  # noqa: E501
        :type: int
        """

        self._latency_down = latency_down

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


        :return: The latency_up of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: int
        """
        return self._latency_up

    @latency_up.setter
    def latency_up(self, latency_up):
        """Sets the latency_up of this ObjectStorageBucketStat.


        :param latency_up: The latency_up of this ObjectStorageBucketStat.  # noqa: E501
        :type: int
        """

        self._latency_up = latency_up

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


        :return: The num_down of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: int
        """
        return self._num_down

    @num_down.setter
    def num_down(self, num_down):
        """Sets the num_down of this ObjectStorageBucketStat.


        :param num_down: The num_down of this ObjectStorageBucketStat.  # noqa: E501
        :type: int
        """

        self._num_down = num_down

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


        :return: The num_up of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: int
        """
        return self._num_up

    @num_up.setter
    def num_up(self, num_up):
        """Sets the num_up of this ObjectStorageBucketStat.


        :param num_up: The num_up of this ObjectStorageBucketStat.  # noqa: E501
        :type: int
        """

        self._num_up = num_up

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


        :return: The rx_bandwidth_kbyte of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: float
        """
        return self._rx_bandwidth_kbyte

    @rx_bandwidth_kbyte.setter
    def rx_bandwidth_kbyte(self, rx_bandwidth_kbyte):
        """Sets the rx_bandwidth_kbyte of this ObjectStorageBucketStat.


        :param rx_bandwidth_kbyte: The rx_bandwidth_kbyte of this ObjectStorageBucketStat.  # noqa: E501
        :type: float
        """

        self._rx_bandwidth_kbyte = rx_bandwidth_kbyte

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


        :return: The rx_ops_pm of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: float
        """
        return self._rx_ops_pm

    @rx_ops_pm.setter
    def rx_ops_pm(self, rx_ops_pm):
        """Sets the rx_ops_pm of this ObjectStorageBucketStat.


        :param rx_ops_pm: The rx_ops_pm of this ObjectStorageBucketStat.  # noqa: E501
        :type: float
        """

        self._rx_ops_pm = rx_ops_pm

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


        :return: The total_del_ops of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: int
        """
        return self._total_del_ops

    @total_del_ops.setter
    def total_del_ops(self, total_del_ops):
        """Sets the total_del_ops of this ObjectStorageBucketStat.


        :param total_del_ops: The total_del_ops of this ObjectStorageBucketStat.  # noqa: E501
        :type: int
        """

        self._total_del_ops = total_del_ops

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


        :return: The total_del_success_ops of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: int
        """
        return self._total_del_success_ops

    @total_del_success_ops.setter
    def total_del_success_ops(self, total_del_success_ops):
        """Sets the total_del_success_ops of this ObjectStorageBucketStat.


        :param total_del_success_ops: The total_del_success_ops of this ObjectStorageBucketStat.  # noqa: E501
        :type: int
        """

        self._total_del_success_ops = total_del_success_ops

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


        :return: The total_rx_bytes of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: int
        """
        return self._total_rx_bytes

    @total_rx_bytes.setter
    def total_rx_bytes(self, total_rx_bytes):
        """Sets the total_rx_bytes of this ObjectStorageBucketStat.


        :param total_rx_bytes: The total_rx_bytes of this ObjectStorageBucketStat.  # noqa: E501
        :type: int
        """

        self._total_rx_bytes = total_rx_bytes

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


        :return: The total_rx_ops of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: int
        """
        return self._total_rx_ops

    @total_rx_ops.setter
    def total_rx_ops(self, total_rx_ops):
        """Sets the total_rx_ops of this ObjectStorageBucketStat.


        :param total_rx_ops: The total_rx_ops of this ObjectStorageBucketStat.  # noqa: E501
        :type: int
        """

        self._total_rx_ops = total_rx_ops

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


        :return: The total_rx_success_ops of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: int
        """
        return self._total_rx_success_ops

    @total_rx_success_ops.setter
    def total_rx_success_ops(self, total_rx_success_ops):
        """Sets the total_rx_success_ops of this ObjectStorageBucketStat.


        :param total_rx_success_ops: The total_rx_success_ops of this ObjectStorageBucketStat.  # noqa: E501
        :type: int
        """

        self._total_rx_success_ops = total_rx_success_ops

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


        :return: The total_tx_bytes of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: int
        """
        return self._total_tx_bytes

    @total_tx_bytes.setter
    def total_tx_bytes(self, total_tx_bytes):
        """Sets the total_tx_bytes of this ObjectStorageBucketStat.


        :param total_tx_bytes: The total_tx_bytes of this ObjectStorageBucketStat.  # noqa: E501
        :type: int
        """

        self._total_tx_bytes = total_tx_bytes

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


        :return: The total_tx_ops of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: int
        """
        return self._total_tx_ops

    @total_tx_ops.setter
    def total_tx_ops(self, total_tx_ops):
        """Sets the total_tx_ops of this ObjectStorageBucketStat.


        :param total_tx_ops: The total_tx_ops of this ObjectStorageBucketStat.  # noqa: E501
        :type: int
        """

        self._total_tx_ops = total_tx_ops

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


        :return: The total_tx_success_ops of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: int
        """
        return self._total_tx_success_ops

    @total_tx_success_ops.setter
    def total_tx_success_ops(self, total_tx_success_ops):
        """Sets the total_tx_success_ops of this ObjectStorageBucketStat.


        :param total_tx_success_ops: The total_tx_success_ops of this ObjectStorageBucketStat.  # noqa: E501
        :type: int
        """

        self._total_tx_success_ops = total_tx_success_ops

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


        :return: The tx_bandwidth_kbyte of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: float
        """
        return self._tx_bandwidth_kbyte

    @tx_bandwidth_kbyte.setter
    def tx_bandwidth_kbyte(self, tx_bandwidth_kbyte):
        """Sets the tx_bandwidth_kbyte of this ObjectStorageBucketStat.


        :param tx_bandwidth_kbyte: The tx_bandwidth_kbyte of this ObjectStorageBucketStat.  # noqa: E501
        :type: float
        """

        self._tx_bandwidth_kbyte = tx_bandwidth_kbyte

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


        :return: The tx_ops_pm of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: float
        """
        return self._tx_ops_pm

    @tx_ops_pm.setter
    def tx_ops_pm(self, tx_ops_pm):
        """Sets the tx_ops_pm of this ObjectStorageBucketStat.


        :param tx_ops_pm: The tx_ops_pm of this ObjectStorageBucketStat.  # noqa: E501
        :type: float
        """

        self._tx_ops_pm = tx_ops_pm

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


        :return: The up_latency_us of this ObjectStorageBucketStat.  # noqa: E501
        :rtype: float
        """
        return self._up_latency_us

    @up_latency_us.setter
    def up_latency_us(self, up_latency_us):
        """Sets the up_latency_us of this ObjectStorageBucketStat.


        :param up_latency_us: The up_latency_us of this ObjectStorageBucketStat.  # noqa: E501
        :type: float
        """

        self._up_latency_us = up_latency_us

    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

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

        return self.__dict__ == other.__dict__

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