o
    viH                     @   s<   d Z ddlZddlZddlZddlmZ G dd deZdS )z
    Kubernetes

    No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)  # noqa: E501

    The version of the OpenAPI document: release-1.35
    Generated by: https://openapi-generator.tech
    N)Configurationc                   @   s  e Zd ZdZ	 dddddddddddd	d
Zddddddddddddd
ZdHddZedd Zej	dd Zedd Z
e
j	dd Z
ed d! Zej	d"d! Zed#d$ Zej	d%d$ Zed&d' Zej	d(d' Zed)d* Zej	d+d* Zed,d- Zej	d.d- Zed/d0 Zej	d1d0 Zed2d3 Zej	d4d3 Zed5d6 Zej	d7d6 Zed8d9 Zej	d:d9 Zed;d< Zej	d=d< Zd>d? Zd@dA ZdBdC ZdDdE ZdFdG ZdS )IV1DevicezNOTE: This class is auto generated by OpenAPI Generator.
    Ref: https://openapi-generator.tech

    Do not edit the class manually.
    boolzdict(str, V1DeviceAttribute)z	list[str]zdict(str, V1DeviceCapacity)z list[V1DeviceCounterConsumption]strV1NodeSelectorzlist[V1DeviceTaint])	all_nodesallow_multiple_allocations
attributesbinding_conditionsbinding_failure_conditionsbinds_to_nodecapacityconsumes_countersname	node_namenode_selectortaintsallNodesallowMultipleAllocationsr	   bindingConditionsbindingFailureConditionsbindsToNoder   consumesCountersr   nodeNamenodeSelectorr   Nc                 C   s
  |du rt  }|| _d| _d| _d| _d| _d| _d| _d| _d| _	d| _
d| _d| _d| _d| _|dur8|| _|dur?|| _|durF|| _|durM|| _|durT|| _|dur[|| _|durb|| _|duri|| _|	| _|
durs|
| _|durz|| _|dur|| _dS dS )z%V1Device - a model defined in OpenAPIN)r   local_vars_configuration
_all_nodes_allow_multiple_allocations_attributes_binding_conditions_binding_failure_conditions_binds_to_node	_capacity_consumes_counters_name
_node_name_node_selector_taintsdiscriminatorr   r   r	   r
   r   r   r   r   r   r   r   r   )selfr   r   r	   r
   r   r   r   r   r   r   r   r   r    r*   a/home/air/biblejyuku/back/venv/lib/python3.10/site-packages/kubernetes/client/models/v1_device.py__init__A   sP   
zV1Device.__init__c                 C      | j S )ad  Gets the all_nodes of this V1Device.  # noqa: E501

        AllNodes indicates that all nodes have access to the device.  Must only be set if Spec.PerDeviceNodeSelection is set to true. At most one of NodeName, NodeSelector and AllNodes can be set.  # noqa: E501

        :return: The all_nodes of this V1Device.  # noqa: E501
        :rtype: bool
        r   r)   r*   r*   r+   r   m      	zV1Device.all_nodesc                 C   
   || _ dS )a^  Sets the all_nodes of this V1Device.

        AllNodes indicates that all nodes have access to the device.  Must only be set if Spec.PerDeviceNodeSelection is set to true. At most one of NodeName, NodeSelector and AllNodes can be set.  # noqa: E501

        :param all_nodes: The all_nodes of this V1Device.  # noqa: E501
        :type: bool
        Nr.   )r)   r   r*   r*   r+   r   x      

c                 C   r-   )a  Gets the allow_multiple_allocations of this V1Device.  # noqa: E501

        AllowMultipleAllocations marks whether the device is allowed to be allocated to multiple DeviceRequests.  If AllowMultipleAllocations is set to true, the device can be allocated more than once, and all of its capacity is consumable, regardless of whether the requestPolicy is defined or not.  # noqa: E501

        :return: The allow_multiple_allocations of this V1Device.  # noqa: E501
        :rtype: bool
        r   r/   r*   r*   r+   r      r0   z#V1Device.allow_multiple_allocationsc                 C   r1   )a  Sets the allow_multiple_allocations of this V1Device.

        AllowMultipleAllocations marks whether the device is allowed to be allocated to multiple DeviceRequests.  If AllowMultipleAllocations is set to true, the device can be allocated more than once, and all of its capacity is consumable, regardless of whether the requestPolicy is defined or not.  # noqa: E501

        :param allow_multiple_allocations: The allow_multiple_allocations of this V1Device.  # noqa: E501
        :type: bool
        Nr3   )r)   r   r*   r*   r+   r      r2   c                 C   r-   )as  Gets the attributes of this V1Device.  # noqa: E501

        Attributes defines the set of attributes for this device. The name of each attribute must be unique in that set.  The maximum number of attributes and capacities combined is 32.  # noqa: E501

        :return: The attributes of this V1Device.  # noqa: E501
        :rtype: dict(str, V1DeviceAttribute)
        r   r/   r*   r*   r+   r	      r0   zV1Device.attributesc                 C   r1   )an  Sets the attributes of this V1Device.

        Attributes defines the set of attributes for this device. The name of each attribute must be unique in that set.  The maximum number of attributes and capacities combined is 32.  # noqa: E501

        :param attributes: The attributes of this V1Device.  # noqa: E501
        :type: dict(str, V1DeviceAttribute)
        Nr4   )r)   r	   r*   r*   r+   r	      r2   c                 C   r-   )a  Gets the binding_conditions of this V1Device.  # noqa: E501

        BindingConditions defines the conditions for proceeding with binding. All of these conditions must be set in the per-device status conditions with a value of True to proceed with binding the pod to the node while scheduling the pod.  The maximum number of binding conditions is 4.  The conditions must be a valid condition type string.  This is an alpha field and requires enabling the DRADeviceBindingConditions and DRAResourceClaimDeviceStatus feature gates.  # noqa: E501

        :return: The binding_conditions of this V1Device.  # noqa: E501
        :rtype: list[str]
        r   r/   r*   r*   r+   r
      r0   zV1Device.binding_conditionsc                 C   r1   )a  Sets the binding_conditions of this V1Device.

        BindingConditions defines the conditions for proceeding with binding. All of these conditions must be set in the per-device status conditions with a value of True to proceed with binding the pod to the node while scheduling the pod.  The maximum number of binding conditions is 4.  The conditions must be a valid condition type string.  This is an alpha field and requires enabling the DRADeviceBindingConditions and DRAResourceClaimDeviceStatus feature gates.  # noqa: E501

        :param binding_conditions: The binding_conditions of this V1Device.  # noqa: E501
        :type: list[str]
        Nr5   )r)   r
   r*   r*   r+   r
      r2   c                 C   r-   )ai  Gets the binding_failure_conditions of this V1Device.  # noqa: E501

        BindingFailureConditions defines the conditions for binding failure. They may be set in the per-device status conditions. If any is set to "True", a binding failure occurred.  The maximum number of binding failure conditions is 4.  The conditions must be a valid condition type string.  This is an alpha field and requires enabling the DRADeviceBindingConditions and DRAResourceClaimDeviceStatus feature gates.  # noqa: E501

        :return: The binding_failure_conditions of this V1Device.  # noqa: E501
        :rtype: list[str]
        r    r/   r*   r*   r+   r      r0   z#V1Device.binding_failure_conditionsc                 C   r1   )at  Sets the binding_failure_conditions of this V1Device.

        BindingFailureConditions defines the conditions for binding failure. They may be set in the per-device status conditions. If any is set to "True", a binding failure occurred.  The maximum number of binding failure conditions is 4.  The conditions must be a valid condition type string.  This is an alpha field and requires enabling the DRADeviceBindingConditions and DRAResourceClaimDeviceStatus feature gates.  # noqa: E501

        :param binding_failure_conditions: The binding_failure_conditions of this V1Device.  # noqa: E501
        :type: list[str]
        Nr6   )r)   r   r*   r*   r+   r      r2   c                 C   r-   )aP  Gets the binds_to_node of this V1Device.  # noqa: E501

        BindsToNode indicates if the usage of an allocation involving this device has to be limited to exactly the node that was chosen when allocating the claim. If set to true, the scheduler will set the ResourceClaim.Status.Allocation.NodeSelector to match the node where the allocation was made.  This is an alpha field and requires enabling the DRADeviceBindingConditions and DRAResourceClaimDeviceStatus feature gates.  # noqa: E501

        :return: The binds_to_node of this V1Device.  # noqa: E501
        :rtype: bool
        r!   r/   r*   r*   r+   r      r0   zV1Device.binds_to_nodec                 C   r1   )aN  Sets the binds_to_node of this V1Device.

        BindsToNode indicates if the usage of an allocation involving this device has to be limited to exactly the node that was chosen when allocating the claim. If set to true, the scheduler will set the ResourceClaim.Status.Allocation.NodeSelector to match the node where the allocation was made.  This is an alpha field and requires enabling the DRADeviceBindingConditions and DRAResourceClaimDeviceStatus feature gates.  # noqa: E501

        :param binds_to_node: The binds_to_node of this V1Device.  # noqa: E501
        :type: bool
        Nr7   )r)   r   r*   r*   r+   r      r2   c                 C   r-   )ak  Gets the capacity of this V1Device.  # noqa: E501

        Capacity defines the set of capacities for this device. The name of each capacity must be unique in that set.  The maximum number of attributes and capacities combined is 32.  # noqa: E501

        :return: The capacity of this V1Device.  # noqa: E501
        :rtype: dict(str, V1DeviceCapacity)
        r"   r/   r*   r*   r+   r      r0   zV1Device.capacityc                 C   r1   )ad  Sets the capacity of this V1Device.

        Capacity defines the set of capacities for this device. The name of each capacity must be unique in that set.  The maximum number of attributes and capacities combined is 32.  # noqa: E501

        :param capacity: The capacity of this V1Device.  # noqa: E501
        :type: dict(str, V1DeviceCapacity)
        Nr8   )r)   r   r*   r*   r+   r     r2   c                 C   r-   )a  Gets the consumes_counters of this V1Device.  # noqa: E501

        ConsumesCounters defines a list of references to sharedCounters and the set of counters that the device will consume from those counter sets.  There can only be a single entry per counterSet.  The maximum number of device counter consumptions per device is 2.  # noqa: E501

        :return: The consumes_counters of this V1Device.  # noqa: E501
        :rtype: list[V1DeviceCounterConsumption]
        r#   r/   r*   r*   r+   r     r0   zV1Device.consumes_countersc                 C   r1   )a  Sets the consumes_counters of this V1Device.

        ConsumesCounters defines a list of references to sharedCounters and the set of counters that the device will consume from those counter sets.  There can only be a single entry per counterSet.  The maximum number of device counter consumptions per device is 2.  # noqa: E501

        :param consumes_counters: The consumes_counters of this V1Device.  # noqa: E501
        :type: list[V1DeviceCounterConsumption]
        Nr9   )r)   r   r*   r*   r+   r     r2   c                 C   r-   )a  Gets the name of this V1Device.  # noqa: E501

        Name is unique identifier among all devices managed by the driver in the pool. It must be a DNS label.  # noqa: E501

        :return: The name of this V1Device.  # noqa: E501
        :rtype: str
        )r$   r/   r*   r*   r+   r   %  r0   zV1Device.namec                 C   s"   | j jr|du rtd|| _dS )zSets the name of this V1Device.

        Name is unique identifier among all devices managed by the driver in the pool. It must be a DNS label.  # noqa: E501

        :param name: The name of this V1Device.  # noqa: E501
        :type: str
        Nz,Invalid value for `name`, must not be `None`)r   client_side_validation
ValueErrorr$   )r)   r   r*   r*   r+   r   0  s   	
c                 C   r-   )ab  Gets the node_name of this V1Device.  # noqa: E501

        NodeName identifies the node where the device is available.  Must only be set if Spec.PerDeviceNodeSelection is set to true. At most one of NodeName, NodeSelector and AllNodes can be set.  # noqa: E501

        :return: The node_name of this V1Device.  # noqa: E501
        :rtype: str
        r%   r/   r*   r*   r+   r   >  r0   zV1Device.node_namec                 C   r1   )a\  Sets the node_name of this V1Device.

        NodeName identifies the node where the device is available.  Must only be set if Spec.PerDeviceNodeSelection is set to true. At most one of NodeName, NodeSelector and AllNodes can be set.  # noqa: E501

        :param node_name: The node_name of this V1Device.  # noqa: E501
        :type: str
        Nr<   )r)   r   r*   r*   r+   r   I  r2   c                 C   r-   )zGets the node_selector of this V1Device.  # noqa: E501


        :return: The node_selector of this V1Device.  # noqa: E501
        :rtype: V1NodeSelector
        r&   r/   r*   r*   r+   r   U  s   zV1Device.node_selectorc                 C   r1   )zSets the node_selector of this V1Device.


        :param node_selector: The node_selector of this V1Device.  # noqa: E501
        :type: V1NodeSelector
        Nr=   )r)   r   r*   r*   r+   r   _  s   
	c                 C   r-   )a  Gets the taints of this V1Device.  # noqa: E501

        If specified, these are the driver-defined taints.  The maximum number of taints is 16. If taints are set for any device in a ResourceSlice, then the maximum number of allowed devices per ResourceSlice is 64 instead of 128.  This is an alpha field and requires enabling the DRADeviceTaints feature gate.  # noqa: E501

        :return: The taints of this V1Device.  # noqa: E501
        :rtype: list[V1DeviceTaint]
        r'   r/   r*   r*   r+   r   j  r0   zV1Device.taintsc                 C   r1   )a  Sets the taints of this V1Device.

        If specified, these are the driver-defined taints.  The maximum number of taints is 16. If taints are set for any device in a ResourceSlice, then the maximum number of allowed devices per ResourceSlice is 64 instead of 128.  This is an alpha field and requires enabling the DRADeviceTaints feature gate.  # noqa: E501

        :param taints: The taints of this V1Device.  # noqa: E501
        :type: list[V1DeviceTaint]
        Nr>   )r)   r   r*   r*   r+   r   u  r2   c                 C   s   i }t | jD ]=\}}t| |}t|tr"ttdd |||< qt|dr.| ||< qt|t	rAt	tdd |
 ||< q|||< q|S )z&Returns the model properties as a dictc                 S   s   t | dr	|  S | S )Nto_dicthasattrr?   )xr*   r*   r+   <lambda>  s    z"V1Device.to_dict.<locals>.<lambda>r?   c                 S   s&   t | d dr| d | d  fS | S )N   r?   r   r@   )itemr*   r*   r+   rC     s   )six	iteritemsopenapi_typesgetattr
isinstancelistmaprA   r?   dictitems)r)   resultattr_valuer*   r*   r+   r?     s"   




zV1Device.to_dictc                 C   s   t |  S )z.Returns the string representation of the model)pprintpformatr?   r/   r*   r*   r+   to_str  s   zV1Device.to_strc                 C   s   |   S )zFor `print` and `pprint`)rU   r/   r*   r*   r+   __repr__  s   zV1Device.__repr__c                 C   s   t |tsdS |  | kS )z&Returns true if both objects are equalFrJ   r   r?   r)   otherr*   r*   r+   __eq__     
zV1Device.__eq__c                 C   s   t |tsdS |  | kS )z*Returns true if both objects are not equalTrW   rX   r*   r*   r+   __ne__  r[   zV1Device.__ne__)NNNNNNNNNNNNN)__name__
__module____qualname____doc__rH   attribute_mapr,   propertyr   setterr   r	   r
   r   r   r   r   r   r   r   r   r?   rU   rV   rZ   r\   r*   r*   r*   r+   r      s    
,






























	




r   )r`   rS   rerF   kubernetes.client.configurationr   objectr   r*   r*   r*   r+   <module>   s   
