Ë
    Ã?Æi  ã                  óJ   — d Z ddlmZ ddl­ ddlmZ d
d„Zd
d„Zdd„Zd
d„Z	y	)a  Y-tunnus (Finnish business identifier).

The number is an 8-digit code with a weighted checksum.

>>> validate('2077474-0')
'20774740'
>>> validate('2077474-1')  # invalid check digit
Traceback (most recent call last):
    ...
InvalidChecksum: ...
>>> format('2077474-0')
'2077474-0'
é    )Úannotations)Ú*)Úalvc                ó,   — t        j                  | «      S )zˆConvert the number to the minimal representation. This strips the
    number of any valid separators and removes surrounding whitespace.)r   Úcompact©Únumbers    úX/var/www/html/myprovider/mon_projet_qr/lib/python3.12/site-packages/stdnum/fi/ytunnus.pyr   r   *   s   € ô �;‰;�vÓÐó    c                ó,   — t        j                  | «      S )zkCheck if the number is a valid business identifier. This checks the
    length, formatting and check digit.)r   Úvalidater   s    r
   r   r   0   s   € ô �<‰<˜ÓÐr   c                óJ   — 	 t        t        | «      «      S # t        $ r Y yw xY w)z3Check if the number is a valid business identifier.F)Úboolr   ÚValidationErrorr   s    r
   Úis_validr   6   s)   € ðÜ”H˜VÓ$Ó%Ð%øÜò Ùðús   ‚ –	"¡"c                ó4   — t        | «      } | dd dz   | dd z   S )z8Reformat the number to the standard presentation format.Né   ú-)r   r   s    r
   Úformatr   >   s'   € ä�V‹_€FØ�"�1ˆ:˜Ñ˜f Q R˜jÑ(Ð(r   N)r	   ÚstrÚreturnr   )r	   r   r   r   )
Ú__doc__Ú
__future__r   Ústdnum.exceptionsÚ	stdnum.fir   r   r   r   r   © r   r
   ú<module>r      s)   ðñ,õ #ä Ý óó óô)r   