Top

lentiq.models.application_resources module

# coding: utf-8
####alex test
"""
    
    
        
    """

import pprint
import re  # noqa: F401

import six


class ApplicationResources(object):
    """
        """
    """
    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 = {
        'limits_cpu': 'float',
        'limits_memory_gi_b': 'float',
        'requests_cpu': 'float',
        'requests_memory_gi_b': 'float',
        'use_limits_values_for_requests': 'bool'
    }

    attribute_map = {
        'limits_cpu': 'limitsCPU',
        'limits_memory_gi_b': 'limitsMemoryGiB',
        'requests_cpu': 'requestsCPU',
        'requests_memory_gi_b': 'requestsMemoryGiB',
        'use_limits_values_for_requests': 'useLimitsValuesForRequests'
    }

    discriminator = None

    def __init__(self, limits_cpu=None, limits_memory_gi_b=None, requests_cpu=None, requests_memory_gi_b=None, use_limits_values_for_requests=None):  # noqa: E501
        """ApplicationResources - a model defined in Swagger"""  # noqa: E501
        self._limits_cpu = None
        self._limits_memory_gi_b = None
        self._requests_cpu = None
        self._requests_memory_gi_b = None
        self._use_limits_values_for_requests = None

        if limits_cpu is not None:
            self.limits_cpu = limits_cpu
        if limits_memory_gi_b is not None:
            self.limits_memory_gi_b = limits_memory_gi_b
        if requests_cpu is not None:
            self.requests_cpu = requests_cpu
        if requests_memory_gi_b is not None:
            self.requests_memory_gi_b = requests_memory_gi_b
        if use_limits_values_for_requests is not None:
            self.use_limits_values_for_requests = use_limits_values_for_requests

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


        :return: The limits_cpu of this ApplicationResources.  # noqa: E501
        :rtype: float
        """
        return self._limits_cpu

    @limits_cpu.setter
    def limits_cpu(self, limits_cpu):
        """Sets the limits_cpu of this ApplicationResources.


        :param limits_cpu: The limits_cpu of this ApplicationResources.  # noqa: E501
        :type: float
        """

        self._limits_cpu = limits_cpu

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


        :return: The limits_memory_gi_b of this ApplicationResources.  # noqa: E501
        :rtype: float
        """
        return self._limits_memory_gi_b

    @limits_memory_gi_b.setter
    def limits_memory_gi_b(self, limits_memory_gi_b):
        """Sets the limits_memory_gi_b of this ApplicationResources.


        :param limits_memory_gi_b: The limits_memory_gi_b of this ApplicationResources.  # noqa: E501
        :type: float
        """

        self._limits_memory_gi_b = limits_memory_gi_b

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


        :return: The requests_cpu of this ApplicationResources.  # noqa: E501
        :rtype: float
        """
        return self._requests_cpu

    @requests_cpu.setter
    def requests_cpu(self, requests_cpu):
        """Sets the requests_cpu of this ApplicationResources.


        :param requests_cpu: The requests_cpu of this ApplicationResources.  # noqa: E501
        :type: float
        """

        self._requests_cpu = requests_cpu

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


        :return: The requests_memory_gi_b of this ApplicationResources.  # noqa: E501
        :rtype: float
        """
        return self._requests_memory_gi_b

    @requests_memory_gi_b.setter
    def requests_memory_gi_b(self, requests_memory_gi_b):
        """Sets the requests_memory_gi_b of this ApplicationResources.


        :param requests_memory_gi_b: The requests_memory_gi_b of this ApplicationResources.  # noqa: E501
        :type: float
        """

        self._requests_memory_gi_b = requests_memory_gi_b

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


        :return: The use_limits_values_for_requests of this ApplicationResources.  # noqa: E501
        :rtype: bool
        """
        return self._use_limits_values_for_requests

    @use_limits_values_for_requests.setter
    def use_limits_values_for_requests(self, use_limits_values_for_requests):
        """Sets the use_limits_values_for_requests of this ApplicationResources.


        :param use_limits_values_for_requests: The use_limits_values_for_requests of this ApplicationResources.  # noqa: E501
        :type: bool
        """

        self._use_limits_values_for_requests = use_limits_values_for_requests

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

        return self.__dict__ == other.__dict__

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

Classes

class ApplicationResources

class ApplicationResources(object):
    """
        """
    """
    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 = {
        'limits_cpu': 'float',
        'limits_memory_gi_b': 'float',
        'requests_cpu': 'float',
        'requests_memory_gi_b': 'float',
        'use_limits_values_for_requests': 'bool'
    }

    attribute_map = {
        'limits_cpu': 'limitsCPU',
        'limits_memory_gi_b': 'limitsMemoryGiB',
        'requests_cpu': 'requestsCPU',
        'requests_memory_gi_b': 'requestsMemoryGiB',
        'use_limits_values_for_requests': 'useLimitsValuesForRequests'
    }

    discriminator = None

    def __init__(self, limits_cpu=None, limits_memory_gi_b=None, requests_cpu=None, requests_memory_gi_b=None, use_limits_values_for_requests=None):  # noqa: E501
        """ApplicationResources - a model defined in Swagger"""  # noqa: E501
        self._limits_cpu = None
        self._limits_memory_gi_b = None
        self._requests_cpu = None
        self._requests_memory_gi_b = None
        self._use_limits_values_for_requests = None

        if limits_cpu is not None:
            self.limits_cpu = limits_cpu
        if limits_memory_gi_b is not None:
            self.limits_memory_gi_b = limits_memory_gi_b
        if requests_cpu is not None:
            self.requests_cpu = requests_cpu
        if requests_memory_gi_b is not None:
            self.requests_memory_gi_b = requests_memory_gi_b
        if use_limits_values_for_requests is not None:
            self.use_limits_values_for_requests = use_limits_values_for_requests

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


        :return: The limits_cpu of this ApplicationResources.  # noqa: E501
        :rtype: float
        """
        return self._limits_cpu

    @limits_cpu.setter
    def limits_cpu(self, limits_cpu):
        """Sets the limits_cpu of this ApplicationResources.


        :param limits_cpu: The limits_cpu of this ApplicationResources.  # noqa: E501
        :type: float
        """

        self._limits_cpu = limits_cpu

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


        :return: The limits_memory_gi_b of this ApplicationResources.  # noqa: E501
        :rtype: float
        """
        return self._limits_memory_gi_b

    @limits_memory_gi_b.setter
    def limits_memory_gi_b(self, limits_memory_gi_b):
        """Sets the limits_memory_gi_b of this ApplicationResources.


        :param limits_memory_gi_b: The limits_memory_gi_b of this ApplicationResources.  # noqa: E501
        :type: float
        """

        self._limits_memory_gi_b = limits_memory_gi_b

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


        :return: The requests_cpu of this ApplicationResources.  # noqa: E501
        :rtype: float
        """
        return self._requests_cpu

    @requests_cpu.setter
    def requests_cpu(self, requests_cpu):
        """Sets the requests_cpu of this ApplicationResources.


        :param requests_cpu: The requests_cpu of this ApplicationResources.  # noqa: E501
        :type: float
        """

        self._requests_cpu = requests_cpu

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


        :return: The requests_memory_gi_b of this ApplicationResources.  # noqa: E501
        :rtype: float
        """
        return self._requests_memory_gi_b

    @requests_memory_gi_b.setter
    def requests_memory_gi_b(self, requests_memory_gi_b):
        """Sets the requests_memory_gi_b of this ApplicationResources.


        :param requests_memory_gi_b: The requests_memory_gi_b of this ApplicationResources.  # noqa: E501
        :type: float
        """

        self._requests_memory_gi_b = requests_memory_gi_b

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


        :return: The use_limits_values_for_requests of this ApplicationResources.  # noqa: E501
        :rtype: bool
        """
        return self._use_limits_values_for_requests

    @use_limits_values_for_requests.setter
    def use_limits_values_for_requests(self, use_limits_values_for_requests):
        """Sets the use_limits_values_for_requests of this ApplicationResources.


        :param use_limits_values_for_requests: The use_limits_values_for_requests of this ApplicationResources.  # noqa: E501
        :type: bool
        """

        self._use_limits_values_for_requests = use_limits_values_for_requests

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

        return self.__dict__ == other.__dict__

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

Ancestors (in MRO)

Class variables

var attribute_map

var discriminator

var swagger_types

Static methods

def __init__(

self, limits_cpu=None, limits_memory_gi_b=None, requests_cpu=None, requests_memory_gi_b=None, use_limits_values_for_requests=None)

ApplicationResources - a model defined in Swagger

def __init__(self, limits_cpu=None, limits_memory_gi_b=None, requests_cpu=None, requests_memory_gi_b=None, use_limits_values_for_requests=None):  # noqa: E501
    """ApplicationResources - a model defined in Swagger"""  # noqa: E501
    self._limits_cpu = None
    self._limits_memory_gi_b = None
    self._requests_cpu = None
    self._requests_memory_gi_b = None
    self._use_limits_values_for_requests = None
    if limits_cpu is not None:
        self.limits_cpu = limits_cpu
    if limits_memory_gi_b is not None:
        self.limits_memory_gi_b = limits_memory_gi_b
    if requests_cpu is not None:
        self.requests_cpu = requests_cpu
    if requests_memory_gi_b is not None:
        self.requests_memory_gi_b = requests_memory_gi_b
    if use_limits_values_for_requests is not None:
        self.use_limits_values_for_requests = use_limits_values_for_requests

def to_dict(

self)

Returns the model properties as a dict

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

def to_str(

self)

Returns the string representation of the model

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

Instance variables

var limits_cpu

Gets the limits_cpu of this ApplicationResources. # noqa: E501

:return: The limits_cpu of this ApplicationResources. # noqa: E501 :rtype: float

var limits_memory_gi_b

Gets the limits_memory_gi_b of this ApplicationResources. # noqa: E501

:return: The limits_memory_gi_b of this ApplicationResources. # noqa: E501 :rtype: float

var requests_cpu

Gets the requests_cpu of this ApplicationResources. # noqa: E501

:return: The requests_cpu of this ApplicationResources. # noqa: E501 :rtype: float

var requests_memory_gi_b

Gets the requests_memory_gi_b of this ApplicationResources. # noqa: E501

:return: The requests_memory_gi_b of this ApplicationResources. # noqa: E501 :rtype: float

var use_limits_values_for_requests

Gets the use_limits_values_for_requests of this ApplicationResources. # noqa: E501

:return: The use_limits_values_for_requests of this ApplicationResources. # noqa: E501 :rtype: bool