o
    •Û_‹  ã                   @   s   G d d„ de ƒZdS )c                   @   sà   e Zd ZdZdd„ Zedd„ ƒZedd„ ƒZedd	„ ƒZej	d
d	„ ƒZedd„ ƒZ
edd„ ƒZedd„ ƒZedd„ ƒZedd„ ƒZedd„ ƒZedd„ ƒZedd„ ƒZedd„ ƒZdd„ Zdd „ Zd!d"„ Zd)d$d%„Zd&d'„ Zd(S )*ÚInstancez
	c                 C   sP   || _ || _|| _|| _|| _|| _|| _d| _d| _d| _	t
ƒ | _t
ƒ | _d S )NTF)Ú_pluginÚ_nameÚ_devices_expressionÚ_devices_udev_regexÚ_script_preÚ_script_postÚ_optionsÚ_activeÚ_has_static_tuningÚ_has_dynamic_tuningÚsetÚ_assigned_devicesÚ_processed_devices)ÚselfÚpluginÚnameÚdevices_expressionÚdevices_udev_regexÚ
script_preÚscript_postÚoptions© r   úA/usr/lib/python3/dist-packages/tuned/plugins/instance/instance.pyÚ__init__   s   zInstance.__init__c                 C   ó   | j S ©N)r   ©r   r   r   r   r      ó   zInstance.pluginc                 C   r   r   )r   r   r   r   r   r      r   zInstance.namec                 C   r   )z>The instance performs some tuning (otherwise it is suspended).©r	   r   r   r   r   Úactive   s   zInstance.activec                 C   s
   || _ d S r   r   )r   Úvaluer   r   r   r   #   s   
c                 C   r   r   )r   r   r   r   r   r   '   r   zInstance.devices_expressionc                 C   r   r   )r   r   r   r   r   Úassigned_devices+   r   zInstance.assigned_devicesc                 C   r   r   )r   r   r   r   r   Úprocessed_devices/   r   zInstance.processed_devicesc                 C   r   r   )r   r   r   r   r   r   3   r   zInstance.devices_udev_regexc                 C   r   r   )r   r   r   r   r   r   7   r   zInstance.script_prec                 C   r   r   )r   r   r   r   r   r   ;   r   zInstance.script_postc                 C   r   r   )r   r   r   r   r   r   ?   r   zInstance.optionsc                 C   r   r   )r
   r   r   r   r   Úhas_static_tuningC   r   zInstance.has_static_tuningc                 C   r   r   )r   r   r   r   r   Úhas_dynamic_tuningG   r   zInstance.has_dynamic_tuningc                 C   ó   | j  | ¡ d S r   )r   Úinstance_apply_tuningr   r   r   r   Úapply_tuningM   ó   zInstance.apply_tuningc                 C   s   | j  | |¡S r   )r   Úinstance_verify_tuning)r   Úignore_missingr   r   r   Úverify_tuningP   s   zInstance.verify_tuningc                 C   r%   r   )r   Úinstance_update_tuningr   r   r   r   Úupdate_tuningS   r(   zInstance.update_tuningFc                 C   s   | j  | |¡ d S r   )r   Úinstance_unapply_tuning)r   Úfull_rollbackr   r   r   Úunapply_tuningV   s   zInstance.unapply_tuningc                 C   s   |   ¡  | j | ¡ d S r   )r0   r   Údestroy_instancer   r   r   r   ÚdestroyY   s   zInstance.destroyN)F)Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   Úpropertyr   r   r   Úsetterr   r!   r"   r   r   r   r   r#   r$   r'   r+   r-   r0   r2   r   r   r   r   r      sD    













r   N)Úobjectr   r   r   r   r   Ú<module>   s    