Ë
    û—h�3  ã                   ó  — d dl mZmZmZ d dlmZ  G d„ d«      Z G d„ d«      Z G d„ d«      Z G d	„ d
«      Z	 G d„ d«      Z
 G d„ d«      Z G d„ d«      Z G d„ d«      Z G d„ d«      Z G d„ d«      Z G d„ d«      Z G d„ d«      Zy)é    )ÚAnyÚOptionalÚUnion)Úcommand_builderc                   ó   — e Zd ZdZdZdZdZy)ÚSameSitez5Represents the possible same site values for cookies.ÚstrictÚlaxÚnoneN)Ú__name__Ú
__module__Ú__qualname__Ú__doc__ÚSTRICTÚLAXÚNONE© ó    úi/home/bbl/html/w1hd.aprs.trek/venv/lib/python3.12/site-packages/selenium/webdriver/common/bidi/storage.pyr   r      s   „ Ù?à€FØ
€CØ�Dr   r   c                   ó4   — e Zd ZdZdZdZdedefd„Zdefd„Z	y	)
Ú
BytesValuezRepresents a bytes value.Úbase64ÚstringÚtypeÚvaluec                 ó    — || _         || _        y ©N©r   r   )Úselfr   r   s      r   Ú__init__zBytesValue.__init__%   s   € ØˆŒ	Øˆ�
r   Úreturnc                 ó4   — | j                   | j                  dœS )z”Converts the BytesValue to a dictionary.

        Returns:
        -------
            Dict: A dictionary representation of the BytesValue.
        r   r   ©r   s    r   Úto_dictzBytesValue.to_dict)   s   € ð Ÿ	™	¨D¯J©JÑ7Ð7r   N)
r   r   r   r   ÚTYPE_BASE64ÚTYPE_STRINGÚstrr    Údictr$   r   r   r   r   r      s.   „ Ù#à€KØ€Kð˜Sð ¨ó ð8˜ô 8r   r   c                   óˆ   — e Zd ZdZ	 	 	 	 	 	 ddedededee   dee   dee   d	ee   d
ee   dee   fd„Z	e
dedd fd„«       Zy)ÚCookiezRepresents a cookie.NÚnamer   ÚdomainÚpathÚsizeÚ	http_onlyÚsecureÚ	same_siteÚexpiryc
                 ó‚   — || _         || _        || _        || _        || _        || _        || _        || _        |	| _        y r   ©	r+   r   r,   r-   r.   r/   r0   r1   r2   ©
r   r+   r   r,   r-   r.   r/   r0   r1   r2   s
             r   r    zCookie.__init__6   óC   € ð ˆŒ	ØˆŒ
ØˆŒØˆŒ	ØˆŒ	Ø"ˆŒØˆŒØ"ˆŒØˆ�r   Údatar!   c                 ó  — |j                  d«      }|st        d«      ‚|j                  d«      }|st        d«      ‚t        |j                  di «      j                  d«      |j                  di «      j                  d«      «      } | t        |«      |t        |«      |j                  d«      |j                  d«      |j                  d	«      |j                  d
«      |j                  d«      |j                  d«      ¬«	      S )zðCreates a Cookie instance from a dictionary.

        Parameters:
        -----------
            data: A dictionary containing the cookie information.

        Returns:
        -------
            Cookie: A new instance of Cookie.
        r+   z$name is required and cannot be emptyr,   z&domain is required and cannot be emptyr   r   r-   r.   ÚhttpOnlyr0   ÚsameSiter2   r4   )ÚgetÚ
ValueErrorr   r'   )Úclsr7   r+   r,   r   s        r   Ú	from_dictzCookie.from_dictL   sÞ   € ð �x‰x˜ÓˆÙÜÐCÓDÐDØ—‘˜(Ó#ˆÙÜÐEÓFÐFä˜4Ÿ8™8 G¨RÓ0×4Ñ4°VÓ<¸d¿h¹hÀwÐPRÓ>S×>WÑ>WÐX_Ó>`ÓaˆÙÜ�T“ØÜ�v“;Ø—‘˜&Ó!Ø—‘˜&Ó!Ø—h‘h˜zÓ*Ø—8‘8˜HÓ%Ø—h‘h˜zÓ*Ø—8‘8˜HÓ%ô

ð 
	
r   )NNNNNN)r   r   r   r   r'   r   r   ÚintÚboolr    Úclassmethodr(   r>   r   r   r   r*   r*   3   s°   „ Ùð #Ø"Ø$(Ø!%Ø#'Ø $ñàðð ðð ð	ð
 �s‰mðð �s‰mðð ˜D‘>ðð ˜‘ðð ˜C‘=ðð ˜‘óð, ð
˜Tð 
 hò 
ó ñ
r   r*   c                   óœ   — e Zd ZdZ	 	 	 	 	 	 	 	 	 ddee   dee   dee   dee   dee   dee   d	ee   d
ee   dee   fd„Z	de
eef   fd„Zy)ÚCookieFilterz Represents a filter for cookies.Nr+   r   r,   r-   r.   r/   r0   r1   r2   c
                 ó‚   — || _         || _        || _        || _        || _        || _        || _        || _        |	| _        y r   r4   r5   s
             r   r    zCookieFilter.__init__q   r6   r   r!   c                 ó  — i }| j                   �| j                   |d<   | j                  �| j                  j                  «       |d<   | j                  �| j                  |d<   | j                  �| j                  |d<   | j
                  �| j
                  |d<   | j                  �| j                  |d<   | j                  �| j                  |d<   | j                  �| j                  |d<   | j                  �| j                  |d	<   |S )
z˜Converts the CookieFilter to a dictionary.

        Returns:
        -------
            Dict: A dictionary representation of the CookieFilter.
        r+   r   r,   r-   r.   r9   r0   r:   r2   )
r+   r   r$   r,   r-   r.   r/   r0   r1   r2   ©r   Úresults     r   r$   zCookieFilter.to_dict‡   së   € ð "$ˆØ�9‰9Ð Ø!ŸY™YˆF�6‰NØ�:‰:Ð!Ø"Ÿj™j×0Ñ0Ó2ˆF�7‰OØ�;‰;Ð"Ø#Ÿ{™{ˆF�8ÑØ�9‰9Ð Ø!ŸY™YˆF�6‰NØ�9‰9Ð Ø!ŸY™YˆF�6‰NØ�>‰>Ð%Ø!%§¡ˆF�:ÑØ�;‰;Ð"Ø#Ÿ{™{ˆF�8ÑØ�>‰>Ð%Ø!%§¡ˆF�:ÑØ�;‰;Ð"Ø#Ÿ{™{ˆF�8ÑØˆr   )	NNNNNNNNN)r   r   r   r   r   r'   r   r?   r@   r    r(   r   r$   r   r   r   rC   rC   n   s¸   „ Ù*ð #Ø&*Ø $Ø"Ø"Ø$(Ø!%Ø#'Ø $ñà�s‰mðð ˜
Ñ#ðð ˜‘ð	ð
 �s‰mðð �s‰mðð ˜D‘>ðð ˜‘ðð ˜C‘=ðð ˜‘óð,˜˜c 3˜h™ô r   rC   c                   óH   — e Zd ZdZd	dee   dee   fd„Zededd fd„«       Z	y)
ÚPartitionKeyz#Represents a storage partition key.NÚuser_contextÚsource_originc                 ó    — || _         || _        y r   ©rJ   rK   ©r   rJ   rK   s      r   r    zPartitionKey.__init__§   s   € Ø(ˆÔØ*ˆÕr   r7   r!   c                 óR   —  | |j                  d«      |j                  d«      ¬«      S )a	  Creates a PartitionKey instance from a dictionary.

        Parameters:
        -----------
            data: A dictionary containing the partition key information.

        Returns:
        -------
            PartitionKey: A new instance of PartitionKey.
        ÚuserContextÚsourceOriginrM   )r;   )r=   r7   s     r   r>   zPartitionKey.from_dict«   s)   € ñ ØŸ™ -Ó0ØŸ(™( >Ó2ô
ð 	
r   ©NN)
r   r   r   r   r   r'   r    rA   r(   r>   r   r   r   rI   rI   ¤   sC   „ Ù-ñ+ X¨c¡]ð +È(ÐSVÉ-ó +ð ð
˜Tð 
 nò 
ó ñ
r   rI   c                   ó(   — e Zd ZdZdefd„Zdefd„Zy)Ú"BrowsingContextPartitionDescriptorz3Represents a browsing context partition descriptor.Úcontextc                 ó    — d| _         || _        y )NrU   ©r   rU   )r   rU   s     r   r    z+BrowsingContextPartitionDescriptor.__init__À   s   € ØˆŒ	Øˆ�r   r!   c                 ó4   — | j                   | j                  dœS )zÄConverts the BrowsingContextPartitionDescriptor to a dictionary.

        Returns:
        -------
            Dict: A dictionary representation of the BrowsingContextPartitionDescriptor.
        rW   rW   r#   s    r   r$   z*BrowsingContextPartitionDescriptor.to_dictÄ   s   € ð Ÿ	™	¨d¯l©lÑ;Ð;r   N)r   r   r   r   r'   r    r(   r$   r   r   r   rT   rT   ½   s   „ Ù=ð ó ð<˜ô <r   rT   c                   ó:   — e Zd ZdZddee   dee   fd„Zdefd„Zy)	ÚStorageKeyPartitionDescriptorz.Represents a storage key partition descriptor.NrJ   rK   c                 ó.   — d| _         || _        || _        y )NÚ
storageKey©r   rJ   rK   rN   s      r   r    z&StorageKeyPartitionDescriptor.__init__Ñ   s   € Ø ˆŒ	Ø(ˆÔØ*ˆÕr   r!   c                 óŽ   — d| j                   i}| j                  �| j                  |d<   | j                  �| j                  |d<   |S )zºConverts the StorageKeyPartitionDescriptor to a dictionary.

        Returns:
        -------
            Dict: A dictionary representation of the StorageKeyPartitionDescriptor.
        r   rP   rQ   r]   rF   s     r   r$   z%StorageKeyPartitionDescriptor.to_dictÖ   sO   € ð ˜$Ÿ)™)Ð$ˆØ×ÑÐ(Ø$(×$5Ñ$5ˆF�=Ñ!Ø×ÑÐ)Ø%)×%7Ñ%7ˆF�>Ñ"Øˆr   rR   )	r   r   r   r   r   r'   r    r(   r$   r   r   r   rZ   rZ   Î   s-   „ Ù8ñ+ X¨c¡]ð +È(ÐSVÉ-ó +ð
˜ô r   rZ   c                   óx   — e Zd ZdZ	 	 	 	 	 ddedededee   dee   dee   d	ee   d
ee   fd„Z	de
eef   fd„Zy)ÚPartialCookiez(Represents a partial cookie for setting.Nr+   r   r,   r-   r/   r0   r1   r2   c	                 ót   — || _         || _        || _        || _        || _        || _        || _        || _        y r   )r+   r   r,   r-   r/   r0   r1   r2   )	r   r+   r   r,   r-   r/   r0   r1   r2   s	            r   r    zPartialCookie.__init__è   s<   € ð ˆŒ	ØˆŒ
ØˆŒØˆŒ	Ø"ˆŒØˆŒØ"ˆŒØˆ�r   r!   c                 óx  — | j                   | j                  j                  «       | j                  dœ}| j                  �| j                  |d<   | j
                  �| j
                  |d<   | j                  �| j                  |d<   | j                  �| j                  |d<   | j                  �| j                  |d<   |S )zšConverts the PartialCookie to a dictionary.

        Returns:
        -------
            Dict: A dictionary representation of the PartialCookie.
        )r+   r   r,   r-   r9   r0   r:   r2   )	r+   r   r$   r,   r-   r/   r0   r1   r2   rF   s     r   r$   zPartialCookie.to_dictü   s§   € ð —I‘IØ—Z‘Z×'Ñ'Ó)Ø—k‘kñ"
ˆð
 �9‰9Ð Ø!ŸY™YˆF�6‰NØ�>‰>Ð%Ø!%§¡ˆF�:ÑØ�;‰;Ð"Ø#Ÿ{™{ˆF�8ÑØ�>‰>Ð%Ø!%§¡ˆF�:ÑØ�;‰;Ð"Ø#Ÿ{™{ˆF�8ÑØˆr   )NNNNN)r   r   r   r   r'   r   r   r@   r?   r    r(   r   r$   r   r   r   r`   r`   å   s‘   „ Ù2ð #Ø$(Ø!%Ø#'Ø $ñàðð ðð ð	ð
 �s‰mðð ˜D‘>ðð ˜‘ðð ˜C‘=ðð ˜‘óð(˜˜c 3˜h™ô r   r`   c                   ó@   — e Zd ZdZdee   defd„Zede	dd fd„«       Z
y)	ÚGetCookiesResultz.Represents the result of a getCookies command.ÚcookiesÚpartition_keyc                 ó    — || _         || _        y r   ©re   rf   )r   re   rf   s      r   r    zGetCookiesResult.__init__  s   € ØˆŒØ*ˆÕr   r7   r!   c                 óÎ   — |j                  dg «      D �cg c]  }t        j                  |«      ‘Œ }}t        j                  |j                  di «      «      } | ||¬«      S c c}w )a  Creates a GetCookiesResult instance from a dictionary.

        Parameters:
        -----------
            data: A dictionary containing the get cookies result information.

        Returns:
        -------
            GetCookiesResult: A new instance of GetCookiesResult.
        re   ÚpartitionKeyrh   )r;   r*   r>   rI   )r=   r7   Úcookiere   rf   s        r   r>   zGetCookiesResult.from_dict  s[   € ð ;?¿(¹(À9ÈbÓ:QÖR°”6×#Ñ# FÕ+ÐRˆÐRÜ$×.Ñ.¨t¯x©x¸ÈÓ/KÓLˆÙ˜7°-Ô@Ð@ùò Ss   •A"N)r   r   r   r   Úlistr*   rI   r    rA   r(   r>   r   r   r   rd   rd     sC   „ Ù8ð+  V¡ð +¸\ó +ð ðA˜Tð AÐ&8ò Aó ñAr   rd   c                   ó6   — e Zd ZdZdefd„Zededd fd„«       Zy)ÚSetCookieResultz-Represents the result of a setCookie command.rf   c                 ó   — || _         y r   ©rf   ©r   rf   s     r   r    zSetCookieResult.__init__0  ó
   € Ø*ˆÕr   r7   r!   c                 ó^   — t         j                  |j                  di «      «      } | |¬«      S )a  Creates a SetCookieResult instance from a dictionary.

        Parameters:
        -----------
            data: A dictionary containing the set cookie result information.

        Returns:
        -------
            SetCookieResult: A new instance of SetCookieResult.
        rj   rp   ©rI   r>   r;   ©r=   r7   rf   s      r   r>   zSetCookieResult.from_dict3  ó*   € ô %×.Ñ.¨t¯x©x¸ÈÓ/KÓLˆÙ Ô/Ð/r   N©	r   r   r   r   rI   r    rA   r(   r>   r   r   r   rn   rn   -  s4   „ Ù7ð+ ló +ð ð0˜Tð 0Ð&7ò 0ó ñ0r   rn   c                   ó6   — e Zd ZdZdefd„Zededd fd„«       Zy)ÚDeleteCookiesResultz1Represents the result of a deleteCookies command.rf   c                 ó   — || _         y r   rp   rq   s     r   r    zDeleteCookiesResult.__init__F  rr   r   r7   r!   c                 ó^   — t         j                  |j                  di «      «      } | |¬«      S )a&  Creates a DeleteCookiesResult instance from a dictionary.

        Parameters:
        -----------
            data: A dictionary containing the delete cookies result information.

        Returns:
        -------
            DeleteCookiesResult: A new instance of DeleteCookiesResult.
        rj   rp   rt   ru   s      r   r>   zDeleteCookiesResult.from_dictI  rv   r   Nrw   r   r   r   ry   ry   C  s4   „ Ù;ð+ ló +ð ð0˜Tð 0Ð&;ò 0ó ñ0r   ry   c                   óž   — e Zd ZdZd„ Z	 	 ddee   deeee	f      de
fd„Z	 ddedeeee	f      defd	„Z	 	 ddee   deeee	f      defd
„Zy)ÚStoragez*BiDi implementation of the storage module.c                 ó   — || _         y r   )Úconn)r   r   s     r   r    zStorage.__init__\  s	   € Øˆ�	r   NÚfilterÚ	partitionr!   c                 óÎ   — i }|�|j                  «       |d<   |�|j                  «       |d<   | j                  j                  t        d|«      «      }t        j                  |«      S )a7  Retrieves cookies that match the given parameters.

        Parameters:
        -----------
            filter: Optional filter to match cookies.
            partition: Optional partition descriptor.

        Returns:
        -------
            GetCookiesResult: The result of the get cookies command.
        r€   r�   zstorage.getCookies)r$   r   Úexecuter   rd   r>   ©r   r€   r�   ÚparamsrG   s        r   Úget_cookieszStorage.get_cookies_  sf   € ð  ˆØÐØ%Ÿ~™~Ó/ˆF�8ÑØÐ Ø"+×"3Ñ"3Ó"5ˆF�;Ñà—‘×"Ñ"¤?Ð3GÈÓ#PÓQˆÜ×)Ñ)¨&Ó1Ð1r   rk   c                 óÄ   — d|j                  «       i}|�|j                  «       |d<   | j                  j                  t        d|«      «      }t        j                  |«      S )a  Sets a cookie in the browser.

        Parameters:
        -----------
            cookie: The cookie to set.
            partition: Optional partition descriptor.

        Returns:
        -------
            SetCookieResult: The result of the set cookie command.
        rk   r�   zstorage.setCookie)r$   r   rƒ   r   rn   r>   )r   rk   r�   r…   rG   s        r   Ú
set_cookiezStorage.set_cookiex  s[   € ð  ˜FŸN™NÓ,Ð-ˆØÐ Ø"+×"3Ñ"3Ó"5ˆF�;Ñà—‘×"Ñ"¤?Ð3FÈÓ#OÓPˆÜ×(Ñ(¨Ó0Ð0r   c                 óÎ   — i }|�|j                  «       |d<   |�|j                  «       |d<   | j                  j                  t        d|«      «      }t        j                  |«      S )aE  Deletes cookies that match the given parameters.

        Parameters:
        -----------
            filter: Optional filter to match cookies to delete.
            partition: Optional partition descriptor.

        Returns:
        -------
            DeleteCookiesResult: The result of the delete cookies command.
        r€   r�   zstorage.deleteCookies)r$   r   rƒ   r   ry   r>   r„   s        r   Údelete_cookieszStorage.delete_cookies�  sf   € ð  ˆØÐØ%Ÿ~™~Ó/ˆF�8ÑØÐ Ø"+×"3Ñ"3Ó"5ˆF�;Ñà—‘×"Ñ"¤?Ð3JÈFÓ#SÓTˆÜ"×,Ñ,¨VÓ4Ð4r   rR   r   )r   r   r   r   r    r   rC   r   rT   rZ   rd   r†   r`   rn   rˆ   ry   rŠ   r   r   r   r}   r}   Y  sÁ   „ Ù4òð
 *.Øhlñ2à˜Ñ&ð2ð ˜EÐ"DÐFcÐ"cÑdÑeð2ð 
ó	2ð8 imñ1àð1ð ˜EÐ"DÐFcÐ"cÑdÑeð1ð 
ó	1ð2 *.Øhlñ5à˜Ñ&ð5ð ˜EÐ"DÐFcÐ"cÑdÑeð5ð 
ô	5r   r}   N)Útypingr   r   r   Ú%selenium.webdriver.common.bidi.commonr   r   r   r*   rC   rI   rT   rZ   r`   rd   rn   ry   r}   r   r   r   ú<module>r�      s�   ð÷$ (Ñ 'å A÷ñ ÷8ñ 8÷(8
ñ 8
÷v3ñ 3÷l
ñ 
÷2<ñ <÷"ñ ÷.-ñ -÷`Añ A÷00ñ 0÷,0ñ 0÷,M5ò M5r   