관리-도구
편집 파일: _utils.cpython-39.pyc
a �)g� � @ s$ d dl mZmZmZ eZdd� ZdS )� )�absolute_import�division�print_functionc C s\ t | �� �}t|�}|rX|D ]8}|�|� |�� D ] }||vr2|�|� |�|� q2qq|S )a Recursively search and find all subclasses of a given class :arg cls: A python class :rtype: set :returns: The set of python classes which are the subclasses of `cls`. In python, you can use a class's :py:meth:`__subclasses__` method to determine what subclasses of a class exist. However, `__subclasses__` only goes one level deep. This function searches each child class's `__subclasses__` method to find all of the descendent classes. It then returns an iterable of the descendent classes. )�set�__subclasses__�list�remove�append�add)�clsZ subclassesZto_visitZscZssc� r �F/usr/lib/python3.9/site-packages/ansible/module_utils/common/_utils.py�get_all_subclasses s r N)Z __future__r r r �typeZ __metaclass__r r r r r �<module> s