# coding: utf-8

"""
    ocrapi

    The powerful Optical Character Recognition (OCR) APIs let you convert scanned images of pages into recognized text.  # noqa: E501

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


import pprint
import re  # noqa: F401

import six


class FormTableDefinition(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 = {
        'table_id': 'str',
        'column_definitions': 'list[FormTableColumnDefinition]',
        'target_table_height_relative': 'float',
        'target_row_height_relative': 'float'
    }

    attribute_map = {
        'table_id': 'TableID',
        'column_definitions': 'ColumnDefinitions',
        'target_table_height_relative': 'TargetTableHeight_Relative',
        'target_row_height_relative': 'TargetRowHeight_Relative'
    }

    def __init__(self, table_id=None, column_definitions=None, target_table_height_relative=None, target_row_height_relative=None):  # noqa: E501
        """FormTableDefinition - a model defined in Swagger"""  # noqa: E501

        self._table_id = None
        self._column_definitions = None
        self._target_table_height_relative = None
        self._target_row_height_relative = None
        self.discriminator = None

        if table_id is not None:
            self.table_id = table_id
        if column_definitions is not None:
            self.column_definitions = column_definitions
        if target_table_height_relative is not None:
            self.target_table_height_relative = target_table_height_relative
        if target_row_height_relative is not None:
            self.target_row_height_relative = target_row_height_relative

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

        Optional; the ID of the table  # noqa: E501

        :return: The table_id of this FormTableDefinition.  # noqa: E501
        :rtype: str
        """
        return self._table_id

    @table_id.setter
    def table_id(self, table_id):
        """Sets the table_id of this FormTableDefinition.

        Optional; the ID of the table  # noqa: E501

        :param table_id: The table_id of this FormTableDefinition.  # noqa: E501
        :type: str
        """

        self._table_id = table_id

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

        Definition of the columns in the table  # noqa: E501

        :return: The column_definitions of this FormTableDefinition.  # noqa: E501
        :rtype: list[FormTableColumnDefinition]
        """
        return self._column_definitions

    @column_definitions.setter
    def column_definitions(self, column_definitions):
        """Sets the column_definitions of this FormTableDefinition.

        Definition of the columns in the table  # noqa: E501

        :param column_definitions: The column_definitions of this FormTableDefinition.  # noqa: E501
        :type: list[FormTableColumnDefinition]
        """

        self._column_definitions = column_definitions

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

        Optional - scale factor for target table height - relative to maximum height of headers of columns  # noqa: E501

        :return: The target_table_height_relative of this FormTableDefinition.  # noqa: E501
        :rtype: float
        """
        return self._target_table_height_relative

    @target_table_height_relative.setter
    def target_table_height_relative(self, target_table_height_relative):
        """Sets the target_table_height_relative of this FormTableDefinition.

        Optional - scale factor for target table height - relative to maximum height of headers of columns  # noqa: E501

        :param target_table_height_relative: The target_table_height_relative of this FormTableDefinition.  # noqa: E501
        :type: float
        """

        self._target_table_height_relative = target_table_height_relative

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

        Optional - scale factor for target row height - relative to height of column header  # noqa: E501

        :return: The target_row_height_relative of this FormTableDefinition.  # noqa: E501
        :rtype: float
        """
        return self._target_row_height_relative

    @target_row_height_relative.setter
    def target_row_height_relative(self, target_row_height_relative):
        """Sets the target_row_height_relative of this FormTableDefinition.

        Optional - scale factor for target row height - relative to height of column header  # noqa: E501

        :param target_row_height_relative: The target_row_height_relative of this FormTableDefinition.  # noqa: E501
        :type: float
        """

        self._target_row_height_relative = target_row_height_relative

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

        return self.__dict__ == other.__dict__

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