# coding: utf-8

from datetime import date, datetime  # noqa: F401

from typing import List, Dict  # noqa: F401

from swagger_server.models.base_model_ import Model
from swagger_server import util


class Todo(Model):
    """NOTE: This class is auto generated by the swagger code generator program.

    Do not edit the class manually.
    """

    def __init__(
        self,
        id: int = None,
        name: str = None,
        description: str = None,
        due_date: date = None,
        status: str = None,
    ):  # noqa: E501
        """Todo - a model defined in Swagger

        :param id: The id of this Todo.  # noqa: E501
        :type id: int
        :param name: The name of this Todo.  # noqa: E501
        :type name: str
        :param description: The description of this Todo.  # noqa: E501
        :type description: str
        :param due_date: The due_date of this Todo.  # noqa: E501
        :type due_date: date
        :param status: The status of this Todo.  # noqa: E501
        :type status: str
        """
        self.swagger_types = {
            "id": int,
            "name": str,
            "description": str,
            "due_date": date,
            "status": str,
        }

        self.attribute_map = {
            "id": "id",
            "name": "name",
            "description": "description",
            "due_date": "dueDate",
            "status": "status",
        }

        self._id = id
        self._name = name
        self._description = description
        self._due_date = due_date
        self._status = status

    @classmethod
    def from_dict(cls, dikt) -> "Todo":
        """Returns the dict as a model

        :param dikt: A dict.
        :type: dict
        :return: The Todo of this Todo.  # noqa: E501
        :rtype: Todo
        """
        return util.deserialize_model(dikt, cls)

    @property
    def id(self) -> int:
        """Gets the id of this Todo.


        :return: The id of this Todo.
        :rtype: int
        """
        return self._id

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


        :param id: The id of this Todo.
        :type id: int
        """

        self._id = id

    @property
    def name(self) -> str:
        """Gets the name of this Todo.


        :return: The name of this Todo.
        :rtype: str
        """
        return self._name

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


        :param name: The name of this Todo.
        :type name: str
        """

        self._name = name

    @property
    def description(self) -> str:
        """Gets the description of this Todo.


        :return: The description of this Todo.
        :rtype: str
        """
        return self._description

    @description.setter
    def description(self, description: str):
        """Sets the description of this Todo.


        :param description: The description of this Todo.
        :type description: str
        """

        self._description = description

    @property
    def due_date(self) -> date:
        """Gets the due_date of this Todo.


        :return: The due_date of this Todo.
        :rtype: date
        """
        return self._due_date

    @due_date.setter
    def due_date(self, due_date: date):
        """Sets the due_date of this Todo.


        :param due_date: The due_date of this Todo.
        :type due_date: date
        """

        self._due_date = due_date

    @property
    def status(self) -> str:
        """Gets the status of this Todo.

        to-do Status  # noqa: E501

        :return: The status of this Todo.
        :rtype: str
        """
        return self._status

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

        to-do Status  # noqa: E501

        :param status: The status of this Todo.
        :type status: str
        """
        allowed_values = ["done", "late", "in progress", "to do"]  # noqa: E501
        if status not in allowed_values:
            raise ValueError(
                "Invalid value for `status` ({0}), must be one of {1}".format(
                    status, allowed_values
                )
            )

        self._status = status
