
    yIf                    z    d dl mZ d dlmZ erd dlZej        dk    rd dlmZ nd dlmZ  G d d          ZdgZ	dS )    )annotations)TYPE_CHECKINGN)      )Selfc                      e Zd ZdZdZ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S )Sectionztox configuration section.:prefix
str | NonenamestrreturnNonec                "    || _         || _        d S N)_prefix_name)selfr   r   s      M/var/www/piapp/venv/lib/python3.11/site-packages/tox/config/loader/section.py__init__zSection.__init__   s    


    cls
type[Self]keyr   c                    |                     | j                  }|dk    rd|}}n|d|         ||dz   d         }} | ||          S )z
        Create a section from a section key.

        :param key: the section key
        :return: the constructed section
        N   )findSEP)r   r   sep_atr   r   s        r   from_keyzSection.from_key   s[     #'""R<<DFFww<VaZ\\):DFs64   r   c                    | j         S )z":return: the prefix of the section)r   r   s    r   r   zSection.prefix&   s     |r   c                    | j         S )z :return: the name of the section)r   r$   s    r   r   zSection.name+   s     zr   c                b    | j                             d | j        | j        fD                       S )z:return: the section keyc              3     K   | ]}||V  	d S r    ).0is     r   	<genexpr>zSection.key.<locals>.<genexpr>3   s"      TT1amQmmmmTTr   )r    joinr   r   r$   s    r   r   zSection.key0   s0     x}}TTtz(BTTTTTTr   c                    | j         S r   )r   r$   s    r   __str__zSection.__str__5   s	    xr   c                @    | j         j         d| j        d| j        dS )Nz(prefix=z, name=))	__class____name__r   r   r$   s    r   __repr__zSection.__repr__8   s*    .)YY4<YY$*YYYYr   otherobjectboolc                h    t          || j                  o| j        | j        f|j        |j        fk    S r   )
isinstancer1   r   r   r   )r   r4   s     r   __eq__zSection.__eq__;   s;    %00 
dlDJ5OMJT
 6
 	
r   N)r   r   r   r   r   r   )r   r   r   r   r   r   )r   r   )r   r   )r4   r5   r   r6   )r2   
__module____qualname____doc__r    r   classmethodr"   propertyr   r   r   r.   r3   r9   r(   r   r   r	   r	      s        $$
C    ! ! ! [!    X    X U U U XU   Z Z Z Z
 
 
 
 
 
r   r	   )

__future__r   typingr   sysversion_infor   typing_extensionsr	   __all__r(   r   r   <module>rE      s    " " " " " "             +JJJ
7""******1
 1
 1
 1
 1
 1
 1
 1
j r   