U
    H4f^                     @   s:   d dl Z d dlmZ d dlZejddG dd dZdS )    N)contextmanagerT)slotsc                       s   e Zd ZdZejddZejddZejddZejddZ	ejddZ
ejddZejddZejddZejddZejeejdZedd Z fdd	Z  ZS )
Settingsa<  

    :param strict: boolean to indicate if the lxml should be parsed a 'strict'.
      If false then the recover mode is enabled which tries to parse invalid
      XML as best as it can.
    :type strict: boolean
    :param raw_response: boolean to skip the parsing of the XML response by
     zeep but instead returning the raw data

    :param forbid_dtd: disallow XML with a <!DOCTYPE> processing instruction
    :type forbid_dtd: bool
    :param forbid_entities: disallow XML with <!ENTITY> declarations inside the DTD
    :type forbid_entities: bool
    :param forbid_external: disallow any access to remote or local resources
      in external entities or DTD and raising an ExternalReferenceForbidden
      exception when a DTD or entity references an external resource.
    :type forbid_external: bool
    :param xml_huge_tree: disable lxml/libxml2 security restrictions and
                          support very deep trees and very long text content

    :param force_https: Force all connections to HTTPS if the WSDL is also
      loaded from an HTTPS endpoint. (default: true)
    :type force_https: bool
    :param extra_http_headers: Additional HTTP headers to be sent to the
     transport. This can be used in combination with the context manager
     approach to add http headers for specific calls.
    :type extra_headers: list

    :param xsd_ignore_sequence_order: boolean to indicate whether to enforce sequence
     order when parsing complex types. This is a workaround for servers that
     don't respect sequence order.
    :type xsd_ignore_sequence_order: boolean
    T)defaultFNc                 k   s   i }|  D ]$\}}t| |||< t| j|| qz
d V  W 5 |  D ]6\}}t| |}||krnt| j| qFt| j|| qFX d S )N)itemsgetattrsetattr_tlsdelattr)selfoptionscurrentkeyvaluer    r   1/tmp/pip-unpacked-wheel-04z2hmy8/zeep/settings.py__call__=   s    

zSettings.__call__c                    s,   |dkr t | j|r t| j|S t |S )Nr	   )hasattrr	   r   super__getattribute__)r   r   	__class__r   r   r   N   s    zSettings.__getattribute__)__name__
__module____qualname____doc__attribstrictZraw_responseZforce_httpsZextra_http_headersZxml_huge_treeZ
forbid_dtdZforbid_entitiesZforbid_externalZxsd_ignore_sequence_orderZFactory	threadinglocalr	   r   r   r   __classcell__r   r   r   r   r      s   "
r   )r   
contextlibr   r   sr   r   r   r   r   <module>   s   
