
    Ixh	                     r    d dl Zd dlZ G d d          ZdZ eeed                                           dS )    Nc                   V    e Zd ZdZddZed             Zd Zd Zd Z	d	 Z
dd
Zd ZdS )VendorImporterz
    A PEP 302 meta path importer for finding optionally-vendored
    or otherwise naturally-installed packages from root_name.
     Nc                 v    || _         t          |          | _        |p|                    dd          | _        d S )Nextern_vendor)	root_namesetvendored_namesreplace
vendor_pkg)selfr	   r   r   s       M/var/www/html/what/lib/python3.11/site-packages/setuptools/extern/__init__.py__init__zVendorImporter.__init__   s9    "!.11$N	(9(9(I(N(N    c              #   *   K   | j         dz   V  dV  dS )zL
        Search first the vendor package then as a natural package.
        . N)r   r   s    r   search_pathzVendorImporter.search_path   s(      
 o####r   c                     |                     | j        dz             \  }}}| o&t          t          |j        | j                            S )z,Figure out if the target module is vendored.r   )	partitionr	   anymap
startswithr   )r   fullnamerootbasetargets        r   _module_matches_namespacez(VendorImporter._module_matches_namespace   sH    %//0DEEdFxLCF$5t7J K KLLLr   c                 6   |                     | j        dz             \  }}}| j        D ]K}	 ||z   }t          |           t          j        |         }|t          j        |<   |c S # t          $ r Y Hw xY wt           dj        di t                                )zK
        Iterate over the search path to locate and load fullname.
        r   zThe '{target}' package is required; normally this is bundled with this package so if you get this warning, consult the packager of your distribution.Nr   )	r   r	   r   
__import__sysmodulesImportErrorformatlocals)r   r   r   r   r   prefixextantmods           r   load_modulezVendorImporter.load_module   s     &//0DEEdF& 	 	F&6"""k&)(+H%


    '   !'3 3 *03 3  s   6A%%
A21A2c                 6    |                      |j                  S N)r+   name)r   specs     r   create_modulezVendorImporter.create_module3   s    	***r   c                     d S r-   r   )r   modules     r   exec_modulezVendorImporter.exec_module6   s    r   c                 p    |                      |          r t          j                            ||           ndS )z(Return a module spec for vendored names.N)r    	importlibutilspec_from_loader)r   r   pathr   s       r   	find_speczVendorImporter.find_spec9   s:     --h77BIN++Hd;;;=A	
r   c                 d    | t           j        vr!t           j                            |            dS dS )zR
        Install this importer into sys.meta_path if not already present.
        N)r#   	meta_pathappendr   s    r   installzVendorImporter.install@   s5     s}$$M  &&&&& %$r   )r   N)NN)__name__
__module____qualname____doc__r   propertyr   r    r+   r0   r3   r9   r=   r   r   r   r   r      s         
O O O O
   XM M M
  ,+ + +  
 
 
 
' ' ' ' 'r   r   )
	packaging	pyparsingordered_setmore_itertoolsimportlib_metadatazippimportlib_resourcesjaracotyping_extensionstomlizsetuptools._vendor)importlib.utilr5   r#   r   namesr>   r=   r   r   r   <module>rO      s{        



@' @' @' @' @' @' @' @'F	 x 4 5 5 = = ? ? ? ? ?r   