관리-도구
편집 파일: models.cpython-38.pyc
U ʗRe� � @ s2 d Z ddlZddlmZmZmZ G dd� d�ZdS )zUtilities for defining models � N)�Any�Callable�Typec @ s� e Zd ZdZddgZeed dd�dd�Zed�d d �Z ee d�dd �Zee d�dd�Zee d�dd�Z ee d�dd�Zee d�dd�Zeeeege f e d�dd�ZdS )�KeyBasedCompareMixinz7Provides comparison capabilities that is based on a key�_compare_key�_defining_classN)�key�defining_class�returnc C s || _ || _d S �N)r r )�selfr r � r ��/builddir/build/BUILDROOT/alt-python38-pip-22.2.1-2.el8.x86_64/opt/alt/python38/lib/python3.8/site-packages/pip/_internal/utils/models.py�__init__ s zKeyBasedCompareMixin.__init__)r c C s t | j�S r )�hashr )r r r r �__hash__ s zKeyBasedCompareMixin.__hash__)�otherr c C s | � |tj�S r )�_compare�operator�__lt__�r r r r r r s zKeyBasedCompareMixin.__lt__c C s | � |tj�S r )r r �__le__r r r r r s zKeyBasedCompareMixin.__le__c C s | � |tj�S r )r r �__gt__r r r r r s zKeyBasedCompareMixin.__gt__c C s | � |tj�S r )r r �__ge__r r r r r s zKeyBasedCompareMixin.__ge__c C s | � |tj�S r )r r �__eq__r r r r r s zKeyBasedCompareMixin.__eq__)r �methodr c C s t || j�stS || j|j�S r )� isinstancer �NotImplementedr )r r r r r r r # s zKeyBasedCompareMixin._compare)�__name__� __module__�__qualname__�__doc__� __slots__r r r �intr �boolr r r r r r r r r r r r s r )r! r �typingr r r r r r r r �<module> s