# coding: utf-8

"""
    Lists

    No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)  # noqa: E501

    The version of the OpenAPI document: v3
    Generated by: https://openapi-generator.tech
"""


try:
    from inspect import getfullargspec
except ImportError:
    from inspect import getargspec as getfullargspec
import pprint
import re  # noqa: F401
import six

from hubspot.crm.lists.configuration import Configuration


class PublicIndexedTimePoint(object):
    """NOTE: This class is auto generated by OpenAPI Generator.
    Ref: https://openapi-generator.tech

    Do not edit the class manually.
    """

    """
    Attributes:
      openapi_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.
    """
    openapi_types = {"offset": "PublicIndexOffset", "timezone_source": "str", "index_reference": "PublicIndexedTimePointIndexReference", "time_type": "str", "zone_id": "str"}

    attribute_map = {"offset": "offset", "timezone_source": "timezoneSource", "index_reference": "indexReference", "time_type": "timeType", "zone_id": "zoneId"}

    def __init__(self, offset=None, timezone_source=None, index_reference=None, time_type="INDEXED", zone_id=None, local_vars_configuration=None):  # noqa: E501
        """PublicIndexedTimePoint - a model defined in OpenAPI"""  # noqa: E501
        if local_vars_configuration is None:
            local_vars_configuration = Configuration.get_default_copy()
        self.local_vars_configuration = local_vars_configuration

        self._offset = None
        self._timezone_source = None
        self._index_reference = None
        self._time_type = None
        self._zone_id = None
        self.discriminator = None

        if offset is not None:
            self.offset = offset
        if timezone_source is not None:
            self.timezone_source = timezone_source
        self.index_reference = index_reference
        self.time_type = time_type
        self.zone_id = zone_id

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


        :return: The offset of this PublicIndexedTimePoint.  # noqa: E501
        :rtype: PublicIndexOffset
        """
        return self._offset

    @offset.setter
    def offset(self, offset):
        """Sets the offset of this PublicIndexedTimePoint.


        :param offset: The offset of this PublicIndexedTimePoint.  # noqa: E501
        :type offset: PublicIndexOffset
        """

        self._offset = offset

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


        :return: The timezone_source of this PublicIndexedTimePoint.  # noqa: E501
        :rtype: str
        """
        return self._timezone_source

    @timezone_source.setter
    def timezone_source(self, timezone_source):
        """Sets the timezone_source of this PublicIndexedTimePoint.


        :param timezone_source: The timezone_source of this PublicIndexedTimePoint.  # noqa: E501
        :type timezone_source: str
        """

        self._timezone_source = timezone_source

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


        :return: The index_reference of this PublicIndexedTimePoint.  # noqa: E501
        :rtype: PublicIndexedTimePointIndexReference
        """
        return self._index_reference

    @index_reference.setter
    def index_reference(self, index_reference):
        """Sets the index_reference of this PublicIndexedTimePoint.


        :param index_reference: The index_reference of this PublicIndexedTimePoint.  # noqa: E501
        :type index_reference: PublicIndexedTimePointIndexReference
        """
        if self.local_vars_configuration.client_side_validation and index_reference is None:  # noqa: E501
            raise ValueError("Invalid value for `index_reference`, must not be `None`")  # noqa: E501

        self._index_reference = index_reference

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


        :return: The time_type of this PublicIndexedTimePoint.  # noqa: E501
        :rtype: str
        """
        return self._time_type

    @time_type.setter
    def time_type(self, time_type):
        """Sets the time_type of this PublicIndexedTimePoint.


        :param time_type: The time_type of this PublicIndexedTimePoint.  # noqa: E501
        :type time_type: str
        """
        if self.local_vars_configuration.client_side_validation and time_type is None:  # noqa: E501
            raise ValueError("Invalid value for `time_type`, must not be `None`")  # noqa: E501
        allowed_values = ["INDEXED"]  # noqa: E501
        if self.local_vars_configuration.client_side_validation and time_type not in allowed_values:  # noqa: E501
            raise ValueError("Invalid value for `time_type` ({0}), must be one of {1}".format(time_type, allowed_values))  # noqa: E501

        self._time_type = time_type

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


        :return: The zone_id of this PublicIndexedTimePoint.  # noqa: E501
        :rtype: str
        """
        return self._zone_id

    @zone_id.setter
    def zone_id(self, zone_id):
        """Sets the zone_id of this PublicIndexedTimePoint.


        :param zone_id: The zone_id of this PublicIndexedTimePoint.  # noqa: E501
        :type zone_id: str
        """
        if self.local_vars_configuration.client_side_validation and zone_id is None:  # noqa: E501
            raise ValueError("Invalid value for `zone_id`, must not be `None`")  # noqa: E501

        self._zone_id = zone_id

    def to_dict(self, serialize=False):
        """Returns the model properties as a dict"""
        result = {}

        def convert(x):
            if hasattr(x, "to_dict"):
                args = getfullargspec(x.to_dict).args
                if len(args) == 1:
                    return x.to_dict()
                else:
                    return x.to_dict(serialize)
            else:
                return x

        for attr, _ in six.iteritems(self.openapi_types):
            value = getattr(self, attr)
            attr = self.attribute_map.get(attr, attr) if serialize else attr
            if isinstance(value, list):
                result[attr] = list(map(lambda x: convert(x), value))
            elif isinstance(value, dict):
                result[attr] = dict(map(lambda item: (item[0], convert(item[1])), value.items()))
            else:
                result[attr] = convert(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, PublicIndexedTimePoint):
            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, PublicIndexedTimePoint):
            return True

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