# coding: utf-8

"""
    communications-sms

    These APIs ensures an easy integration process of SMS management for developers to send, read, and track SMS histories within applications.  # noqa: E501

    OpenAPI spec version: 1.0.0
    
    Generated by: phenom
"""

import pprint
import re  # noqa: F401

import six

class SMSHistoryPagination(object):
    """
    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 = {
        'first': 'bool',
        'last': 'bool',
        'has_errors': 'bool',
        'has_next': 'bool',
        'total_elements': 'int',
        'total_pages': 'int',
        'size': 'int',
        'current_page': 'int',
        'number_of_elements': 'int'
    }

    attribute_map = {
        'first': 'first',
        'last': 'last',
        'has_errors': 'hasErrors',
        'has_next': 'hasNext',
        'total_elements': 'totalElements',
        'total_pages': 'totalPages',
        'size': 'size',
        'current_page': 'currentPage',
        'number_of_elements': 'numberOfElements'
    }

    def __init__(self, first=None, last=None, has_errors=None, has_next=None, total_elements=None, total_pages=None, size=None, current_page=None, number_of_elements=None):  # noqa: E501
        """SMSHistoryPagination - a model defined in Swagger"""  # noqa: E501
        self._first = None
        self._last = None
        self._has_errors = None
        self._has_next = None
        self._total_elements = None
        self._total_pages = None
        self._size = None
        self._current_page = None
        self._number_of_elements = None
        self.discriminator = None
        self.first = first
        self.last = last
        self.has_errors = has_errors
        self.has_next = has_next
        self.total_elements = total_elements
        self.total_pages = total_pages
        self.size = size
        self.current_page = current_page
        self.number_of_elements = number_of_elements

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

        Indicates the first page in the pagination.  # noqa: E501

        :return: The first of this SMSHistoryPagination.  # noqa: E501
        :rtype: bool
        """
        return self._first

    @first.setter
    def first(self, first):
        """Sets the first of this SMSHistoryPagination.

        Indicates the first page in the pagination.  # noqa: E501

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

        self._first = first

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

        Indicates last page in the pagination.  # noqa: E501

        :return: The last of this SMSHistoryPagination.  # noqa: E501
        :rtype: bool
        """
        return self._last

    @last.setter
    def last(self, last):
        """Sets the last of this SMSHistoryPagination.

        Indicates last page in the pagination.  # noqa: E501

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

        self._last = last

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

        Indicates whether there are errors in the pagination.  # noqa: E501

        :return: The has_errors of this SMSHistoryPagination.  # noqa: E501
        :rtype: bool
        """
        return self._has_errors

    @has_errors.setter
    def has_errors(self, has_errors):
        """Sets the has_errors of this SMSHistoryPagination.

        Indicates whether there are errors in the pagination.  # noqa: E501

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

        self._has_errors = has_errors

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

        Indicates whether there is a next page in the pagination.  # noqa: E501

        :return: The has_next of this SMSHistoryPagination.  # noqa: E501
        :rtype: bool
        """
        return self._has_next

    @has_next.setter
    def has_next(self, has_next):
        """Sets the has_next of this SMSHistoryPagination.

        Indicates whether there is a next page in the pagination.  # noqa: E501

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

        self._has_next = has_next

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

        Total number of elements across all pages.  # noqa: E501

        :return: The total_elements of this SMSHistoryPagination.  # noqa: E501
        :rtype: int
        """
        return self._total_elements

    @total_elements.setter
    def total_elements(self, total_elements):
        """Sets the total_elements of this SMSHistoryPagination.

        Total number of elements across all pages.  # noqa: E501

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

        self._total_elements = total_elements

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

        Total number of pages in the pagination.  # noqa: E501

        :return: The total_pages of this SMSHistoryPagination.  # noqa: E501
        :rtype: int
        """
        return self._total_pages

    @total_pages.setter
    def total_pages(self, total_pages):
        """Sets the total_pages of this SMSHistoryPagination.

        Total number of pages in the pagination.  # noqa: E501

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

        self._total_pages = total_pages

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

        Number of elements in the current page.  # noqa: E501

        :return: The size of this SMSHistoryPagination.  # noqa: E501
        :rtype: int
        """
        return self._size

    @size.setter
    def size(self, size):
        """Sets the size of this SMSHistoryPagination.

        Number of elements in the current page.  # noqa: E501

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

        self._size = size

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

        The current page number.  # noqa: E501

        :return: The current_page of this SMSHistoryPagination.  # noqa: E501
        :rtype: int
        """
        return self._current_page

    @current_page.setter
    def current_page(self, current_page):
        """Sets the current_page of this SMSHistoryPagination.

        The current page number.  # noqa: E501

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

        self._current_page = current_page

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

        Number of elements in the current page.  # noqa: E501

        :return: The number_of_elements of this SMSHistoryPagination.  # noqa: E501
        :rtype: int
        """
        return self._number_of_elements

    @number_of_elements.setter
    def number_of_elements(self, number_of_elements):
        """Sets the number_of_elements of this SMSHistoryPagination.

        Number of elements in the current page.  # noqa: E501

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

        self._number_of_elements = number_of_elements

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

        return self.__dict__ == other.__dict__

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