
    8h
                     J    d dl Z d dlZd dlmZ  G d dej                        Zy)    N)servicec                   6    e Zd ZdZ	 	 	 	 	 	 ddedededej                  ej                  e      dej                  ej                  eef      ddf fd	Zdej                  e   fd
Zedefd       Zedefd       Zej                   deddfd       Z xZS )Servicea  A Service class that is responsible for the starting and stopping of
    `safaridriver`  This is only supported on MAC OSX.

    :param executable_path: install path of the safaridriver executable, defaults to `/usr/bin/safaridriver`.
    :param port: Port for the service to run on, defaults to 0 where the operating system will decide.
    :param quiet: (Deprecated) Suppress driver stdout & stderr, redirects to os.devnull if enabled.
    :param service_args: (Optional) List of args to be passed to the subprocess when launching the executable.
    :param env: (Optional) Mapping of environment variables for the new process, defaults to `os.environ`.
    Nexecutable_pathportquietservice_argsenvreturnc                     |xs g | _         |t        j                  dt        d       || _        t        |   d|||d| y )Nz+quiet is no longer needed to supress output   )
stacklevel)
executabler   r
    )r	   warningswarnDeprecationWarning_reuse_servicesuper__init__)	selfr   r   r   r	   r
   reuse_servicekwargs	__class__s	           x/home/stella.sw7ft.com/public_html/site_rebuilder/venv/lib/python3.12/site-packages/selenium/webdriver/safari/service.pyr   zService.__init__#   sX     ).BMMGI[hij+ 	
&	
 		
    c                 :    d| j                    g| j                  z   S )Nz-p)r   r	   r   s    r   command_line_argszService.command_line_args9   s    %(9(999r   c                      d| j                    S )z)Gets the url of the SafariDriver Service.zhttp://localhost:)r   r   s    r   service_urlzService.service_url<   s     #499+..r   c                     | j                   S )N)r   r   s    r   r   zService.reuse_serviceA   s    """r   reusec                 H    t        |t              st        d      || _        y )Nzreuse must be a boolean)
isinstancebool	TypeErrorr   )r   r#   s     r   r   zService.reuse_serviceE   s     %&566#r   )Nr   NNNF)__name__
__module____qualname____doc__strintr&   typingOptionalListMappingr   r   propertyr!   r   setter__classcell__)r   s   @r   r   r      s      $:>9=

 
 	

 oofkk#&67
 __V^^CH56
 

,:6;;s#3 : /S / / #t # # $4 $D $ $r   r   )r.   r   selenium.webdriver.commonr   r   r   r   r   <module>r6      s    $   -1$goo 1$r   