# 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 DomainRoles(Model):
    """NOTE: This class is auto generated by the swagger code generator program.

    Do not edit the class manually.
    """

    def __init__(self, domain_id: int=None, roles_map: Dict[str, List[int]]=None):  # noqa: E501
        """DomainRoles - a model defined in Swagger

        :param domain_id: The domain_id of this DomainRoles.  # noqa: E501
        :type domain_id: int
        :param roles_map: The roles_map of this DomainRoles.  # noqa: E501
        :type roles_map: Dict[str, List[int]]
        """
        self.swagger_types = {
            'domain_id': int,
            'roles_map': Dict[str, List[int]]
        }

        self.attribute_map = {
            'domain_id': 'domain_id',
            'roles_map': 'roles_map'
        }

        self._domain_id = domain_id
        self._roles_map = roles_map

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

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

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

        The domain for which the request was made.  # noqa: E501

        :return: The domain_id of this DomainRoles.
        :rtype: int
        """
        return self._domain_id

    @domain_id.setter
    def domain_id(self, domain_id: int):
        """Sets the domain_id of this DomainRoles.

        The domain for which the request was made.  # noqa: E501

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

        self._domain_id = domain_id

    @property
    def roles_map(self) -> Dict[str, List[int]]:
        """Gets the roles_map of this DomainRoles.

        A dictionary where the keys are domain ids prefixed with `d:` and the values are lists of role ids.  # noqa: E501

        :return: The roles_map of this DomainRoles.
        :rtype: Dict[str, List[int]]
        """
        return self._roles_map

    @roles_map.setter
    def roles_map(self, roles_map: Dict[str, List[int]]):
        """Sets the roles_map of this DomainRoles.

        A dictionary where the keys are domain ids prefixed with `d:` and the values are lists of role ids.  # noqa: E501

        :param roles_map: The roles_map of this DomainRoles.
        :type roles_map: Dict[str, List[int]]
        """
        if roles_map is None:
            raise ValueError("Invalid value for `roles_map`, must not be `None`")  # noqa: E501

        self._roles_map = roles_map
