1# coding: utf-8 2""" 3 Kubernetes 4 5 No description provided (generated by Swagger Codegen 6 https://github.com/swagger-api/swagger-codegen) 7 8 OpenAPI spec version: v1.14.4 9 10 Generated by: https://github.com/swagger-api/swagger-codegen.git 11""" 12 13from pprint import pformat 14from six import iteritems 15import re 16 17 18class V1beta1CSINodeSpec(object): 19 """ 20 NOTE: This class is auto generated by the swagger code generator program. 21 Do not edit the class manually. 22 """ 23 """ 24 Attributes: 25 swagger_types (dict): The key is attribute name and the value is attribute 26 type. 27 attribute_map (dict): The key is attribute name and the value is json key 28 in definition. 29 """ 30 swagger_types = {'drivers': 'list[V1beta1CSINodeDriver]'} 31 32 attribute_map = {'drivers': 'drivers'} 33 34 def __init__(self, drivers=None): 35 """ 36 V1beta1CSINodeSpec - a model defined in Swagger 37 """ 38 39 self._drivers = None 40 self.discriminator = None 41 42 self.drivers = drivers 43 44 @property 45 def drivers(self): 46 """ 47 Gets the drivers of this V1beta1CSINodeSpec. 48 drivers is a list of information of all CSI Drivers existing on a node. 49 If all drivers in the list are uninstalled, this can become empty. 50 51 :return: The drivers of this V1beta1CSINodeSpec. 52 :rtype: list[V1beta1CSINodeDriver] 53 """ 54 return self._drivers 55 56 @drivers.setter 57 def drivers(self, drivers): 58 """ 59 Sets the drivers of this V1beta1CSINodeSpec. 60 drivers is a list of information of all CSI Drivers existing on a node. 61 If all drivers in the list are uninstalled, this can become empty. 62 63 :param drivers: The drivers of this V1beta1CSINodeSpec. 64 :type: list[V1beta1CSINodeDriver] 65 """ 66 if drivers is None: 67 raise ValueError('Invalid value for `drivers`, must not be `None`') 68 69 self._drivers = drivers 70 71 def to_dict(self): 72 """ 73 Returns the model properties as a dict 74 """ 75 result = {} 76 77 for attr, _ in iteritems(self.swagger_types): 78 value = getattr(self, attr) 79 if isinstance(value, list): 80 result[attr] = list( 81 map(lambda x: x.to_dict() if hasattr(x, 'to_dict') else x, value)) 82 elif hasattr(value, 'to_dict'): 83 result[attr] = value.to_dict() 84 elif isinstance(value, dict): 85 result[attr] = dict( 86 map( 87 lambda item: (item[0], item[1].to_dict()) 88 if hasattr(item[1], 'to_dict') else item, value.items())) 89 else: 90 result[attr] = value 91 92 return result 93 94 def to_str(self): 95 """ 96 Returns the string representation of the model 97 """ 98 return pformat(self.to_dict()) 99 100 def __repr__(self): 101 """ 102 For `print` and `pprint` 103 """ 104 return self.to_str() 105 106 def __eq__(self, other): 107 """ 108 Returns true if both objects are equal 109 """ 110 if not isinstance(other, V1beta1CSINodeSpec): 111 return False 112 113 return self.__dict__ == other.__dict__ 114 115 def __ne__(self, other): 116 """ 117 Returns true if both objects are not equal 118 """ 119 return not self == other 120