File: //proc/self/root/lib/python3/dist-packages/twisted/internet/__pycache__/endpoints.cpython-38.pyc
U
J0�[�- � @ sx d Z ddlmZmZ ddlZddlZddlZddlmZ ddl Z ddl
mZmZ ddl
mZ ddlmZmZmZ ddlmZmZmZmZmZ dd lmZmZ dd
lmZmZmZm Z ddl!m"Z"m#Z#m$Z$m%Z%m&Z& ddl'm(Z(m)Z) dd
l'm*Z*m+Z+ ddl,m-Z-m.Z. ddl/m0Z0 ddl1m2Z2 ddl3m4Z4 ddl5m6Z6m7Z7 ddl8m9Z9m:Z: ddl;m<Z<m=Z=m>Z> ddl?m@Z@ ddlAmBZB ddlCmDZD ddl;mEZE ddlFmGZG ddlHmIZI ddlJmKZKmLZL z<ddlMmNZN ddlOmPZPmQZQmRZRmSZSmTZTmUZU ddlVmWZX W n eYk
�r dZNY nX d d!d"d#d$d%d&d'd(d)d*d+d,d-d.d/d0gZZG d1d2� d2e+�Z[G d3d4� d4e(�Z\eej]�G d5d+� d+e^��Z_G d6d7� d7ej`ejaejb�ZcG d8d9� d9e@ecd:��ZdG d;d<� d<e*�ZeG d=d.� d.e�Zfeejg�G d>d,� d,e^��Zheej]�G d?d@� d@e^��ZiG dAd"� d"ei�ZjG dBd#� d#ei�Zkeejg�G dCd$� d$e^��Zleejg�G dDd%� d%e^��Zmee&�G dEdF� dFe^��Zneejg�G dGd-� d-e^��Zoeej]�G dHd(� d(e^��Zpeejg�G dId)� d)e^��Zqeej]�G dJd&� d&e^��Zreejg�G dKd'� d'e^��Zseej]�G dLd*� d*e^��Ztd�dOdP�Zud�dSdT�Zvd�dVdW�Zwee6e"�G dXdY� dYe^��Zxee6e"�G dZd[� d[e^��Zyee6e"�G d\d]� d]e^��Zzeuevewd^�Z{e|d_�\Z}Z~d`da� Zdbdc� Z�ejeperdd�Z�eleqesdd�Z�dedf� Z�dgdh� Z�did!� Z�djdk� Z�dldm� Z�dndo� Z�dpdq� Z�drds� Z�dtdu� Z�dvdw� Z�dxdy� Z�e�e�e�dd�Z�dzd � Z�d{d/� Z�eejg�G d|d}� d}e^��Z�eej]�G d~d� de^��Z�d�d0� Z�d�d�d��Z�ee6e#�G d�d�� d�e^��Z�dS )�a7
Implementations of L{IStreamServerEndpoint} and L{IStreamClientEndpoint} that
wrap the L{IReactorTCP}, L{IReactorSSL}, and L{IReactorUNIX} interfaces.
This also implements an extensible mini-language for describing endpoints,
parsed by the L{clientFromString} and L{serverFromString} functions.
@since: 10.1
� )�division�absolute_importN)� normalize)�
NamedConstant�Names)�Version)�implementer�directlyProvides�provider)�
interfaces�defer�error�fdesc�threads)�
isIPv6Address�isIPAddress)�_ProcessAddress�HostnameAddress�IPv4Address�IPv6Address)�!IStreamServerEndpointStringParser�,IStreamClientEndpointStringParserWithReactor�IResolutionReceiver�IReactorPluggableNameResolver�IHostnameResolver)�
ClientFactory�Factory)�ProcessProtocol�Protocol)�
StandardIO�PipeAddress)�LoopingCall)�HostResolution)�Logger)�IPlugin�
getPlugins)� deprecate�log)�nativeString�unicode�_matchingString)�proxyForInterface)�Failure)�FilePath)� iterbytes)�Deferred)� ListenFDs� )�
_idnaBytes� _idnaText��TLSMemoryBIOFactory)�optionsForClientTLS�PrivateCertificate�Certificate�KeyPair�CertificateOptions�trustRootFromCertificates)�Error�clientFromString�serverFromString�TCP4ServerEndpoint�TCP6ServerEndpoint�TCP4ClientEndpoint�TCP6ClientEndpoint�UNIXServerEndpoint�UNIXClientEndpoint�SSL4ServerEndpoint�SSL4ClientEndpoint�AdoptedStreamServerEndpoint�StandardIOEndpoint�ProcessEndpoint�HostnameEndpoint�StandardErrorBehavior�connectProtocol�
wrapClientTLSc @ sX e Zd ZdZdd� Zdd� Zdd� Zdd � Zd
d� Zdd
� Z dd� Z
dd� Zdd� ZdS )�_WrappingProtocolz_
Wrap another protocol in order to notify my user when a connection has
been made.
c C s<