# coding: utf-8

"""
    Curia Platform API

    These are the docs for the curia platform API. To test, generate an authorization token first.  # noqa: E501

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

import pprint
import re  # noqa: F401

import six

class Analysis(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 = {
        'id': 'str',
        'name': 'str',
        'type': 'AnalysisType',
        'project_id': 'str',
        'project': 'Project',
        'status': 'str',
        'models': 'list[Model]',
        'model_batches': 'list[ModelBatch]',
        'processes': 'list[Process]',
        'analysis_jobs': 'list[AnalysisJob]',
        'last_updated_by': 'str',
        'created_by': 'str',
        'created_at': 'datetime',
        'updated_at': 'datetime',
        'version': 'float'
    }

    attribute_map = {
        'id': 'id',
        'name': 'name',
        'type': 'type',
        'project_id': 'projectId',
        'project': 'project',
        'status': 'status',
        'models': 'models',
        'model_batches': 'modelBatches',
        'processes': 'processes',
        'analysis_jobs': 'analysisJobs',
        'last_updated_by': 'lastUpdatedBy',
        'created_by': 'createdBy',
        'created_at': 'createdAt',
        'updated_at': 'updatedAt',
        'version': 'version'
    }

    def __init__(self, id=None, name=None, type=None, project_id=None, project=None, status=None, models=None, model_batches=None, processes=None, analysis_jobs=None, last_updated_by=None, created_by=None, created_at=None, updated_at=None, version=None):  # noqa: E501
        """Analysis - a model defined in Swagger"""  # noqa: E501
        self._id = None
        self._name = None
        self._type = None
        self._project_id = None
        self._project = None
        self._status = None
        self._models = None
        self._model_batches = None
        self._processes = None
        self._analysis_jobs = None
        self._last_updated_by = None
        self._created_by = None
        self._created_at = None
        self._updated_at = None
        self._version = None
        self.discriminator = None
        self.id = id
        self.name = name
        self.type = type
        self.project_id = project_id
        if project is not None:
            self.project = project
        self.status = status
        if models is not None:
            self.models = models
        if model_batches is not None:
            self.model_batches = model_batches
        if processes is not None:
            self.processes = processes
        if analysis_jobs is not None:
            self.analysis_jobs = analysis_jobs
        self.last_updated_by = last_updated_by
        self.created_by = created_by
        self.created_at = created_at
        self.updated_at = updated_at
        if version is not None:
            self.version = version

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


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

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


        :param id: The id of this Analysis.  # noqa: E501
        :type: str
        """
        if id is None:
            raise ValueError("Invalid value for `id`, must not be `None`")  # noqa: E501

        self._id = id

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


        :return: The name of this Analysis.  # noqa: E501
        :rtype: str
        """
        return self._name

    @name.setter
    def name(self, name):
        """Sets the name of this Analysis.


        :param name: The name of this Analysis.  # noqa: E501
        :type: str
        """
        if name is None:
            raise ValueError("Invalid value for `name`, must not be `None`")  # noqa: E501

        self._name = name

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


        :return: The type of this Analysis.  # noqa: E501
        :rtype: AnalysisType
        """
        return self._type

    @type.setter
    def type(self, type):
        """Sets the type of this Analysis.


        :param type: The type of this Analysis.  # noqa: E501
        :type: AnalysisType
        """
        if type is None:
            raise ValueError("Invalid value for `type`, must not be `None`")  # noqa: E501

        self._type = type

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


        :return: The project_id of this Analysis.  # noqa: E501
        :rtype: str
        """
        return self._project_id

    @project_id.setter
    def project_id(self, project_id):
        """Sets the project_id of this Analysis.


        :param project_id: The project_id of this Analysis.  # noqa: E501
        :type: str
        """
        if project_id is None:
            raise ValueError("Invalid value for `project_id`, must not be `None`")  # noqa: E501

        self._project_id = project_id

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


        :return: The project of this Analysis.  # noqa: E501
        :rtype: Project
        """
        return self._project

    @project.setter
    def project(self, project):
        """Sets the project of this Analysis.


        :param project: The project of this Analysis.  # noqa: E501
        :type: Project
        """

        self._project = project

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


        :return: The status of this Analysis.  # noqa: E501
        :rtype: str
        """
        return self._status

    @status.setter
    def status(self, status):
        """Sets the status of this Analysis.


        :param status: The status of this Analysis.  # noqa: E501
        :type: str
        """
        if status is None:
            raise ValueError("Invalid value for `status`, must not be `None`")  # noqa: E501

        self._status = status

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


        :return: The models of this Analysis.  # noqa: E501
        :rtype: list[Model]
        """
        return self._models

    @models.setter
    def models(self, models):
        """Sets the models of this Analysis.


        :param models: The models of this Analysis.  # noqa: E501
        :type: list[Model]
        """

        self._models = models

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


        :return: The model_batches of this Analysis.  # noqa: E501
        :rtype: list[ModelBatch]
        """
        return self._model_batches

    @model_batches.setter
    def model_batches(self, model_batches):
        """Sets the model_batches of this Analysis.


        :param model_batches: The model_batches of this Analysis.  # noqa: E501
        :type: list[ModelBatch]
        """

        self._model_batches = model_batches

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


        :return: The processes of this Analysis.  # noqa: E501
        :rtype: list[Process]
        """
        return self._processes

    @processes.setter
    def processes(self, processes):
        """Sets the processes of this Analysis.


        :param processes: The processes of this Analysis.  # noqa: E501
        :type: list[Process]
        """

        self._processes = processes

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


        :return: The analysis_jobs of this Analysis.  # noqa: E501
        :rtype: list[AnalysisJob]
        """
        return self._analysis_jobs

    @analysis_jobs.setter
    def analysis_jobs(self, analysis_jobs):
        """Sets the analysis_jobs of this Analysis.


        :param analysis_jobs: The analysis_jobs of this Analysis.  # noqa: E501
        :type: list[AnalysisJob]
        """

        self._analysis_jobs = analysis_jobs

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


        :return: The last_updated_by of this Analysis.  # noqa: E501
        :rtype: str
        """
        return self._last_updated_by

    @last_updated_by.setter
    def last_updated_by(self, last_updated_by):
        """Sets the last_updated_by of this Analysis.


        :param last_updated_by: The last_updated_by of this Analysis.  # noqa: E501
        :type: str
        """
        if last_updated_by is None:
            raise ValueError("Invalid value for `last_updated_by`, must not be `None`")  # noqa: E501

        self._last_updated_by = last_updated_by

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


        :return: The created_by of this Analysis.  # noqa: E501
        :rtype: str
        """
        return self._created_by

    @created_by.setter
    def created_by(self, created_by):
        """Sets the created_by of this Analysis.


        :param created_by: The created_by of this Analysis.  # noqa: E501
        :type: str
        """
        if created_by is None:
            raise ValueError("Invalid value for `created_by`, must not be `None`")  # noqa: E501

        self._created_by = created_by

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


        :return: The created_at of this Analysis.  # noqa: E501
        :rtype: datetime
        """
        return self._created_at

    @created_at.setter
    def created_at(self, created_at):
        """Sets the created_at of this Analysis.


        :param created_at: The created_at of this Analysis.  # noqa: E501
        :type: datetime
        """
        if created_at is None:
            raise ValueError("Invalid value for `created_at`, must not be `None`")  # noqa: E501

        self._created_at = created_at

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


        :return: The updated_at of this Analysis.  # noqa: E501
        :rtype: datetime
        """
        return self._updated_at

    @updated_at.setter
    def updated_at(self, updated_at):
        """Sets the updated_at of this Analysis.


        :param updated_at: The updated_at of this Analysis.  # noqa: E501
        :type: datetime
        """
        if updated_at is None:
            raise ValueError("Invalid value for `updated_at`, must not be `None`")  # noqa: E501

        self._updated_at = updated_at

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


        :return: The version of this Analysis.  # noqa: E501
        :rtype: float
        """
        return self._version

    @version.setter
    def version(self, version):
        """Sets the version of this Analysis.


        :param version: The version of this Analysis.  # noqa: E501
        :type: float
        """

        self._version = version

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

        return self.__dict__ == other.__dict__

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