Ë
    XV.jé  ã                   óf   — d dl Z d dlZd dlmZ d dlmZ d dlmZmZ ddlm	Z	 dZ
dZ G d	„ d
e	«      Zy)é    N)Úceil)Úascii_uppercase)ÚDictÚOptionalé   )ÚBaseProviderTÚen_GBc                   ó<  — e Zd ZU dZej
                  D � ���ci c]  }|t        t        |«      dz  «      “Œ c}}}} Ze	eef   e
d<   dZee
d<   dZee
d<   defd	„Zdefd
„Zdefd„Zdefd„Zddedefd„Zddededefd„Z	 	 	 ddee   dededefd„Zyc c}}}} w )ÚProvidera  Implement default bank provider for Faker.

    .. important::
       Bank codes, account numbers, and other ID's generated by this provider
       are only valid in form, i.e. they conform to some standard/format, are
       of the expected lengths, and have valid checksums (where applicable).
       Results generated that turn out to be valid in real life are purely
       coincidental.

    Sources:

    - https://en.wikipedia.org/wiki/International_Bank_Account_Number
    - https://www.theswiftcodes.com/swift-code-checker/
    é7   ÚALPHAz????#############Úbban_formatÚGBÚcountry_codeÚreturnc                 ó0  — | j                  dd¬«      }| j                  d«      }|d›|› �}|D �cg c]  }t        |«      ‘Œ }}d|d   |d   z   |d   z   z  d	|d   |d
   z   |d	   z   z  z   |d   z   |d   z   }t        |dz  «      dz  |z
  }|› |› �S c c}w )z'Generate an ABA routing transit number.é   é   )ÚminÚmaxz######Ú02é   r   é   é   é   r   é   é
   )Ú
random_intÚnumerifyÚintr   )ÚselfÚfed_numÚrandÚabaÚnÚdÚ	chk_digits          ú_C:\xampp\htdocs\tradingbinance\backend\.venv\Lib\site-packages\faker/providers/bank/__init__.pyr$   zProvider.aba"   sË   € à—/‘/ a¨R�/Ó0ˆØ�}‰}˜XÓ&ˆØ˜�˜T˜FÐ#ˆñ !Ó!™S˜ŒS��V˜SˆÐ!Ø˜˜1™  !¡™ q¨¡tÑ+Ñ,¨q°A°a±D¸1¸Q¹4±KÀ!ÀAÁ$Ñ4FÑ/GÑGÈ!ÈAÉ$ÑNÐQRÐSTÑQUÑUˆ	Ü˜ R™Ó(¨2Ñ-°	Ñ9ˆ	à��y�kÐ"Ð"ùò	 "s   °Bc                 ó   — | j                   S )z=Generate the bank provider's ISO 3166-1 alpha-2 country code.)r   )r!   s    r(   Úbank_countryzProvider.bank_country/   s   € à× Ñ Ð ó    c                 ón   ‡ — t        j                  dˆ fd„‰ j                  «      }‰ j                  |«      S )z,Generate a Basic Bank Account Number (BBAN).z\?c                 ó.   •— ‰j                  t        «      S ©N)Úrandom_elementr   )Úxr!   s    €r(   Ú<lambda>zProvider.bban.<locals>.<lambda>5   s   ø€  t×':Ñ':¼?Ô'Kr+   )ÚreÚsubr   r   )r!   Útemps   ` r(   ÚbbanzProvider.bban3   s+   ø€ ä�v‰v�eÓKÈT×M]ÑM]Ó^ˆØ�}‰}˜TÓ"Ð"r+   c                 óö   ‡ — ‰ j                  «       }|‰ j                  z   dz   }t        dj                  ˆ fd„|D «       «      «      }d|dz  z
  }t	        |«      j                  d«      }‰ j                  |z   |z   S )z5Generate an International Bank Account Number (IBAN).Ú00Ú c              3   óV   •K  — | ]   }‰j                   j                  ||«      –— Œ" y ­wr.   )r   Úget)Ú.0Úcr!   s     €r(   Ú	<genexpr>z Provider.iban.<locals>.<genexpr>=   s!   øè ø€ ÐA¹5°a˜TŸZ™ZŸ^™^¨A¨q×1¹5ùs   ƒ&)éb   éa   r   )r5   r   r    ÚjoinÚstrÚzfill)r!   r5   ÚcheckÚcheck_s   `   r(   ÚibanzProvider.iban8   st   ø€ à�y‰y‹{ˆà�t×(Ñ(Ñ(¨4Ñ/ˆÜ�R—W‘WÓA¹5ÓAÓAÓBˆØ�v ‘{Ñ#ˆÜ�F“×!Ñ! !Ó$ˆà× Ñ  5Ñ(¨4Ñ/Ð/r+   Úuse_datasetc                 ó(   — | j                  d|¬«      S )a6  Generate an 8-digit SWIFT code.

        This method uses |swift| under the hood with the ``length`` argument set
        to ``8`` and with the ``primary`` argument omitted. All 8-digit SWIFT
        codes already refer to the primary branch/office.

        :sample:
        :sample: use_dataset=True
        é   )ÚlengthrF   ©Úswift)r!   rF   s     r(   Úswift8zProvider.swift8C   s   € ð �z‰z °ˆzÓ<Ð<r+   Úprimaryc                 ó*   — | j                  d||¬«      S )ax  Generate an 11-digit SWIFT code.

        This method uses |swift| under the hood with the ``length`` argument set
        to ``11``. If ``primary`` is set to ``True``, the SWIFT code will always
        end with ``'XXX'``. All 11-digit SWIFT codes use this convention to
        refer to the primary branch/office.

        :sample:
        :sample: use_dataset=True
        é   )rI   rM   rF   rJ   )r!   rM   rF   s      r(   Úswift11zProvider.swift11O   s   € ð �z‰z ¨WÀ+ˆzÓNÐNr+   NrI   c                 ó®  — |€| j                  d«      }|dvrt        d«      ‚|r(t        | d«      r| j                  | j                  «      }n!| j	                  dt
        j                  ¬«      }|r(t        | d«      r| j                  | j                  «      }n2| j	                  dt
        j                  t
        j                  z   ¬«      }|dk(  r|| j                  z   |z   S |rd	}n\|r(t        | d
«      r| j                  | j                  «      }n2| j	                  dt
        j                  t
        j                  z   ¬«      }|| j                  z   |z   |z   S )a{  Generate a SWIFT code.

        SWIFT codes, reading from left to right, are composed of a 4 alphabet
        character bank code, a 2 alphabet character country code, a 2
        alphanumeric location code, and an optional 3 alphanumeric branch code.
        This means SWIFT codes can only have 8 or 11 characters, so the value of
        ``length`` can only be ``None`` or the integers ``8`` or ``11``. If the
        value is ``None``, then a value of ``8`` or ``11`` will randomly be
        assigned.

        Because all 8-digit SWIFT codes already refer to the primary branch or
        office, the ``primary`` argument only has an effect if the value of
        ``length`` is ``11``. If ``primary`` is ``True`` and ``length`` is
        ``11``, the 11-digit SWIFT codes generated will always end in ``'XXX'``
        to denote that they belong to primary branches/offices.

        For extra authenticity, localized providers may opt to include SWIFT
        bank codes, location codes, and branch codes used in their respective
        locales. If ``use_dataset`` is ``True``, this method will generate SWIFT
        codes based on those locale-specific codes if included. If those codes
        were not included, then it will behave as if ``use_dataset`` were
        ``False``, and in that mode, all those codes will just be randomly
        generated as per the specification.

        :sample:
        :sample: length=8
        :sample: length=8, use_dataset=True
        :sample: length=11
        :sample: length=11, primary=True
        :sample: length=11, use_dataset=True
        :sample: length=11, primary=True, use_dataset=True
        )rH   rO   zlength can only be 8 or 11Úswift_bank_codesz????)ÚlettersÚswift_location_codesz??rH   ÚXXXÚswift_branch_codesz???)r/   ÚAssertionErrorÚhasattrrR   ÚlexifyÚstringr   rT   Údigitsr   rV   )r!   rI   rM   rF   Ú	bank_codeÚlocation_codeÚbranch_codes          r(   rK   zProvider.swift\   s1  € ðL ˆ>Ø×(Ñ(¨Ó1ˆFØ˜Ñ Ü Ð!=Ó>Ð>áœ7 4Ð);Ô<Ø!×0Ñ0°×1FÑ1FÓG‰IàŸ™ F´F×4JÑ4J˜ÓKˆIáœ7 4Ð)?Ô@Ø!%×!4Ñ!4°T×5NÑ5NÓ!O‰Mà ŸK™K¨´f×6LÑ6LÌvÏ}É}Ñ6\˜KÓ]ˆMà�QŠ;Ø˜t×0Ñ0Ñ0°=Ñ@Ð@áØ‰KÙœW TÐ+?Ô@Ø×-Ñ-¨d×.EÑ.EÓF‰KàŸ+™+ e´V×5KÑ5KÌfÏmÉmÑ5[˜+Ó\ˆKà˜4×,Ñ,Ñ,¨}Ñ<¸{ÑJÐJr+   )F)FF)NFF)Ú__name__Ú
__module__Ú__qualname__Ú__doc__rZ   r   rA   Úordr   r   Ú__annotations__r   r   r$   r*   r5   rE   ÚboolrL   rP   r   r    rK   )r;   r<   rA   rc   s   0000r(   r   r      s   … ñð ;A×:PÒ:PÖQÑ:P°Q˜Q¤¤C¨£F¨R¡KÓ 0Ñ0Ð:PÔQ€Eˆ4��S�‰>ÓQØ*€K�Ó*Ø€L�#Óð#�Só #ð!˜có !ð#�có #ð
	0�có 	0ñ
= $ð 
=°3ó 
=ñO˜tð O¸$ð OÈ3ó Oð !%ØØ!ñ	?Kà˜‘ð?Kð ð?Kð ð	?Kð
 
ô?Kùõ} Rs   ™B
r   )r2   rZ   Úmathr   r   Útypingr   r   r8   r   Ú	localizedÚdefault_localer   © r+   r(   Ú<module>rk      s1   ðÛ 	Û å Ý "ß !å à€	Ø€ôMKˆ|õ MKr+   