Ë
    Ã?Æi\  ã                  ón   — d Z ddlmZ ddlZddl­ ddlmZ  ej                  d«      Zd
d„Z	d
d„Z
dd	„Zy)a‡  PTIN (U.S. Preparer Tax Identification Number).

A Preparer Tax Identification Number (PTIN) is United States
identification number for tax return preparers. It is an eight-digit
number prefixed with a capital P.

>>> validate('P-00634642')
'P00634642'
>>> validate('P01594846')
'P01594846'
>>> validate('00634642')  # missing P
Traceback (most recent call last):
    ...
InvalidFormat: ...
é    )ÚannotationsN)Ú*)Úcleanz^P[0-9]{8}$c                ó6   — t        | d«      j                  «       S )zˆConvert the number to the minimal representation. This strips the
    number of any valid separators and removes surrounding whitespace.ú-)r   Ústrip©Únumbers    úU/var/www/html/myprovider/mon_projet_qr/lib/python3.12/site-packages/stdnum/us/ptin.pyÚcompactr   0   s   € ô �˜Ó×#Ñ#Ó%Ð%ó    c                óv   — t        | «      j                  «       } t        j                  | «      s
t	        «       ‚| S )zhCheck if the number is a valid PTIN. This checks the length, groups
    and formatting if it is present.)r   ÚupperÚ_ptin_reÚsearchÚInvalidFormatr	   s    r   Úvalidater   6   s/   € ô �V‹_×"Ñ"Ó$€FÜ�?‰?˜6Ô"Ü‹oÐà€Mr   c                óJ   — 	 t        t        | «      «      S # t        $ r Y yw xY w)z$Check if the number is a valid ATIN.F)Úboolr   ÚValidationErrorr	   s    r   Úis_validr   @   s)   € ðÜ”H˜VÓ$Ó%Ð%øÜò Ùðús   ‚ –	"¡")r
   ÚstrÚreturnr   )r
   r   r   r   )Ú__doc__Ú
__future__r   ÚreÚstdnum.exceptionsÚstdnum.utilr   Úcompiler   r   r   r   © r   r   ú<module>r!      s9   ðñ(õ  #ã 	ä Ý ð ˆ2�:‰:�nÓ%€ó&óôr   