# coding: utf-8

"""
    Welcome to the Atera API

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

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


import pprint
import re  # noqa: F401

import six

from atera_client.configuration import Configuration


class CustomValueQueryDTO(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 = {
        "item_id": "int",
        "id": "str",
        "field_name": "str",
        "value_as_string": "str",
        "value_as_decimal": "float",
        "value_as_date_time": "datetime",
        "value_as_bool": "bool",
    }

    attribute_map = {
        "item_id": "ItemId",
        "id": "Id",
        "field_name": "FieldName",
        "value_as_string": "ValueAsString",
        "value_as_decimal": "ValueAsDecimal",
        "value_as_date_time": "ValueAsDateTime",
        "value_as_bool": "ValueAsBool",
    }

    def __init__(
        self,
        item_id=None,
        id=None,
        field_name=None,
        value_as_string=None,
        value_as_decimal=None,
        value_as_date_time=None,
        value_as_bool=None,
        _configuration=None,
    ):  # noqa: E501
        """CustomValueQueryDTO - a model defined in Swagger"""  # noqa: E501
        if _configuration is None:
            _configuration = Configuration()
        self._configuration = _configuration

        self._item_id = None
        self._id = None
        self._field_name = None
        self._value_as_string = None
        self._value_as_decimal = None
        self._value_as_date_time = None
        self._value_as_bool = None
        self.discriminator = None

        if item_id is not None:
            self.item_id = item_id
        if id is not None:
            self.id = id
        if field_name is not None:
            self.field_name = field_name
        if value_as_string is not None:
            self.value_as_string = value_as_string
        if value_as_decimal is not None:
            self.value_as_decimal = value_as_decimal
        if value_as_date_time is not None:
            self.value_as_date_time = value_as_date_time
        if value_as_bool is not None:
            self.value_as_bool = value_as_bool

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


        :return: The item_id of this CustomValueQueryDTO.  # noqa: E501
        :rtype: int
        """
        return self._item_id

    @item_id.setter
    def item_id(self, item_id):
        """Sets the item_id of this CustomValueQueryDTO.


        :param item_id: The item_id of this CustomValueQueryDTO.  # noqa: E501
        :type: int
        """

        self._item_id = item_id

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


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

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


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

        self._id = id

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


        :return: The field_name of this CustomValueQueryDTO.  # noqa: E501
        :rtype: str
        """
        return self._field_name

    @field_name.setter
    def field_name(self, field_name):
        """Sets the field_name of this CustomValueQueryDTO.


        :param field_name: The field_name of this CustomValueQueryDTO.  # noqa: E501
        :type: str
        """

        self._field_name = field_name

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


        :return: The value_as_string of this CustomValueQueryDTO.  # noqa: E501
        :rtype: str
        """
        return self._value_as_string

    @value_as_string.setter
    def value_as_string(self, value_as_string):
        """Sets the value_as_string of this CustomValueQueryDTO.


        :param value_as_string: The value_as_string of this CustomValueQueryDTO.  # noqa: E501
        :type: str
        """

        self._value_as_string = value_as_string

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


        :return: The value_as_decimal of this CustomValueQueryDTO.  # noqa: E501
        :rtype: float
        """
        return self._value_as_decimal

    @value_as_decimal.setter
    def value_as_decimal(self, value_as_decimal):
        """Sets the value_as_decimal of this CustomValueQueryDTO.


        :param value_as_decimal: The value_as_decimal of this CustomValueQueryDTO.  # noqa: E501
        :type: float
        """

        self._value_as_decimal = value_as_decimal

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


        :return: The value_as_date_time of this CustomValueQueryDTO.  # noqa: E501
        :rtype: datetime
        """
        return self._value_as_date_time

    @value_as_date_time.setter
    def value_as_date_time(self, value_as_date_time):
        """Sets the value_as_date_time of this CustomValueQueryDTO.


        :param value_as_date_time: The value_as_date_time of this CustomValueQueryDTO.  # noqa: E501
        :type: datetime
        """

        self._value_as_date_time = value_as_date_time

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


        :return: The value_as_bool of this CustomValueQueryDTO.  # noqa: E501
        :rtype: bool
        """
        return self._value_as_bool

    @value_as_bool.setter
    def value_as_bool(self, value_as_bool):
        """Sets the value_as_bool of this CustomValueQueryDTO.


        :param value_as_bool: The value_as_bool of this CustomValueQueryDTO.  # noqa: E501
        :type: bool
        """

        self._value_as_bool = value_as_bool

    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(CustomValueQueryDTO, 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, CustomValueQueryDTO):
            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, CustomValueQueryDTO):
            return True

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