U
    H4fa
                     @   s   d dl mZmZ d dlZd dlZd dlZd dlZd dlmZ d dl	Z	d dl
mZ d dlmZ d dlmZ d dlmZ edZdd	d
Zdd Zedkre Zee dS )    )absolute_importprint_functionN)urlparse)SqliteCache)Client)Settings)	Transportzeepc                 C   sx   t jdd}|jdtdd d |jdddd	 |jd
ddd	 |jdddd	 |jddd |jddddd || S )NzZeep: The SOAP client)description	wsdl_filezPath or URL to the WSDL file)typehelpdefaultz--cache
store_truezEnable cache)actionr   z--no-verifyzDisable SSL verificationz	--verbosezEnable verbose outputz	--profilez.Enable profiling and save output to given file)r   z--no-strictFzDisable strict mode)r   r   r   )argparseArgumentParseradd_argumentstr
parse_args)argsparser r   1/tmp/pip-unpacked-wheel-04z2hmy8/zeep/__main__.pyparse_arguments   s2             r   c           
   
   C   s  | j r>tjddddiidddddid	dd
dgdid | jr\dd l}| }|  | jrht	 nd }t
 }| jrd|_t| j}|js|jr|j|jf|_t||d}t }t| j d}t| j||d}	tdt | d  | jr
|  || j |	j  d S )N   verboseformatz%(name)20s: %(message)sconsoleDEBUGzlogging.StreamHandler)levelclass	formatterr	   T)r    	propagatehandlers)version
formattersr$   loggersr   F)cachesession)strict)	transportsettingszLoading WSDL took %smsi  )r   loggingconfig
dictConfigprofilecProfileZProfileenabler(   r   requestsSessionZ	no_verifyverifyr   r   usernamepasswordauthr   timer   Z	no_strictr   loggerdebugdisableZ
dump_statswsdldump)
r   r1   r0   r(   r)   resultr+   str,   clientr   r   r   main&   sL    

rB   __main__)N)
__future__r   r   r   r-   logging.configr9   urllib.parser   r3   Z
zeep.cacher   Zzeep.clientr   Zzeep.settingsr   Zzeep.transportsr   	getLoggerr:   r   rB   __name__r   r   r   r   r   <module>   s    

4