a „oeÜ ã@sVdZddlZddlZddlZddlmZddlmZddgZgd¢Z Gd d „d ƒZ dS) zeUtilities for Server Side connections. A collection of helpers for server side connection points. éN)Úolectlé)Ú ExceptionÚEnumConnectionPointsÚFindConnectionPoint)ÚEnumConnectionsÚUnadviseÚAdviseÚGetConnectionPointContainerÚGetConnectionInterfacec@speZdZeeZejejgZ dd„Z dd„Z dd„Z dd„Z d d „Zd d „Zd d„Zdd„Zdd„Zdd„ZdS)ÚConnectableServercCsd|_i|_dS)Nr)ÚcookieNoÚ connections©Úself©rú8C:\Program Files\Certbot\pkgs\win32com\server\connect.pyÚ__init__szConnectableServer.__init__cCsttjƒ‚dS©N©rÚwinerrorZ E_NOTIMPLrrrrr$sz!ConnectableServer.EnumConnectionscCsttjƒ‚dSrrrrrrr 'sz(ConnectableServer.GetConnectionInterfacecCstjj |¡Sr)Úwin32comÚserverÚutilÚwraprrrrr *sz-ConnectableServer.GetConnectionPointContainercCsXz| |jdtj¡}Wn tjy8ttjd�‚Yn0|jd|_||j |j<|jS)Nr©Zscoder) ZQueryInterfaceÚ_connect_interfaces_Ú pythoncomZ IID_IDispatchÚ com_errorrrZCONNECT_E_NOCONNECTIONr r)rZpUnkÚ interfacerrrr -s ÿ  zConnectableServer.AdvisecCs0z |j|=Wnty*ttjd�‚Yn0dS)Nr)rÚKeyErrorrrZ E_UNEXPECTED)rÚcookierrrr:s  zConnectableServer.UnadvisecCsttjƒ‚dSrrrrrrrBsz&ConnectableServer.EnumConnectionPointscCs||jvrtjj |¡SdSr)rrrrr)rZiidrrrrEs z%ConnectableServer.FindConnectionPointc CsZ|j ¡D]J}z||f|ŽWq tjyR}z| ||¡WYd}~q d}~00q dSr)rÚvaluesrrÚ _OnNotifyFail)rZ broadcasterZ extraArgsrÚdetailsrrrÚ_BroadcastNotifyJs z"ConnectableServer._BroadcastNotifycCstdt|ƒƒdS)Nz%Ignoring COM error to connection - %s)ÚprintÚrepr)rrr$rrrr#SszConnectableServer._OnNotifyFailN)Ú__name__Ú __module__Ú __qualname__Ú!IConnectionPointContainer_methodsÚIConnectionPoint_methodsZ_public_methods_rZIID_IConnectionPointZIID_IConnectionPointContainerZ_com_interfaces_rrr r r rrrr%r#rrrrr sþ  r ) Ú__doc__rZwin32com.server.utilrrrÚ exceptionrr+r,r rrrrÚs