
    Eg                     \    d dl Z d dlmZ d dlmZ  G d d          Z G d de          ZdS )    N)DesiredCapabilities)
ArgOptionsc                   "    e Zd ZddZdefdZdS )LogreturnNc                     d | _         d S Nlevelselfs    V/var/www/sysmax/venv/lib/python3.11/site-packages/selenium/webdriver/safari/options.py__init__zLog.__init__   s    


    c                 *    | j         rdd| j         iiS i S )Nlogr   r
   r   s    r   to_capabilitieszLog.to_capabilities   s#    : 	2GTZ011	r   r   N)__name__
__module____qualname__r   dictr    r   r   r   r      sC                 r   r   c                       e Zd ZdZdZdZdZd fdZede	fd            Z
e
j        d	e	ddfd
            Z
defdZedej        e	e	f         fd            Zedefd            Zej        d	eddfd            Zedefd            Zej        d	eddfd            Zedefd            Zej        d	eddfd            Z xZS )Optionszsafari.optionszsafari:automaticInspectionzsafari:automaticProfilingzSafari Technology Previewr   Nc                     t                                                       d | _        i | _        t	                      | _        d S r	   )superr   _binary_location_preferencesr   r   )r   	__class__s    r   r   zOptions.__init__*   s8     $"$55r   c                     | j         S )zX
        :Returns: The location of the browser binary otherwise an empty string
        r   r   s    r   binary_locationzOptions.binary_location0   s    
 $$r   valuec                     || _         dS )zvAllows you to set the browser binary to launch.

        :Args:
         - value : path to the browser binary
        Nr"   r   r$   s     r   r#   zOptions.binary_location7   s     !&r   c                     | j         }i }| j        r
| j        |d<   | j        r
| j        |d<   |                    | j                                                   |r||t          j        <   |S )z8Marshals the  options to an desired capabilities object.argsbinary)_caps
_argumentsr   updater   r   r   KEY)r   capsoptss      r   r   zOptions.to_capabilities@   su     z? 	+?DL  	3!2DNDH,,../// 	% $Dr   c                 >    t           j                                        S r	   )r   SAFARIcopyr   s    r   default_capabilitieszOptions.default_capabilitiesT   s    ")..000r   c                 @    | j                             | j                  S )z/:Returns: The option Automatic Inspection value)r*   getAUTOMATIC_INSPECTIONr   s    r   automatic_inspectionzOptions.automatic_inspectionX   s     z~~d7888r   c                 <    |                      | j        |           dS )zgSets the option Automatic Inspection to value.

        :Args:
         - value: boolean value
        N)set_capabilityr6   r&   s     r   r7   zOptions.automatic_inspection]   s#     	D5u=====r   c                 @    | j                             | j                  S )z/:Returns: The options Automatic Profiling value)r*   r5   AUTOMATIC_PROFILINGr   s    r   automatic_profilingzOptions.automatic_profilingf   s     z~~d6777r   c                 <    |                      | j        |           dS )zfSets the option Automatic Profiling to value.

        :Args:
         - value: boolean value
        N)r9   r;   r&   s     r   r<   zOptions.automatic_profilingk   s#     	D4e<<<<<r   c                 H    | j                             d          | j        k    S )zD:Returns: whether BROWSER_NAME is equal to Safari Technology PreviewbrowserName)r*   r5   SAFARI_TECH_PREVIEWr   s    r   use_technology_previewzOptions.use_technology_previewt   s      z~~m,,0HHHr   c                 D    |                      d|r| j        nd           dS )zSets browser name to Safari Technology Preview if value else to
        safari.

        :Args:
         - value: boolean value
        r?   safariN)r9   r@   r&   s     r   rA   zOptions.use_technology_previewy   s.     	Mu+Z4+C+CRZ[[[[[r   r   )r   r   r   r-   r6   r;   r@   r   propertystrr#   setterr   r   typingDictr3   boolr7   r<   rA   __classcell__)r    s   @r   r   r   !   s       
C 855      % % % % X% &S &T & & & &    ( 1fk#s(&; 1 1 1 X1 9d 9 9 9 X9  >$ >4 > > > ! > 8T 8 8 8 X8 = =$ = = =  = I I I I XI "\D \T \ \ \ #"\ \ \ \ \r   r   )rG   .selenium.webdriver.common.desired_capabilitiesr   !selenium.webdriver.common.optionsr   r   r   r   r   r   <module>rM      s   "  N N N N N N 8 8 8 8 8 8       `\ `\ `\ `\ `\j `\ `\ `\ `\ `\r   