# coding: utf-8

"""
    Seeq REST API

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

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

from pprint import pformat
from six import iteritems
import re


class ColumnDefinitionOutputV1(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 = {
        'column_name': 'str',
        'column_type': 'str',
        'column_uom': 'str',
        'id': 'str',
        'is_indexed': 'bool',
        'rules': 'list[ColumnRule]'
    }

    attribute_map = {
        'column_name': 'columnName',
        'column_type': 'columnType',
        'column_uom': 'columnUom',
        'id': 'id',
        'is_indexed': 'isIndexed',
        'rules': 'rules'
    }

    def __init__(self, column_name=None, column_type=None, column_uom=None, id=None, is_indexed=None, rules=None):
        """
        ColumnDefinitionOutputV1 - a model defined in Swagger
        """

        self._column_name = None
        self._column_type = None
        self._column_uom = None
        self._id = None
        self._is_indexed = None
        self._rules = None

        if column_name is not None:
          self.column_name = column_name
        if column_type is not None:
          self.column_type = column_type
        if column_uom is not None:
          self.column_uom = column_uom
        if id is not None:
          self.id = id
        if is_indexed is not None:
          self.is_indexed = is_indexed
        if rules is not None:
          self.rules = rules

    @property
    def column_name(self):
        """
        Gets the column_name of this ColumnDefinitionOutputV1.
        The column definition's name

        :return: The column_name of this ColumnDefinitionOutputV1.
        :rtype: str
        """
        return self._column_name

    @column_name.setter
    def column_name(self, column_name):
        """
        Sets the column_name of this ColumnDefinitionOutputV1.
        The column definition's name

        :param column_name: The column_name of this ColumnDefinitionOutputV1.
        :type: str
        """

        self._column_name = column_name

    @property
    def column_type(self):
        """
        Gets the column_type of this ColumnDefinitionOutputV1.
        The column definition's type

        :return: The column_type of this ColumnDefinitionOutputV1.
        :rtype: str
        """
        return self._column_type

    @column_type.setter
    def column_type(self, column_type):
        """
        Sets the column_type of this ColumnDefinitionOutputV1.
        The column definition's type

        :param column_type: The column_type of this ColumnDefinitionOutputV1.
        :type: str
        """
        allowed_values = ["UUID", "TEXT", "NUMERIC", "TIMESTAMPTZ", "BOOLEAN"]
        if column_type not in allowed_values:
            raise ValueError(
                "Invalid value for `column_type` ({0}), must be one of {1}"
                .format(column_type, allowed_values)
            )

        self._column_type = column_type

    @property
    def column_uom(self):
        """
        Gets the column_uom of this ColumnDefinitionOutputV1.
        The column definition's Unit of Measure

        :return: The column_uom of this ColumnDefinitionOutputV1.
        :rtype: str
        """
        return self._column_uom

    @column_uom.setter
    def column_uom(self, column_uom):
        """
        Sets the column_uom of this ColumnDefinitionOutputV1.
        The column definition's Unit of Measure

        :param column_uom: The column_uom of this ColumnDefinitionOutputV1.
        :type: str
        """

        self._column_uom = column_uom

    @property
    def id(self):
        """
        Gets the id of this ColumnDefinitionOutputV1.
        The column definition's ID

        :return: The id of this ColumnDefinitionOutputV1.
        :rtype: str
        """
        return self._id

    @id.setter
    def id(self, id):
        """
        Sets the id of this ColumnDefinitionOutputV1.
        The column definition's ID

        :param id: The id of this ColumnDefinitionOutputV1.
        :type: str
        """

        self._id = id

    @property
    def is_indexed(self):
        """
        Gets the is_indexed of this ColumnDefinitionOutputV1.
        Whether the column is indexed

        :return: The is_indexed of this ColumnDefinitionOutputV1.
        :rtype: bool
        """
        return self._is_indexed

    @is_indexed.setter
    def is_indexed(self, is_indexed):
        """
        Sets the is_indexed of this ColumnDefinitionOutputV1.
        Whether the column is indexed

        :param is_indexed: The is_indexed of this ColumnDefinitionOutputV1.
        :type: bool
        """

        self._is_indexed = is_indexed

    @property
    def rules(self):
        """
        Gets the rules of this ColumnDefinitionOutputV1.
        The rules associated with the column definition

        :return: The rules of this ColumnDefinitionOutputV1.
        :rtype: list[ColumnRule]
        """
        return self._rules

    @rules.setter
    def rules(self, rules):
        """
        Sets the rules of this ColumnDefinitionOutputV1.
        The rules associated with the column definition

        :param rules: The rules of this ColumnDefinitionOutputV1.
        :type: list[ColumnRule]
        """

        self._rules = rules

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

        for attr, _ in 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 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, ColumnDefinitionOutputV1):
            return False

        return self.__dict__ == other.__dict__

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