# coding: utf-8

"""
    fluid

    client for fluid  # noqa: E501

    The version of the OpenAPI document: v0.1
    Generated by: https://openapi-generator.tech
"""


import pprint
import re  # noqa: F401

import six

from fluid.configuration import Configuration


class EFCRuntimeSpec(object):
    """NOTE: This class is auto generated by OpenAPI Generator.
    Ref: https://openapi-generator.tech

    Do not edit the class manually.
    """

    """
    Attributes:
      openapi_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.
    """
    openapi_types = {
        'clean_cache_policy': 'CleanCachePolicy',
        'fuse': 'EFCFuseSpec',
        'init_fuse': 'InitFuseSpec',
        'master': 'EFCCompTemplateSpec',
        'os_advise': 'OSAdvise',
        'pod_metadata': 'PodMetadata',
        'replicas': 'int',
        'tieredstore': 'TieredStore',
        'worker': 'EFCCompTemplateSpec'
    }

    attribute_map = {
        'clean_cache_policy': 'cleanCachePolicy',
        'fuse': 'fuse',
        'init_fuse': 'initFuse',
        'master': 'master',
        'os_advise': 'osAdvise',
        'pod_metadata': 'podMetadata',
        'replicas': 'replicas',
        'tieredstore': 'tieredstore',
        'worker': 'worker'
    }

    def __init__(self, clean_cache_policy=None, fuse=None, init_fuse=None, master=None, os_advise=None, pod_metadata=None, replicas=None, tieredstore=None, worker=None, local_vars_configuration=None):  # noqa: E501
        """EFCRuntimeSpec - a model defined in OpenAPI"""  # noqa: E501
        if local_vars_configuration is None:
            local_vars_configuration = Configuration()
        self.local_vars_configuration = local_vars_configuration

        self._clean_cache_policy = None
        self._fuse = None
        self._init_fuse = None
        self._master = None
        self._os_advise = None
        self._pod_metadata = None
        self._replicas = None
        self._tieredstore = None
        self._worker = None
        self.discriminator = None

        if clean_cache_policy is not None:
            self.clean_cache_policy = clean_cache_policy
        if fuse is not None:
            self.fuse = fuse
        if init_fuse is not None:
            self.init_fuse = init_fuse
        if master is not None:
            self.master = master
        if os_advise is not None:
            self.os_advise = os_advise
        if pod_metadata is not None:
            self.pod_metadata = pod_metadata
        if replicas is not None:
            self.replicas = replicas
        if tieredstore is not None:
            self.tieredstore = tieredstore
        if worker is not None:
            self.worker = worker

    @property
    def clean_cache_policy(self):
        """Gets the clean_cache_policy of this EFCRuntimeSpec.  # noqa: E501


        :return: The clean_cache_policy of this EFCRuntimeSpec.  # noqa: E501
        :rtype: CleanCachePolicy
        """
        return self._clean_cache_policy

    @clean_cache_policy.setter
    def clean_cache_policy(self, clean_cache_policy):
        """Sets the clean_cache_policy of this EFCRuntimeSpec.


        :param clean_cache_policy: The clean_cache_policy of this EFCRuntimeSpec.  # noqa: E501
        :type: CleanCachePolicy
        """

        self._clean_cache_policy = clean_cache_policy

    @property
    def fuse(self):
        """Gets the fuse of this EFCRuntimeSpec.  # noqa: E501


        :return: The fuse of this EFCRuntimeSpec.  # noqa: E501
        :rtype: EFCFuseSpec
        """
        return self._fuse

    @fuse.setter
    def fuse(self, fuse):
        """Sets the fuse of this EFCRuntimeSpec.


        :param fuse: The fuse of this EFCRuntimeSpec.  # noqa: E501
        :type: EFCFuseSpec
        """

        self._fuse = fuse

    @property
    def init_fuse(self):
        """Gets the init_fuse of this EFCRuntimeSpec.  # noqa: E501


        :return: The init_fuse of this EFCRuntimeSpec.  # noqa: E501
        :rtype: InitFuseSpec
        """
        return self._init_fuse

    @init_fuse.setter
    def init_fuse(self, init_fuse):
        """Sets the init_fuse of this EFCRuntimeSpec.


        :param init_fuse: The init_fuse of this EFCRuntimeSpec.  # noqa: E501
        :type: InitFuseSpec
        """

        self._init_fuse = init_fuse

    @property
    def master(self):
        """Gets the master of this EFCRuntimeSpec.  # noqa: E501


        :return: The master of this EFCRuntimeSpec.  # noqa: E501
        :rtype: EFCCompTemplateSpec
        """
        return self._master

    @master.setter
    def master(self, master):
        """Sets the master of this EFCRuntimeSpec.


        :param master: The master of this EFCRuntimeSpec.  # noqa: E501
        :type: EFCCompTemplateSpec
        """

        self._master = master

    @property
    def os_advise(self):
        """Gets the os_advise of this EFCRuntimeSpec.  # noqa: E501


        :return: The os_advise of this EFCRuntimeSpec.  # noqa: E501
        :rtype: OSAdvise
        """
        return self._os_advise

    @os_advise.setter
    def os_advise(self, os_advise):
        """Sets the os_advise of this EFCRuntimeSpec.


        :param os_advise: The os_advise of this EFCRuntimeSpec.  # noqa: E501
        :type: OSAdvise
        """

        self._os_advise = os_advise

    @property
    def pod_metadata(self):
        """Gets the pod_metadata of this EFCRuntimeSpec.  # noqa: E501


        :return: The pod_metadata of this EFCRuntimeSpec.  # noqa: E501
        :rtype: PodMetadata
        """
        return self._pod_metadata

    @pod_metadata.setter
    def pod_metadata(self, pod_metadata):
        """Sets the pod_metadata of this EFCRuntimeSpec.


        :param pod_metadata: The pod_metadata of this EFCRuntimeSpec.  # noqa: E501
        :type: PodMetadata
        """

        self._pod_metadata = pod_metadata

    @property
    def replicas(self):
        """Gets the replicas of this EFCRuntimeSpec.  # noqa: E501

        The replicas of the worker, need to be specified  # noqa: E501

        :return: The replicas of this EFCRuntimeSpec.  # noqa: E501
        :rtype: int
        """
        return self._replicas

    @replicas.setter
    def replicas(self, replicas):
        """Sets the replicas of this EFCRuntimeSpec.

        The replicas of the worker, need to be specified  # noqa: E501

        :param replicas: The replicas of this EFCRuntimeSpec.  # noqa: E501
        :type: int
        """

        self._replicas = replicas

    @property
    def tieredstore(self):
        """Gets the tieredstore of this EFCRuntimeSpec.  # noqa: E501


        :return: The tieredstore of this EFCRuntimeSpec.  # noqa: E501
        :rtype: TieredStore
        """
        return self._tieredstore

    @tieredstore.setter
    def tieredstore(self, tieredstore):
        """Sets the tieredstore of this EFCRuntimeSpec.


        :param tieredstore: The tieredstore of this EFCRuntimeSpec.  # noqa: E501
        :type: TieredStore
        """

        self._tieredstore = tieredstore

    @property
    def worker(self):
        """Gets the worker of this EFCRuntimeSpec.  # noqa: E501


        :return: The worker of this EFCRuntimeSpec.  # noqa: E501
        :rtype: EFCCompTemplateSpec
        """
        return self._worker

    @worker.setter
    def worker(self, worker):
        """Sets the worker of this EFCRuntimeSpec.


        :param worker: The worker of this EFCRuntimeSpec.  # noqa: E501
        :type: EFCCompTemplateSpec
        """

        self._worker = worker

    def to_dict(self):
        """Returns the model properties as a dict"""
        result = {}

        for attr, _ in six.iteritems(self.openapi_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

        return result

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

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

    def __eq__(self, other):
        """Returns true if both objects are equal"""
        if not isinstance(other, EFCRuntimeSpec):
            return False

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

    def __ne__(self, other):
        """Returns true if both objects are not equal"""
        if not isinstance(other, EFCRuntimeSpec):
            return True

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