# coding: utf-8

from __future__ import absolute_import
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 UserSiteRole(Model):
    """NOTE: This class is auto generated by the swagger code generator program.

    Do not edit the class manually.
    """

    def __init__(self, user_id: str=None, site_id: int=None, role_id: int=None, created_at: datetime=None, updated_at: datetime=None):  # noqa: E501
        """UserSiteRole - a model defined in Swagger

        :param user_id: The user_id of this UserSiteRole.  # noqa: E501
        :type user_id: str
        :param site_id: The site_id of this UserSiteRole.  # noqa: E501
        :type site_id: int
        :param role_id: The role_id of this UserSiteRole.  # noqa: E501
        :type role_id: int
        :param created_at: The created_at of this UserSiteRole.  # noqa: E501
        :type created_at: datetime
        :param updated_at: The updated_at of this UserSiteRole.  # noqa: E501
        :type updated_at: datetime
        """
        self.swagger_types = {
            'user_id': str,
            'site_id': int,
            'role_id': int,
            'created_at': datetime,
            'updated_at': datetime
        }

        self.attribute_map = {
            'user_id': 'user_id',
            'site_id': 'site_id',
            'role_id': 'role_id',
            'created_at': 'created_at',
            'updated_at': 'updated_at'
        }

        self._user_id = user_id
        self._site_id = site_id
        self._role_id = role_id
        self._created_at = created_at
        self._updated_at = updated_at

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

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

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


        :return: The user_id of this UserSiteRole.
        :rtype: str
        """
        return self._user_id

    @user_id.setter
    def user_id(self, user_id: str):
        """Sets the user_id of this UserSiteRole.


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

        self._user_id = user_id

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


        :return: The site_id of this UserSiteRole.
        :rtype: int
        """
        return self._site_id

    @site_id.setter
    def site_id(self, site_id: int):
        """Sets the site_id of this UserSiteRole.


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

        self._site_id = site_id

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


        :return: The role_id of this UserSiteRole.
        :rtype: int
        """
        return self._role_id

    @role_id.setter
    def role_id(self, role_id: int):
        """Sets the role_id of this UserSiteRole.


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

        self._role_id = role_id

    @property
    def created_at(self) -> datetime:
        """Gets the created_at of this UserSiteRole.


        :return: The created_at of this UserSiteRole.
        :rtype: datetime
        """
        return self._created_at

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


        :param created_at: The created_at of this UserSiteRole.
        :type created_at: 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) -> datetime:
        """Gets the updated_at of this UserSiteRole.


        :return: The updated_at of this UserSiteRole.
        :rtype: datetime
        """
        return self._updated_at

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


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

        self._updated_at = updated_at
