# coding: utf-8

"""
    convertapi

    Convert API lets you effortlessly convert file formats and types.  # 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 AutodetectDocumentValidationResult(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 = {
        'file_format_extension': 'str',
        'document_is_valid': 'bool',
        'error_count': 'int',
        'warning_count': 'int',
        'errors_and_warnings': 'list[DocumentValidationError]'
    }

    attribute_map = {
        'file_format_extension': 'FileFormatExtension',
        'document_is_valid': 'DocumentIsValid',
        'error_count': 'ErrorCount',
        'warning_count': 'WarningCount',
        'errors_and_warnings': 'ErrorsAndWarnings'
    }

    def __init__(self, file_format_extension=None, document_is_valid=None, error_count=None, warning_count=None, errors_and_warnings=None):  # noqa: E501
        """AutodetectDocumentValidationResult - a model defined in Swagger"""  # noqa: E501

        self._file_format_extension = None
        self._document_is_valid = None
        self._error_count = None
        self._warning_count = None
        self._errors_and_warnings = None
        self.discriminator = None

        if file_format_extension is not None:
            self.file_format_extension = file_format_extension
        if document_is_valid is not None:
            self.document_is_valid = document_is_valid
        if error_count is not None:
            self.error_count = error_count
        if warning_count is not None:
            self.warning_count = warning_count
        if errors_and_warnings is not None:
            self.errors_and_warnings = errors_and_warnings

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


        :return: The file_format_extension of this AutodetectDocumentValidationResult.  # noqa: E501
        :rtype: str
        """
        return self._file_format_extension

    @file_format_extension.setter
    def file_format_extension(self, file_format_extension):
        """Sets the file_format_extension of this AutodetectDocumentValidationResult.


        :param file_format_extension: The file_format_extension of this AutodetectDocumentValidationResult.  # noqa: E501
        :type: str
        """

        self._file_format_extension = file_format_extension

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

        True if the document is valid and has no errors, false otherwise  # noqa: E501

        :return: The document_is_valid of this AutodetectDocumentValidationResult.  # noqa: E501
        :rtype: bool
        """
        return self._document_is_valid

    @document_is_valid.setter
    def document_is_valid(self, document_is_valid):
        """Sets the document_is_valid of this AutodetectDocumentValidationResult.

        True if the document is valid and has no errors, false otherwise  # noqa: E501

        :param document_is_valid: The document_is_valid of this AutodetectDocumentValidationResult.  # noqa: E501
        :type: bool
        """

        self._document_is_valid = document_is_valid

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

        Number of validation errors found in the document  # noqa: E501

        :return: The error_count of this AutodetectDocumentValidationResult.  # noqa: E501
        :rtype: int
        """
        return self._error_count

    @error_count.setter
    def error_count(self, error_count):
        """Sets the error_count of this AutodetectDocumentValidationResult.

        Number of validation errors found in the document  # noqa: E501

        :param error_count: The error_count of this AutodetectDocumentValidationResult.  # noqa: E501
        :type: int
        """

        self._error_count = error_count

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

        Number of validation warnings found in the document  # noqa: E501

        :return: The warning_count of this AutodetectDocumentValidationResult.  # noqa: E501
        :rtype: int
        """
        return self._warning_count

    @warning_count.setter
    def warning_count(self, warning_count):
        """Sets the warning_count of this AutodetectDocumentValidationResult.

        Number of validation warnings found in the document  # noqa: E501

        :param warning_count: The warning_count of this AutodetectDocumentValidationResult.  # noqa: E501
        :type: int
        """

        self._warning_count = warning_count

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

        Details of errors and warnings found  # noqa: E501

        :return: The errors_and_warnings of this AutodetectDocumentValidationResult.  # noqa: E501
        :rtype: list[DocumentValidationError]
        """
        return self._errors_and_warnings

    @errors_and_warnings.setter
    def errors_and_warnings(self, errors_and_warnings):
        """Sets the errors_and_warnings of this AutodetectDocumentValidationResult.

        Details of errors and warnings found  # noqa: E501

        :param errors_and_warnings: The errors_and_warnings of this AutodetectDocumentValidationResult.  # noqa: E501
        :type: list[DocumentValidationError]
        """

        self._errors_and_warnings = errors_and_warnings

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

        return self.__dict__ == other.__dict__

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