# coding: utf-8
"""
    external/v1/auth_service.proto

    No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)  # noqa: E501

    OpenAPI spec version: version not set

    Generated by: https://github.com/swagger-api/swagger-codegen.git

    NOTE
    ----
    standard swagger-codegen-cli for this python client has been modified
    by custom templates. The purpose of these templates is to include
    typing information in the API and Model code. Please refer to the
    main grid repository for more info
"""

import pprint
import re  # noqa: F401
from typing import TYPE_CHECKING

import six

from cricket_cookie.openapi.configuration import Configuration

if TYPE_CHECKING:
    from datetime import datetime
    from cricket_cookie.openapi.models import *


class V1Membership(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 = {
        'active_experiments_count': 'str',
        'active_sessions_count': 'str',
        'balance': 'float',
        'created_at': 'datetime',
        'datastore_count': 'str',
        'description': 'str',
        'membership_count': 'str',
        'name': 'str',
        'project_id': 'str',
        'roles': 'list[V1Role]',
        'updated_at': 'datetime',
        'user_id': 'str'
    }

    attribute_map = {
        'active_experiments_count': 'activeExperimentsCount',
        'active_sessions_count': 'activeSessionsCount',
        'balance': 'balance',
        'created_at': 'createdAt',
        'datastore_count': 'datastoreCount',
        'description': 'description',
        'membership_count': 'membershipCount',
        'name': 'name',
        'project_id': 'projectId',
        'roles': 'roles',
        'updated_at': 'updatedAt',
        'user_id': 'userId'
    }

    def __init__(self,
                 active_experiments_count: 'str' = None,
                 active_sessions_count: 'str' = None,
                 balance: 'float' = None,
                 created_at: 'datetime' = None,
                 datastore_count: 'str' = None,
                 description: 'str' = None,
                 membership_count: 'str' = None,
                 name: 'str' = None,
                 project_id: 'str' = None,
                 roles: 'list[V1Role]' = None,
                 updated_at: 'datetime' = None,
                 user_id: 'str' = None,
                 _configuration=None):  # noqa: E501
        """V1Membership - a model defined in Swagger"""  # noqa: E501
        if _configuration is None:
            _configuration = Configuration()
        self._configuration = _configuration

        self._active_experiments_count = None
        self._active_sessions_count = None
        self._balance = None
        self._created_at = None
        self._datastore_count = None
        self._description = None
        self._membership_count = None
        self._name = None
        self._project_id = None
        self._roles = None
        self._updated_at = None
        self._user_id = None
        self.discriminator = None

        if active_experiments_count is not None:
            self.active_experiments_count = active_experiments_count
        if active_sessions_count is not None:
            self.active_sessions_count = active_sessions_count
        if balance is not None:
            self.balance = balance
        if created_at is not None:
            self.created_at = created_at
        if datastore_count is not None:
            self.datastore_count = datastore_count
        if description is not None:
            self.description = description
        if membership_count is not None:
            self.membership_count = membership_count
        if name is not None:
            self.name = name
        if project_id is not None:
            self.project_id = project_id
        if roles is not None:
            self.roles = roles
        if updated_at is not None:
            self.updated_at = updated_at
        if user_id is not None:
            self.user_id = user_id

    @property
    def active_experiments_count(self) -> 'str':
        """Gets the active_experiments_count of this V1Membership.  # noqa: E501


        :return: The active_experiments_count of this V1Membership.  # noqa: E501
        :rtype: str
        """
        return self._active_experiments_count

    @active_experiments_count.setter
    def active_experiments_count(self, active_experiments_count: 'str'):
        """Sets the active_experiments_count of this V1Membership.


        :param active_experiments_count: The active_experiments_count of this V1Membership.  # noqa: E501
        :type: str
        """

        self._active_experiments_count = active_experiments_count

    @property
    def active_sessions_count(self) -> 'str':
        """Gets the active_sessions_count of this V1Membership.  # noqa: E501


        :return: The active_sessions_count of this V1Membership.  # noqa: E501
        :rtype: str
        """
        return self._active_sessions_count

    @active_sessions_count.setter
    def active_sessions_count(self, active_sessions_count: 'str'):
        """Sets the active_sessions_count of this V1Membership.


        :param active_sessions_count: The active_sessions_count of this V1Membership.  # noqa: E501
        :type: str
        """

        self._active_sessions_count = active_sessions_count

    @property
    def balance(self) -> 'float':
        """Gets the balance of this V1Membership.  # noqa: E501


        :return: The balance of this V1Membership.  # noqa: E501
        :rtype: float
        """
        return self._balance

    @balance.setter
    def balance(self, balance: 'float'):
        """Sets the balance of this V1Membership.


        :param balance: The balance of this V1Membership.  # noqa: E501
        :type: float
        """

        self._balance = balance

    @property
    def created_at(self) -> 'datetime':
        """Gets the created_at of this V1Membership.  # noqa: E501


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

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


        :param created_at: The created_at of this V1Membership.  # noqa: E501
        :type: datetime
        """

        self._created_at = created_at

    @property
    def datastore_count(self) -> 'str':
        """Gets the datastore_count of this V1Membership.  # noqa: E501


        :return: The datastore_count of this V1Membership.  # noqa: E501
        :rtype: str
        """
        return self._datastore_count

    @datastore_count.setter
    def datastore_count(self, datastore_count: 'str'):
        """Sets the datastore_count of this V1Membership.


        :param datastore_count: The datastore_count of this V1Membership.  # noqa: E501
        :type: str
        """

        self._datastore_count = datastore_count

    @property
    def description(self) -> 'str':
        """Gets the description of this V1Membership.  # noqa: E501


        :return: The description of this V1Membership.  # noqa: E501
        :rtype: str
        """
        return self._description

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


        :param description: The description of this V1Membership.  # noqa: E501
        :type: str
        """

        self._description = description

    @property
    def membership_count(self) -> 'str':
        """Gets the membership_count of this V1Membership.  # noqa: E501


        :return: The membership_count of this V1Membership.  # noqa: E501
        :rtype: str
        """
        return self._membership_count

    @membership_count.setter
    def membership_count(self, membership_count: 'str'):
        """Sets the membership_count of this V1Membership.


        :param membership_count: The membership_count of this V1Membership.  # noqa: E501
        :type: str
        """

        self._membership_count = membership_count

    @property
    def name(self) -> 'str':
        """Gets the name of this V1Membership.  # noqa: E501


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

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


        :param name: The name of this V1Membership.  # noqa: E501
        :type: str
        """

        self._name = name

    @property
    def project_id(self) -> 'str':
        """Gets the project_id of this V1Membership.  # noqa: E501


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

    @project_id.setter
    def project_id(self, project_id: 'str'):
        """Sets the project_id of this V1Membership.


        :param project_id: The project_id of this V1Membership.  # noqa: E501
        :type: str
        """

        self._project_id = project_id

    @property
    def roles(self) -> 'list[V1Role]':
        """Gets the roles of this V1Membership.  # noqa: E501


        :return: The roles of this V1Membership.  # noqa: E501
        :rtype: list[V1Role]
        """
        return self._roles

    @roles.setter
    def roles(self, roles: 'list[V1Role]'):
        """Sets the roles of this V1Membership.


        :param roles: The roles of this V1Membership.  # noqa: E501
        :type: list[V1Role]
        """

        self._roles = roles

    @property
    def updated_at(self) -> 'datetime':
        """Gets the updated_at of this V1Membership.  # noqa: E501


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

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


        :param updated_at: The updated_at of this V1Membership.  # noqa: E501
        :type: datetime
        """

        self._updated_at = updated_at

    @property
    def user_id(self) -> 'str':
        """Gets the user_id of this V1Membership.  # noqa: E501


        :return: The user_id of this V1Membership.  # noqa: E501
        :rtype: str
        """
        return self._user_id

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


        :param user_id: The user_id of this V1Membership.  # noqa: E501
        :type: str
        """

        self._user_id = user_id

    def to_dict(self) -> dict:
        """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(V1Membership, dict):
            for key, value in self.items():
                result[key] = value

        return result

    def to_str(self) -> str:
        """Returns the string representation of the model"""
        return pprint.pformat(self.to_dict())

    def __repr__(self) -> str:
        """For `print` and `pprint`"""
        return self.to_str()

    def __eq__(self, other: 'V1Membership') -> bool:
        """Returns true if both objects are equal"""
        if not isinstance(other, V1Membership):
            return False

        return self.to_dict() == other.to_dict()

    def __ne__(self, other: 'V1Membership') -> bool:
        """Returns true if both objects are not equal"""
        if not isinstance(other, V1Membership):
            return True

        return self.to_dict() != other.to_dict()
