3 fY@s8dZddlmZddlmZddlZGdddeZdS)z Kubernetes No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) OpenAPI spec version: v1.7.4 Generated by: https://github.com/swagger-api/swagger-codegen.git )pformat) iteritemsNc@seZdZdZdddZeddZejddZedd Zejd d Zed d Z e jd d Z ddZ ddZ ddZ ddZ ddZdS)V1PodAffinityTermzw NOTE: This class is auto generated by the swagger code generator program. Do not edit the class manually. NcCs2dddd|_dddd|_||_||_||_dS) aG V1PodAffinityTerm - a model defined in Swagger :param dict swaggerTypes: The key is attribute name and the value is attribute type. :param dict attributeMap: The key is attribute name and the value is json key in definition. V1LabelSelectorz list[str]str)label_selector namespaces topology_keyZ labelSelectorrZ topologyKeyN) swagger_types attribute_map_label_selector _namespaces _topology_key)selfrrr r^/Users/olari/OneDrive/sandbox/awsBlog2/lambda/kubernetes/client/models/v1_pod_affinity_term.py__init__s   zV1PodAffinityTerm.__init__cCs|jS)z Gets the label_selector of this V1PodAffinityTerm. A label query over a set of resources, in this case pods. :return: The label_selector of this V1PodAffinityTerm. :rtype: V1LabelSelector )r )rrrrr1s z V1PodAffinityTerm.label_selectorcCs ||_dS)z Sets the label_selector of this V1PodAffinityTerm. A label query over a set of resources, in this case pods. :param label_selector: The label_selector of this V1PodAffinityTerm. :type: V1LabelSelector N)r )rrrrrr<s cCs|jS)a$ Gets the namespaces of this V1PodAffinityTerm. namespaces specifies which namespaces the labelSelector applies to (matches against); null or empty list means "this pod's namespace" :return: The namespaces of this V1PodAffinityTerm. :rtype: list[str] )r )rrrrrHs zV1PodAffinityTerm.namespacescCs ||_dS)a- Sets the namespaces of this V1PodAffinityTerm. namespaces specifies which namespaces the labelSelector applies to (matches against); null or empty list means "this pod's namespace" :param namespaces: The namespaces of this V1PodAffinityTerm. :type: list[str] N)r )rrrrrrSs cCs|jS)a Gets the topology_key of this V1PodAffinityTerm. This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching the labelSelector in the specified namespaces, where co-located is defined as running on a node whose value of the label with key topologyKey matches that of any node on which any of the selected pods is running. For PreferredDuringScheduling pod anti-affinity, empty topologyKey is interpreted as "all topologies" ("all topologies" here means all the topologyKeys indicated by scheduler command-line argument --failure-domains); for affinity and for RequiredDuringScheduling pod anti-affinity, empty topologyKey is not allowed. :return: The topology_key of this V1PodAffinityTerm. :rtype: str )r)rrrrr _s zV1PodAffinityTerm.topology_keycCs ||_dS)a Sets the topology_key of this V1PodAffinityTerm. This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching the labelSelector in the specified namespaces, where co-located is defined as running on a node whose value of the label with key topologyKey matches that of any node on which any of the selected pods is running. For PreferredDuringScheduling pod anti-affinity, empty topologyKey is interpreted as "all topologies" ("all topologies" here means all the topologyKeys indicated by scheduler command-line argument --failure-domains); for affinity and for RequiredDuringScheduling pod anti-affinity, empty topologyKey is not allowed. :param topology_key: The topology_key of this V1PodAffinityTerm. :type: str N)r)rr rrrr js cCsi}xt|jD]z\}}t||}t|trDttdd|||<qt|dr\|j||<qt|trttdd|j ||<q|||<qW|S)z8 Returns the model properties as a dict cSst|dr|jS|S)Nto_dict)hasattrr)xrrrsz+V1PodAffinityTerm.to_dict..rcSs&t|ddr"|d|djfS|S)Nrr)rr)itemrrrrs) rr getattr isinstancelistmaprrdictitems)rresultattr_valuerrrrvs     zV1PodAffinityTerm.to_dictcCs t|jS)z@ Returns the string representation of the model )rr)rrrrto_strszV1PodAffinityTerm.to_strcCs|jS)z* For `print` and `pprint` )r#)rrrr__repr__szV1PodAffinityTerm.__repr__cCst|tsdS|j|jkS)z8 Returns true if both objects are equal F)rr__dict__)rotherrrr__eq__s zV1PodAffinityTerm.__eq__cCs ||k S)z< Returns true if both objects are not equal r)rr&rrr__ne__szV1PodAffinityTerm.__ne__)NNN)__name__ __module__ __qualname____doc__rpropertyrsetterrr rr#r$r'r(rrrrrs      r)r,pprintrsixrreobjectrrrrr s