
    b?1i                     B    d Z ddlZddlmZ eddddeded	efd
       Zy)zDomain.    N   )	validatorF)rfc_1034rfc_2782valuer   r   c                  | sy	 t        j                  d|        xr[ t        j                  d|rdnd ddz   dz   d	|rd
nd z   | j                  d      j	                  d      t         j
                        S # t        $ r Y yw xY w)a  Return whether or not given value is a valid domain.

    Examples:
        >>> domain('example.com')
        # Output: True
        >>> domain('example.com/')
        # Output: ValidationError(func=domain, ...)
        >>> # Supports IDN domains as well::
        >>> domain('xn----gtbspbbmkef.xn--p1ai')
        # Output: True

    Args:
        value:
            Domain string to validate.
        rfc_1034:
            Allow trailing dot in domain name.
            Ref: [RFC 1034](https://www.rfc-editor.org/rfc/rfc1034).
        rfc_2782:
            Domain name is of type service record.
            Ref: [RFC 2782](https://www.rfc-editor.org/rfc/rfc2782).


    Returns:
        (Literal[True]):
            If `value` is a valid domain name.
        (ValidationError):
            If `value` is an invalid domain name.

    Note:
        - *In version 0.10.0*:
            - Added support for internationalized domain name (IDN) validation.

    > *New in version 0.9.0*.
    Fz\sz^(?:[a-zA-Z0-9_ ]z&(?:[a-zA-Z0-9-_]{0,61}[A-Za-z0-9])?\.)z+[A-Za-z0-9][A-Za-z0-9-_]{0,61}z[A-Za-z]z.$$idnazutf-8)researchmatchencodedecode
IGNORECASEUnicodeError)r   r   r   s      [/home/www/therecruiter.miabetepe.com/venv/lib/python3.12/site-packages/validators/domain.pydomainr   
   s    H 99UE** 
rxxHc"5Q778 1	1 8%678 LL ''0MM0
 	
  s   A3A9 9	BB)__doc__r   utilsr   strboolr        r   <module>r      s@     
  .3e 3# 3t 3t 3 3r   