a oeC@sddlZddlZddlZddlmZddlmZmZddl m Z ddl m Z Gddde Z Gdd d e ZGd d d e ZGd d d e ZGddde ZGdddZGdddeZGdddeZGdddZGdddeZGdddeZGdddZGdddZGd d!d!ZGd"d#d#ZGd$d%d%ZGd&d'd'ZGd(d)d)ZGd*d+d+ZGd,d-d-Z Gd.d/d/Z!Gd0d1d1Z"dS)2N)axdebug) RaiseNotImpl_wrap) Exception)ListEnumeratorGatewayc@seZdZdZejgZdS)EnumDebugCodeContextsaA class to expose a Python sequence as an EnumDebugCodeContexts Create an instance of this class passing a sequence (list, tuple, or any sequence protocol supporting object) and it will automatically support the EnumDebugCodeContexts interface for the object. N)__name__ __module__ __qualname____doc__rZIID_IEnumDebugCodeContexts_com_interfaces_r r =C:\Program Files\Certbot\pkgs\win32comext\axdebug\gateways.pyr src@seZdZdZejgZdS)EnumDebugStackFramesaA class to expose a Python sequence as an EnumDebugStackFrames Create an instance of this class passing a sequence (list, tuple, or any sequence protocol supporting object) and it will automatically support the EnumDebugStackFrames interface for the object. N)rr r r rZIID_IEnumDebugStackFramesr r r r rrsrc@seZdZdZejgZdS)EnumDebugApplicationNodesaA class to expose a Python sequence as an EnumDebugStackFrames Create an instance of this class passing a sequence (list, tuple, or any sequence protocol supporting object) and it will automatically support the EnumDebugApplicationNodes interface for the object. N)rr r r rZIID_IEnumDebugApplicationNodesr r r r rr$src@seZdZejgZdS)EnumRemoteDebugApplicationsN)rr r rZ IID_IEnumRemoteDebugApplicationsr r r r rr0src@seZdZejgZdS)!EnumRemoteDebugApplicationThreadsN)rr r rZ&IID_IEnumRemoteDebugApplicationThreadsr r r r rr4src@s4eZdZddgZejgZddZddZddZ d S) DebugDocumentInfoGetNameGetDocumentClassIdcCsdSNr selfr r r__init__<szDebugDocumentInfo.__init__cCs tddS)zTGet the one of the name of the document dnt -- int DOCUMENTNAMETYPE rNr)rZdntr r rr?szDebugDocumentInfo.GetNamecCs tddS)zL Result must be an IID object (or string representing one). rNrrr r rrEsz$DebugDocumentInfo.GetDocumentClassIdN) rr r _public_methods_rZIID_IDebugDocumentInfor rrrr r r rr8s rc@s.eZdZejdgZejejgZddZdS)DebugDocumentProvider GetDocumentcCs tddS)Nrrrr r rrRsz!DebugDocumentProvider.GetDocumentN) rr r rrr rIID_IDebugDocumentProviderrr r r rrLs  rc@sdeZdZdZdejZejgej Z ddZ ddZ ddZ d d Z d d Zd dZddZdS)DebugApplicationNodez[Provides the functionality of IDebugDocumentProvider, plus a context within a project tree.zREnumChildren GetParent SetDocumentProvider Close Attach DetachcCst|dSr)rrrr r rrbszDebugApplicationNode.__init__cCs tddS)N EnumChildrenrrr r rr esz!DebugApplicationNode.EnumChildrencCs tddS)N GetParentrrr r rr!iszDebugApplicationNode.GetParentcCs tddS)NSetDocumentProviderr)rZpddpr r rr"msz(DebugApplicationNode.SetDocumentProvidercCs tddS)NCloserrr r rr#qszDebugApplicationNode.ClosecCs tddS)NAttachrrparentr r rr$uszDebugApplicationNode.AttachcCs tddS)NDetachrrr r rr'yszDebugApplicationNode.DetachN)rr r r splitrrrrr rr r!r"r#r$r'r r r rrVs rc@sHeZdZdZdZejgZddZ ddZ ddZ d d Z d d Z d S)DebugApplicationNodeEventsz0Event interface for DebugApplicationNode object.z!onAddChild onRemoveChild onDetachcCsdSrr rr r rrsz#DebugApplicationNodeEvents.__init__cCs tddS)N onAddChildrrchildr r rr*sz%DebugApplicationNodeEvents.onAddChildcCs tddS)N onRemoveChildrr+r r rr-sz(DebugApplicationNodeEvents.onRemoveChildcCs tddS)NonDetachrrr r rr.sz#DebugApplicationNodeEvents.onDetachcCs tddS)NonAttachrr%r r rr/sz#DebugApplicationNodeEvents.onAttachN)rr r r r(rrZIID_IDebugApplicationNodeEventsr rr*r-r.r/r r r rr)~sr)c@s$eZdZdZejZejgejZdS) DebugDocumentz*The base interface to all debug documents.N) rr r r rrrZIID_IDebugDocumentr r r r rr0sr0c@sleZdZdZejgejZgdejZddZ ddZ ddZ d d Z d d Z d dZddZddZdS)DebugDocumentTextz,The interface to a text only debug document.)GetDocumentAttributesGetSizeGetPositionOfLineGetLineOfPositionGetTextGetPositionOfContextGetContextOfPositioncCsdSrr rr r rrszDebugDocumentText.__init__cCs tddS)Nr2rrr r rr2sz'DebugDocumentText.GetDocumentAttributescCs tddS)Nr3rrr r rr3szDebugDocumentText.GetSizecCs tddS)Nr4r)rZ cLineNumberr r rr4sz#DebugDocumentText.GetPositionOfLinecCs tddS)Nr5r)rcharPosr r rr5sz#DebugDocumentText.GetLineOfPositioncCs tddS)zParams charPos -- integer maxChars -- integer wantAttr -- Should the function compute attributes. Return value must be (string, attribtues). attributes may be None if(not wantAttr) r6Nr)rr9maxCharsZwantAttrr r rr6s zDebugDocumentText.GetTextcCs tddS)zParams debugDocumentContext -- a PyIDebugDocumentContext object. Return value must be (charPos, numChars) r7Nr)rZdebugDocumentContextr r rr7sz&DebugDocumentText.GetPositionOfContextcCst|tddS)zYParams are integers. Return value must be PyIDebugDocumentContext object r8N)printr)rr9r:r r rr8sz&DebugDocumentText.GetContextOfPositionN)rr r r rZIID_IDebugDocumentTextr0r rrr2r3r4r5r6r7r8r r r rr1s  r1c@s@eZdZdZgdZejgZddZddZ ddZ d d Z d S) DebugDocumentTextExternalAuthorzAllow external editors to edit file-based debugger documents, and to notify the document when the source file has been changed.) GetPathName GetFileName NotifyChangedcCsdSrr rr r rrsz(DebugDocumentTextExternalAuthor.__init__cCs tddS)aReturn the full path (including file name) to the document's source file. Result must be (filename, fIsOriginal), where - if fIsOriginalPath is TRUE if the path refers to the original file for the document. - if fIsOriginalPath is FALSE if the path refers to a newly created temporary file. raise Exception(winerror.E_FAIL) if no source file can be created/determined. r=Nrrr r rr=s z+DebugDocumentTextExternalAuthor.GetPathNamecCs tddS)z}Return just the name of the document, with no path information. (Used for "Save As...") Result is a string r>Nrrr r rr>sz+DebugDocumentTextExternalAuthor.GetFileNamecCs tddS)zzNotify the host that the document's source file has been saved and that its contents should be refreshed. r?Nrrr r rr?sz-DebugDocumentTextExternalAuthor.NotifyChangedN) rr r r rrZ$IID_IDebugDocumentTextExternalAuthorr rr=r>r?r r r rr<s r<c@sTeZdZdZejgZddZddZ ddZ dd Z d d Z d d Z ddZdS)DebugDocumentTextEventszonDestroy onInsertText onRemoveText onReplaceText onUpdateTextAttributes onUpdateDocumentAttributescCsdSrr rr r rrsz DebugDocumentTextEvents.__init__cCs tddS)N onDestroyrrr r rrAsz!DebugDocumentTextEvents.onDestroycCs tddS)N onInsertTextr)rcCharacterPositionZ cNumToInsertr r rrB sz$DebugDocumentTextEvents.onInsertTextcCs tddS)N onRemoveTextr)rrCZ cNumToRemover r rrDsz$DebugDocumentTextEvents.onRemoveTextcCs tddS)N onReplaceTextr)rrCZ cNumToReplacer r rrEsz%DebugDocumentTextEvents.onReplaceTextcCs tddS)NonUpdateTextAttributesr)rrCZ cNumToUpdater r rrFsz.DebugDocumentTextEvents.onUpdateTextAttributescCs tddS)NonUpdateDocumentAttributesr)rZ textdocattrr r rrGsz2DebugDocumentTextEvents.onUpdateDocumentAttributesN)rr r r(rrIID_IDebugDocumentTextEventsr rrArBrDrErFrGr r r rr@sr@c@s4eZdZddgZejgZddZddZddZ d S) DebugDocumentContextrEnumCodeContextscCsdSrr rr r rr$szDebugDocumentContext.__init__cCs tddS)z.Return value must be a PyIDebugDocument objectrNrrr r rr'sz DebugDocumentContext.GetDocumentcCs tddS)z6Return value must be a PyIEnumDebugCodeContexts objectrJNrrr r rrJ+sz%DebugDocumentContext.EnumCodeContextsN) rr r rrZIID_IDebugDocumentContextr rrrJr r r rrI s rIc@s4eZdZddgZejgZddZddZddZ d S) DebugCodeContextGetDocumentContext SetBreakPointcCsdSrr rr r rr4szDebugCodeContext.__init__cCs tddS)z5Return value must be a PyIDebugDocumentContext objectrLNrrr r rrL7sz#DebugCodeContext.GetDocumentContextcCs tddS)zbps -- an integer with flags.rMNr)rZbpsr r rrM;szDebugCodeContext.SetBreakPointN) rr r rrZIID_IDebugCodeContextr rrLrMr r r rrK0s rKc@sPeZdZdZgdZejgZddZddZ ddZ d d Z d d Z d dZ dS)DebugStackFramezHAbstraction representing a logical stack frame on the stack of a thread.)GetCodeContextGetDescriptionStringGetLanguageString GetThreadGetDebugPropertycCsdSrr rr r rrLszDebugStackFrame.__init__cCs tddS)zReturns the current code context associated with the stack frame. Return value must be a IDebugCodeContext object rONrrr r rrOOszDebugStackFrame.GetCodeContextcCs tddS)z}Returns a textual description of the stack frame. fLong -- A flag indicating if the long name is requested. rPNr)rZfLongr r rrPVsz$DebugStackFrame.GetDescriptionStringcCs tddS)zReturns a short or long textual description of the language. fLong -- A flag indicating if the long name is requested. rQNrrr r rrQ]sz!DebugStackFrame.GetLanguageStringcCs tddS)zoReturns the thread associated with this stack frame. Result must be a IDebugApplicationThread rRNrrr r rrRdszDebugStackFrame.GetThreadcCs tddS)NrSrrr r rrSksz DebugStackFrame.GetDebugPropertyN)rr r r rrZIID_IDebugStackFramer rrOrPrQrRrSr r r rrN@srNc@sXeZdZdZgdZejgZddZddZ ddZ d d Z d d Z d dZ ddZdS)DebugDocumentHostzThe interface from the IDebugDocumentHelper back to the smart host or language engine. This interface exposes host specific functionality such as syntax coloring. )GetDeferredTextGetScriptTextAttributesOnCreateDocumentContextr=r>r?cCsdSrr rr r rrszDebugDocumentHost.__init__cCs tddS)NrUr)rZdwTextStartCookier:Z bWantAttrr r rrUsz!DebugDocumentHost.GetDeferredTextcCs tddS)NrVr)rZcodeTextZ delimterTextflagsr r rrVsz)DebugDocumentHost.GetScriptTextAttributescCs tddS)NrWrrr r rrWsz)DebugDocumentHost.OnCreateDocumentContextcCs tddS)Nr=rrr r rr=szDebugDocumentHost.GetPathNamecCs tddS)Nr>rrr r rr>szDebugDocumentHost.GetFileNamecCs tddS)Nr?rrr r rr?szDebugDocumentHost.NotifyChangedN)rr r r rrZIID_IDebugDocumentHostr rrUrVrWr=r>r?r r r rrTosrTc@sleZdZejjjejjjZe j e j gZ ddZ ddZddZddZd d Zd d Zd dZddZdS)DebugDocumentTextConnectServercCsd|_i|_dS)N)cookieNo connectionsrr r rrsz'DebugDocumentTextConnectServer.__init__cCs tddS)NEnumConnectionsrrr r rr]sz.DebugDocumentTextConnectServer.EnumConnectionscCs tddS)NGetConnectionInterfacerrr r rr^sz5DebugDocumentTextConnectServer.GetConnectionInterfacecCst|Sr)rrr r rGetConnectionPointContainersz:DebugDocumentTextConnectServer.GetConnectionPointContainercCs,|tjd}|jd|_||j|j<|jS)N)ZQueryInterfacerrHr[r\)rZpUnkZ interfacer r rAdvises  z%DebugDocumentTextConnectServer.AdvisecCs0z |j|=Wnty*ttjdYS0dSN)Zscode)r\KeyErrorrwinerrorZ E_UNEXPECTED)rcookier r rUnadvises  z'DebugDocumentTextConnectServer.UnadvisecCs tddS)NEnumConnectionPointsrrr r rrgsz3DebugDocumentTextConnectServer.EnumConnectionPointscCs"|tjkrt|SttjddSrb)rrHrrrdZ E_NOINTERFACE)rZiidr r rFindConnectionPoints z2DebugDocumentTextConnectServer.FindConnectionPointN)rr r win32comZserverZconnectZ!IConnectionPointContainer_methodsZIConnectionPoint_methodsr pythoncomZIID_IConnectionPointZIID_IConnectionPointContainerr rr]r^r_rarfrgrhr r r rrYsrYc@sleZdZgdZejgZddZddZddZ dd Z d d Z d d Z ddZ ddZddZddZdS)RemoteDebugApplicationEvents) OnConnectDebuggerOnDisconnectDebugger OnSetName OnDebugOutputOnCloseOnEnterBreakPointOnLeaveBreakPointOnCreateThreadOnDestroyThreadOnBreakFlagChangecCs tddS)z'appDebugger -- a PyIApplicationDebuggerrlNr)rZ appDebuggerr r rrlsz.RemoteDebugApplicationEvents.OnConnectDebuggercCs tddS)Nrmrrr r rrmsz1RemoteDebugApplicationEvents.OnDisconnectDebuggercCs tddS)Nrnr)rnamer r rrnsz&RemoteDebugApplicationEvents.OnSetNamecCs tddS)Nror)rstringr r rrosz*RemoteDebugApplicationEvents.OnDebugOutputcCs tddS)Nrprrr r rrpsz$RemoteDebugApplicationEvents.OnClosecCs tddS)'rdat -- PyIRemoteDebugApplicationThreadrqNrrrdatr r rrqsz.RemoteDebugApplicationEvents.OnEnterBreakPointcCs tddS)rxrrNrryr r rrrsz.RemoteDebugApplicationEvents.OnLeaveBreakPointcCs tddS)rxrsNrryr r rrssz+RemoteDebugApplicationEvents.OnCreateThreadcCs tddS)rxrtNrryr r rrtsz,RemoteDebugApplicationEvents.OnDestroyThreadcCsdS)zabf -- int - one of the axdebug.APPBREAKFLAGS constants rdat -- PyIRemoteDebugApplicationThread RaiseNotImpl("OnBreakFlagChange") Nr )rZabfrzr r rrusz.RemoteDebugApplicationEvents.OnBreakFlagChangeN)rr r rrZ!IID_IRemoteDebugApplicationEventsr rlrmrnrorprqrrrsrtrur r r rrks rkc@s4eZdZddgZejgZddZddZddZ d S) DebugExpressionContextParseLanguageTextGetLanguageInfocCsdSrr rr r rr szDebugExpressionContext.__init__cCs tddS)z, result is IDebugExpression r|Nr)rcoderadixdelimrXr r rr|sz(DebugExpressionContext.ParseLanguageTextcCs tddS)z9 result is (string langName, iid langId) r}Nrrr r rr}sz&DebugExpressionContext.GetLanguageInfoN) rr r rrZIID_IDebugExpressionContextr rr|r}r r r rr{s r{c@sDeZdZgdZejgZddZddZddZ dd Z d d Z d S) DebugExpression)StartAbortQueryIsCompleteGetResultAsStringGetResultAsDebugPropertycCs tddS)zP callback -- an IDebugExpressionCallback result - void rNr)rcallbackr r rr%szDebugExpression.StartcCs tddS)2 no params result -- void rNrrr r rr-szDebugExpression.AbortcCs tddS)rrNrrr r rr4szDebugExpression.QueryIsCompletecCs tddS)Nrrrr r rr;sz!DebugExpression.GetResultAsStringcCs tddS)Nrrrr r rr>sz(DebugExpression.GetResultAsDebugPropertyN) rr r rrZIID_IDebugExpressionr rrrrrr r r rrsrc@s"eZdZdgZejgZddZdS)ProvideExpressionContextsEnumExpressionContextscCs tddS)Nrrrr r rrFsz0ProvideExpressionContexts.EnumExpressionContextsN)rr r rrZIID_IProvideExpressionContextsr rr r r rrBsr)#rjZwin32com.server.connectrirdZwin32com.axdebugrZwin32com.axdebug.utilrrZwin32com.server.exceptionrZwin32com.server.utilrrrrrrrrrr)r0r1r<r@rIrKrNrTrYrkr{rrr r r rs8       (=""/026'