# 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

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

class V1ClusterSpec(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 = {
        'auth_token': 'str',
        'available_instance_types': 'list[str]',
        'aws_v1': 'V1AWSDirectV1',
        'cluster_type': 'V1ClusterType',
        'cost_factor': 'str',
        'deletion_options': 'V1ClusterDeletionOptions',
        'desired_state': 'V1ClusterState',
        'driver': 'V1ClusterDriver',
        'google_cloud_v1': 'V1GoogleCloudDirectV1',
        'gridlet_version': 'str',
        'overprovisioning': 'list[V1InstanceOverprovisioningSpec]',
        'padding_factor': 'str',
        'pause_automation': 'bool',
        'performance_profile': 'V1ClusterPerformanceProfile',
        'slurm_v1': 'V1SlurmV1',
        'user_id': 'str'
    }

    attribute_map = {
        'auth_token': 'authToken',
        'available_instance_types': 'availableInstanceTypes',
        'aws_v1': 'awsV1',
        'cluster_type': 'clusterType',
        'cost_factor': 'costFactor',
        'deletion_options': 'deletionOptions',
        'desired_state': 'desiredState',
        'driver': 'driver',
        'google_cloud_v1': 'googleCloudV1',
        'gridlet_version': 'gridletVersion',
        'overprovisioning': 'overprovisioning',
        'padding_factor': 'paddingFactor',
        'pause_automation': 'pauseAutomation',
        'performance_profile': 'performanceProfile',
        'slurm_v1': 'slurmV1',
        'user_id': 'userId'
    }

    def __init__(self, auth_token: 'str' =None, available_instance_types: 'list[str]' =None, aws_v1: 'V1AWSDirectV1' =None, cluster_type: 'V1ClusterType' =None, cost_factor: 'str' =None, deletion_options: 'V1ClusterDeletionOptions' =None, desired_state: 'V1ClusterState' =None, driver: 'V1ClusterDriver' =None, google_cloud_v1: 'V1GoogleCloudDirectV1' =None, gridlet_version: 'str' =None, overprovisioning: 'list[V1InstanceOverprovisioningSpec]' =None, padding_factor: 'str' =None, pause_automation: 'bool' =None, performance_profile: 'V1ClusterPerformanceProfile' =None, slurm_v1: 'V1SlurmV1' =None, user_id: 'str' =None):  # noqa: E501
        """V1ClusterSpec - a model defined in Swagger"""  # noqa: E501
        self._auth_token = None
        self._available_instance_types = None
        self._aws_v1 = None
        self._cluster_type = None
        self._cost_factor = None
        self._deletion_options = None
        self._desired_state = None
        self._driver = None
        self._google_cloud_v1 = None
        self._gridlet_version = None
        self._overprovisioning = None
        self._padding_factor = None
        self._pause_automation = None
        self._performance_profile = None
        self._slurm_v1 = None
        self._user_id = None
        self.discriminator = None
        if auth_token is not None:
            self.auth_token = auth_token
        if available_instance_types is not None:
            self.available_instance_types = available_instance_types
        if aws_v1 is not None:
            self.aws_v1 = aws_v1
        if cluster_type is not None:
            self.cluster_type = cluster_type
        if cost_factor is not None:
            self.cost_factor = cost_factor
        if deletion_options is not None:
            self.deletion_options = deletion_options
        if desired_state is not None:
            self.desired_state = desired_state
        if driver is not None:
            self.driver = driver
        if google_cloud_v1 is not None:
            self.google_cloud_v1 = google_cloud_v1
        if gridlet_version is not None:
            self.gridlet_version = gridlet_version
        if overprovisioning is not None:
            self.overprovisioning = overprovisioning
        if padding_factor is not None:
            self.padding_factor = padding_factor
        if pause_automation is not None:
            self.pause_automation = pause_automation
        if performance_profile is not None:
            self.performance_profile = performance_profile
        if slurm_v1 is not None:
            self.slurm_v1 = slurm_v1
        if user_id is not None:
            self.user_id = user_id

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


        :return: The auth_token of this V1ClusterSpec.  # noqa: E501
        :rtype: str
        """
        return self._auth_token

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


        :param auth_token: The auth_token of this V1ClusterSpec.  # noqa: E501
        :type: str
        """

        self._auth_token = auth_token

    @property
    def available_instance_types(self) -> 'list[str]':
        """Gets the available_instance_types of this V1ClusterSpec.  # noqa: E501

        available_instance_types is a list of instance types that are available for the cluster. This is just a soft filter to prevent users from using instances that we haven't prepared for. If the list is empty, no filtering is done.  # noqa: E501

        :return: The available_instance_types of this V1ClusterSpec.  # noqa: E501
        :rtype: list[str]
        """
        return self._available_instance_types

    @available_instance_types.setter
    def available_instance_types(self, available_instance_types: 'list[str]'):
        """Sets the available_instance_types of this V1ClusterSpec.

        available_instance_types is a list of instance types that are available for the cluster. This is just a soft filter to prevent users from using instances that we haven't prepared for. If the list is empty, no filtering is done.  # noqa: E501

        :param available_instance_types: The available_instance_types of this V1ClusterSpec.  # noqa: E501
        :type: list[str]
        """

        self._available_instance_types = available_instance_types

    @property
    def aws_v1(self) -> 'V1AWSDirectV1':
        """Gets the aws_v1 of this V1ClusterSpec.  # noqa: E501


        :return: The aws_v1 of this V1ClusterSpec.  # noqa: E501
        :rtype: V1AWSDirectV1
        """
        return self._aws_v1

    @aws_v1.setter
    def aws_v1(self, aws_v1: 'V1AWSDirectV1'):
        """Sets the aws_v1 of this V1ClusterSpec.


        :param aws_v1: The aws_v1 of this V1ClusterSpec.  # noqa: E501
        :type: V1AWSDirectV1
        """

        self._aws_v1 = aws_v1

    @property
    def cluster_type(self) -> 'V1ClusterType':
        """Gets the cluster_type of this V1ClusterSpec.  # noqa: E501


        :return: The cluster_type of this V1ClusterSpec.  # noqa: E501
        :rtype: V1ClusterType
        """
        return self._cluster_type

    @cluster_type.setter
    def cluster_type(self, cluster_type: 'V1ClusterType'):
        """Sets the cluster_type of this V1ClusterSpec.


        :param cluster_type: The cluster_type of this V1ClusterSpec.  # noqa: E501
        :type: V1ClusterType
        """

        self._cluster_type = cluster_type

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

        costController needs for calculating costOfGoods - string since it's decimal. Note: This value is stored in a separate column in the database, not with the rest of the cluster JSON in spec.  # noqa: E501

        :return: The cost_factor of this V1ClusterSpec.  # noqa: E501
        :rtype: str
        """
        return self._cost_factor

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

        costController needs for calculating costOfGoods - string since it's decimal. Note: This value is stored in a separate column in the database, not with the rest of the cluster JSON in spec.  # noqa: E501

        :param cost_factor: The cost_factor of this V1ClusterSpec.  # noqa: E501
        :type: str
        """

        self._cost_factor = cost_factor

    @property
    def deletion_options(self) -> 'V1ClusterDeletionOptions':
        """Gets the deletion_options of this V1ClusterSpec.  # noqa: E501


        :return: The deletion_options of this V1ClusterSpec.  # noqa: E501
        :rtype: V1ClusterDeletionOptions
        """
        return self._deletion_options

    @deletion_options.setter
    def deletion_options(self, deletion_options: 'V1ClusterDeletionOptions'):
        """Sets the deletion_options of this V1ClusterSpec.


        :param deletion_options: The deletion_options of this V1ClusterSpec.  # noqa: E501
        :type: V1ClusterDeletionOptions
        """

        self._deletion_options = deletion_options

    @property
    def desired_state(self) -> 'V1ClusterState':
        """Gets the desired_state of this V1ClusterSpec.  # noqa: E501


        :return: The desired_state of this V1ClusterSpec.  # noqa: E501
        :rtype: V1ClusterState
        """
        return self._desired_state

    @desired_state.setter
    def desired_state(self, desired_state: 'V1ClusterState'):
        """Sets the desired_state of this V1ClusterSpec.


        :param desired_state: The desired_state of this V1ClusterSpec.  # noqa: E501
        :type: V1ClusterState
        """

        self._desired_state = desired_state

    @property
    def driver(self) -> 'V1ClusterDriver':
        """Gets the driver of this V1ClusterSpec.  # noqa: E501


        :return: The driver of this V1ClusterSpec.  # noqa: E501
        :rtype: V1ClusterDriver
        """
        return self._driver

    @driver.setter
    def driver(self, driver: 'V1ClusterDriver'):
        """Sets the driver of this V1ClusterSpec.


        :param driver: The driver of this V1ClusterSpec.  # noqa: E501
        :type: V1ClusterDriver
        """

        self._driver = driver

    @property
    def google_cloud_v1(self) -> 'V1GoogleCloudDirectV1':
        """Gets the google_cloud_v1 of this V1ClusterSpec.  # noqa: E501


        :return: The google_cloud_v1 of this V1ClusterSpec.  # noqa: E501
        :rtype: V1GoogleCloudDirectV1
        """
        return self._google_cloud_v1

    @google_cloud_v1.setter
    def google_cloud_v1(self, google_cloud_v1: 'V1GoogleCloudDirectV1'):
        """Sets the google_cloud_v1 of this V1ClusterSpec.


        :param google_cloud_v1: The google_cloud_v1 of this V1ClusterSpec.  # noqa: E501
        :type: V1GoogleCloudDirectV1
        """

        self._google_cloud_v1 = google_cloud_v1

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


        :return: The gridlet_version of this V1ClusterSpec.  # noqa: E501
        :rtype: str
        """
        return self._gridlet_version

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


        :param gridlet_version: The gridlet_version of this V1ClusterSpec.  # noqa: E501
        :type: str
        """

        self._gridlet_version = gridlet_version

    @property
    def overprovisioning(self) -> 'list[V1InstanceOverprovisioningSpec]':
        """Gets the overprovisioning of this V1ClusterSpec.  # noqa: E501


        :return: The overprovisioning of this V1ClusterSpec.  # noqa: E501
        :rtype: list[V1InstanceOverprovisioningSpec]
        """
        return self._overprovisioning

    @overprovisioning.setter
    def overprovisioning(self, overprovisioning: 'list[V1InstanceOverprovisioningSpec]'):
        """Sets the overprovisioning of this V1ClusterSpec.


        :param overprovisioning: The overprovisioning of this V1ClusterSpec.  # noqa: E501
        :type: list[V1InstanceOverprovisioningSpec]
        """

        self._overprovisioning = overprovisioning

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

        costController needs for calculating paddingValue - string since it's decimal Note: This value is stored in a separate column in the database, not with the rest of the cluster JSON in spec.  # noqa: E501

        :return: The padding_factor of this V1ClusterSpec.  # noqa: E501
        :rtype: str
        """
        return self._padding_factor

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

        costController needs for calculating paddingValue - string since it's decimal Note: This value is stored in a separate column in the database, not with the rest of the cluster JSON in spec.  # noqa: E501

        :param padding_factor: The padding_factor of this V1ClusterSpec.  # noqa: E501
        :type: str
        """

        self._padding_factor = padding_factor

    @property
    def pause_automation(self) -> 'bool':
        """Gets the pause_automation of this V1ClusterSpec.  # noqa: E501


        :return: The pause_automation of this V1ClusterSpec.  # noqa: E501
        :rtype: bool
        """
        return self._pause_automation

    @pause_automation.setter
    def pause_automation(self, pause_automation: 'bool'):
        """Sets the pause_automation of this V1ClusterSpec.


        :param pause_automation: The pause_automation of this V1ClusterSpec.  # noqa: E501
        :type: bool
        """

        self._pause_automation = pause_automation

    @property
    def performance_profile(self) -> 'V1ClusterPerformanceProfile':
        """Gets the performance_profile of this V1ClusterSpec.  # noqa: E501


        :return: The performance_profile of this V1ClusterSpec.  # noqa: E501
        :rtype: V1ClusterPerformanceProfile
        """
        return self._performance_profile

    @performance_profile.setter
    def performance_profile(self, performance_profile: 'V1ClusterPerformanceProfile'):
        """Sets the performance_profile of this V1ClusterSpec.


        :param performance_profile: The performance_profile of this V1ClusterSpec.  # noqa: E501
        :type: V1ClusterPerformanceProfile
        """

        self._performance_profile = performance_profile

    @property
    def slurm_v1(self) -> 'V1SlurmV1':
        """Gets the slurm_v1 of this V1ClusterSpec.  # noqa: E501


        :return: The slurm_v1 of this V1ClusterSpec.  # noqa: E501
        :rtype: V1SlurmV1
        """
        return self._slurm_v1

    @slurm_v1.setter
    def slurm_v1(self, slurm_v1: 'V1SlurmV1'):
        """Sets the slurm_v1 of this V1ClusterSpec.


        :param slurm_v1: The slurm_v1 of this V1ClusterSpec.  # noqa: E501
        :type: V1SlurmV1
        """

        self._slurm_v1 = slurm_v1

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


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

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


        :param user_id: The user_id of this V1ClusterSpec.  # 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(V1ClusterSpec, 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: 'V1ClusterSpec') -> bool:
        """Returns true if both objects are equal"""
        if not isinstance(other, V1ClusterSpec):
            return False

        return self.__dict__ == other.__dict__

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