
    <ȋh                    j    d dl mZ d dlmZmZmZmZ ddlmZm	Z	m
Z
  G d dee	ef                   ZdS )    )annotations)
CollectionGenericIterableIterator   )CTRTRequirementInformationc                  2    e Zd ZdZdd
ZddZddZddZdS )	CriterionaQ  Representation of possible resolution results of a package.

    This holds three attributes:

    * `information` is a collection of `RequirementInformation` pairs.
      Each pair is a requirement contributing to this criterion, and the
      candidate that provides the requirement.
    * `incompatibilities` is a collection of all known not-to-work candidates
      to exclude from consideration.
    * `candidates` is a collection containing all possible candidates deducted
      from the union of contributing requirements and known incompatibilities.
      It should never be empty, except when the criterion is an attribute of a
      raised `RequirementsConflicted` (in which case it is always empty).

    .. note::
        This class is intended to be externally immutable. **Do not** mutate
        any of its attribute containers.
    
candidatesIterable[CT]information*Collection[RequirementInformation[RT, CT]]incompatibilitiesCollection[CT]returnNonec                0    || _         || _        || _        d S N)r   r   r   )selfr   r   r   s       g/var/www/pixelcanvas.ch/venv/lib/python3.11/site-packages/pip/_vendor/resolvelib/resolvers/criterion.py__init__zCriterion.__init__   s!     %&!2    strc                V    d                     d | j        D                       }d| dS )Nz, c              3  .   K   | ]\  }}d |d|dV  dS )(z, via=)N ).0reqparents      r   	<genexpr>z%Criterion.__repr__.<locals>.<genexpr>'   sK       !
 !
-8S&(((V(((!
 !
 !
 !
 !
 !
r   z
Criterion(r    )joinr   )r   requirementss     r   __repr__zCriterion.__repr__&   sG    yy !
 !
<@<L!
 !
 !
 
 
 ,L++++r   Iterator[RT]c                $    d | j         D             S )Nc              3  $   K   | ]}|j         V  d S r   )requirementr"   is     r   r%   z-Criterion.iter_requirement.<locals>.<genexpr>-   s$      88!888888r   r   r   s    r   iter_requirementzCriterion.iter_requirement,   s    88t'78888r   Iterator[CT | None]c                $    d | j         D             S )Nc              3  $   K   | ]}|j         V  d S r   )r$   r-   s     r   r%   z(Criterion.iter_parent.<locals>.<genexpr>0   s$      33Q333333r   r/   r0   s    r   iter_parentzCriterion.iter_parent/   s    33$"23333r   N)r   r   r   r   r   r   r   r   )r   r   )r   r)   )r   r2   )__name__
__module____qualname____doc__r   r(   r1   r5   r!   r   r   r   r      sn         &3 3 3 3, , , ,9 9 9 94 4 4 4 4 4r   r   N)
__future__r   typingr   r   r   r   structsr	   r
   r   r   r!   r   r   <module>r=      s    " " " " " " : : : : : : : : : : : : 4 4 4 4 4 4 4 4 4 4(4 (4 (4 (4 (4B (4 (4 (4 (4 (4r   