
    
hF                        S SK r S SKrS SKrS SKJr  S SKJrJr  S SK	J
r
  S SKJr   " S S\5      r " S S	\5      r " S
 S\5      r " S S\5      r " S S\5      r " S S5      r " S S\5      r " S S\5      r " S S5      r " S S\5      r " S S\5      r " S S5      r " S S5      r " S  S!5      r " S" S#5      r " S$ S%5      r " S& S'5      r " S( S)5      r " S* S+5      r " S, S-5      r  " S. S/5      r! " S0 S15      r"g)2    N)axdebug)RaiseNotImpl_wrap)COMException)ListEnumeratorGatewayc                   2    \ rS rSrSr\R                  /rSrg)EnumDebugCodeContexts   a  A 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____firstlineno____doc__r   IID_IEnumDebugCodeContexts_com_interfaces___static_attributes__r       oC:\Users\julio\OneDrive\Documentos\Trabajo\Ideas Frescas\venv\Lib\site-packages\win32comext/axdebug/gateways.pyr	   r	      s      ::;r   r	   c                   2    \ rS rSrSr\R                  /rSrg)EnumDebugStackFrames   a  A 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.

r   N)	r   r   r   r   r   r   IID_IEnumDebugStackFramesr   r   r   r   r   r   r      s      99:r   r   c                   2    \ rS rSrSr\R                  /rSrg)EnumDebugApplicationNodes$   a	  A 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.

r   N)	r   r   r   r   r   r   IID_IEnumDebugApplicationNodesr   r   r   r   r   r   r   $   s      >>?r   r   c                   .    \ rS rSr\R
                  /rSrg)EnumRemoteDebugApplications0   r   N)r   r   r   r   r    IID_IEnumRemoteDebugApplicationsr   r   r   r   r   r   r   0   s    @@Ar   r   c                   .    \ rS rSr\R
                  /rSrg)!EnumRemoteDebugApplicationThreads4   r   N)r   r   r   r   r   &IID_IEnumRemoteDebugApplicationThreadsr   r   r   r   r   r#   r#   4   s    FFGr   r#   c                   H    \ rS rSrSS/r\R                  /rS rS r	S r
Srg)	DebugDocumentInfo8   GetNameGetDocumentClassIdc                     g Nr   selfs    r   __init__DebugDocumentInfo.__init__<       r   c                     [        S5        g)zDGet the one of the name of the document
dnt -- int DOCUMENTNAMETYPE
r)   Nr   )r.   dnts     r   r)   DebugDocumentInfo.GetName?   s     	Yr   c                     [        S5        g)z<
Result must be an IID object (or string representing one).
r*   Nr3   r-   s    r   r*   $DebugDocumentInfo.GetDocumentClassIdE   s     	)*r   r   N)r   r   r   r   _public_methods_r   IID_IDebugDocumentInfor   r/   r)   r*   r   r   r   r   r'   r'   8   s,    !#78667 +r   r'   c                   n    \ rS rSr\R
                  S/-   r\R                  \R                  /-   rS r	Sr
g)DebugDocumentProviderL   GetDocumentc                     [        S5        g )Nr=   r3   r-   s    r   r=   !DebugDocumentProvider.GetDocumentR   s
    ]#r   r   N)r   r   r   r   r'   r8   r   r   IID_IDebugDocumentProviderr=   r   r   r   r   r;   r;   L   s9    (99]OK(99**= $r   r;   c                       \ rS rSrSrSR                  5       \R                  -   r\R                  /\R                  -   r
S rS rS rS rS rS	 rS
 rSrg)DebugApplicationNodeV   z[Provides the functionality of IDebugDocumentProvider, plus a context within a project tree.zREnumChildren GetParent SetDocumentProvider
                    Close Attach Detachc                 .    [         R                  U 5        g r,   )r;   r/   r-   s    r   r/   DebugApplicationNode.__init__b   s    &&t,r   c                     [        S5        g )NEnumChildrenr3   r-   s    r   rG   !DebugApplicationNode.EnumChildrene   
    ^$r   c                     [        S5        g )N	GetParentr3   r-   s    r   rK   DebugApplicationNode.GetParenti   
    [!r   c                     [        S5        g )NSetDocumentProviderr3   )r.   pddps     r   rO   (DebugApplicationNode.SetDocumentProviderm   s    *+r   c                     [        S5        g )NCloser3   r-   s    r   rS   DebugApplicationNode.Closeq   s
    Wr   c                     [        S5        g )NAttachr3   r.   parents     r   rV   DebugApplicationNode.Attachu   
    Xr   c                     [        S5        g )NDetachr3   r-   s    r   r\   DebugApplicationNode.Detachy   rZ   r   r   N)r   r   r   r   r   splitr;   r8   r   r@   r   r/   rG   rK   rO   rS   rV   r\   r   r   r   r   rB   rB   V   sh    e	++057

0
0	1  	**../-%",r   rB   c                   p    \ rS rSrSrSR                  5       r\R                  /r	S r
S rS rS rS rS	rg
)DebugApplicationNodeEvents~   z0Event interface for DebugApplicationNode object.z!onAddChild onRemoveChild onDetachc                     g r,   r   r-   s    r   r/   #DebugApplicationNodeEvents.__init__   r1   r   c                     [        S5        g )N
onAddChildr3   r.   childs     r   re   %DebugApplicationNodeEvents.onAddChild   s
    \"r   c                     [        S5        g )NonRemoveChildr3   rf   s     r   rj   (DebugApplicationNodeEvents.onRemoveChild   
    _%r   c                     [        S5        g )NonDetachr3   r-   s    r   rn   #DebugApplicationNodeEvents.onDetach   
    Z r   c                     [        S5        g )NonAttachr3   rW   s     r   rr   #DebugApplicationNodeEvents.onAttach   rp   r   r   N)r   r   r   r   r   r^   r8   r   IID_IDebugApplicationNodeEventsr   r/   re   rj   rn   rr   r   r   r   r   r`   r`   ~   s<    ::@@B??@#&!!r   r`   c                   d    \ rS rSrSr\R                  r\R                  /\R                  -   r	Sr
g)DebugDocument   z*The base interface to all debug documents.r   N)r   r   r   r   r   r'   r8   r   IID_IDebugDocumentr   r   r   r   r   rv   rv      s,    4(992236G6X6XXr   rv   c                       \ rS rSrSr\R                  /\R                  -   r/ SQ\R                  -   r	S r
S rS rS rS rS	 rS
 rS rSrg)DebugDocumentText   z,The interface to a text only debug document.)GetDocumentAttributesGetSizeGetPositionOfLineGetLineOfPositionGetTextGetPositionOfContextGetContextOfPositionc                     g r,   r   r-   s    r   r/   DebugDocumentText.__init__   r1   r   c                     [        S5        g )Nr|   r3   r-   s    r   r|   'DebugDocumentText.GetDocumentAttributes   s    ,-r   c                     [        S5        g )Nr}   r3   r-   s    r   r}   DebugDocumentText.GetSize   s
    Yr   c                     [        S5        g )Nr~   r3   )r.   cLineNumbers     r   r~   #DebugDocumentText.GetPositionOfLine       ()r   c                     [        S5        g )Nr   r3   )r.   charPoss     r   r   #DebugDocumentText.GetLineOfPosition   r   r   c                     [        S5        g)zParams
charPos -- integer
maxChars -- integer
wantAttr -- Should the function compute attributes.

Return value must be (string, attribtues).  attributes may be
None if(not wantAttr)
r   Nr3   )r.   r   maxCharswantAttrs       r   r   DebugDocumentText.GetText   s     	Yr   c                     [        S5        g)zkParams
debugDocumentContext -- a PyIDebugDocumentContext object.

Return value must be (charPos, numChars)
r   Nr3   )r.   debugDocumentContexts     r   r   &DebugDocumentText.GetPositionOfContext   s     	+,r   c                 0    [        U 5        [        S5        g)zIParams are integers.
Return value must be PyIDebugDocumentContext object
r   N)printr   )r.   r   r   s      r   r   &DebugDocumentText.GetContextOfPosition   s     	d+,r   r   N)r   r   r   r   r   r   IID_IDebugDocumentTextrv   r   r8   r/   r|   r}   r~   r   r   r   r   r   r   r   r   rz   rz      s_    6667-:X:XX 	&&'. **	 --r   rz   c                   R    \ rS rSrSr/ SQr\R                  /rS r	S r
S rS rSrg	)
DebugDocumentTextExternalAuthor   zAllow external editors to edit file-based debugger documents, and to notify the document when the source file has been changed.)GetPathNameGetFileNameNotifyChangedc                     g r,   r   r-   s    r   r/   (DebugDocumentTextExternalAuthor.__init__   r1   r   c                     [        S5        g)av  Return 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 COMException(winerror.E_FAIL) if no source file can be created/determined.
r   Nr3   r-   s    r   r   +DebugDocumentTextExternalAuthor.GetPathName   s     	]#r   c                     [        S5        g)zmReturn just the name of the document, with no path information.  (Used for "Save As...")

Result is a string
r   Nr3   r-   s    r   r   +DebugDocumentTextExternalAuthor.GetFileName       
 	]#r   c                     [        S5        g)zjNotify the host that the document's source file has been saved and
that its contents should be refreshed.
r   Nr3   r-   s    r   r   -DebugDocumentTextExternalAuthor.NotifyChanged   s     	_%r   r   N)r   r   r   r   r   r8   r   $IID_IDebugDocumentTextExternalAuthorr   r/   r   r   r   r   r   r   r   r   r      s1     JFDDE	$$&r   r   c                   x    \ rS rSrSR	                  5       r\R                  /rS r	S r
S rS rS rS rS	 rS
rg)DebugDocumentTextEvents   zonDestroy onInsertText onRemoveText
              onReplaceText onUpdateTextAttributes
              onUpdateDocumentAttributesc                     g r,   r   r-   s    r   r/    DebugDocumentTextEvents.__init__  r1   r   c                     [        S5        g )N	onDestroyr3   r-   s    r   r   !DebugDocumentTextEvents.onDestroy  rM   r   c                     [        S5        g )NonInsertTextr3   )r.   cCharacterPositioncNumToInserts      r   r   $DebugDocumentTextEvents.onInsertText  rI   r   c                     [        S5        g )NonRemoveTextr3   )r.   r   cNumToRemoves      r   r   $DebugDocumentTextEvents.onRemoveText  rI   r   c                     [        S5        g )NonReplaceTextr3   )r.   r   cNumToReplaces      r   r   %DebugDocumentTextEvents.onReplaceText  rl   r   c                     [        S5        g )NonUpdateTextAttributesr3   )r.   r   cNumToUpdates      r   r   .DebugDocumentTextEvents.onUpdateTextAttributes  s    -.r   c                     [        S5        g )NonUpdateDocumentAttributesr3   )r.   textdocattrs     r   r   2DebugDocumentTextEvents.onUpdateDocumentAttributes  s    12r   r   N)r   r   r   r   r^   r8   r   IID_IDebugDocumentTextEventsr   r/   r   r   r   r   r   r   r   r   r   r   r   r      sG    ,,1EG   <<="%%&/3r   r   c                   H    \ rS rSrSS/r\R                  /rS rS r	S r
Srg)	DebugDocumentContexti   r=   EnumCodeContextsc                     g r,   r   r-   s    r   r/   DebugDocumentContext.__init__$  r1   r   c                     [        S5        g)z.Return value must be a PyIDebugDocument objectr=   Nr3   r-   s    r   r=    DebugDocumentContext.GetDocument'  
    ]#r   c                     [        S5        g)z6Return value must be a PyIEnumDebugCodeContexts objectr   Nr3   r-   s    r   r   %DebugDocumentContext.EnumCodeContexts+  s    '(r   r   N)r   r   r   r   r8   r   IID_IDebugDocumentContextr   r/   r=   r   r   r   r   r   r   r      s,    %'9:99:$)r   r   c                   H    \ rS rSrSS/r\R                  /rS rS r	S r
Srg)	DebugCodeContexti0  GetDocumentContextSetBreakPointc                     g r,   r   r-   s    r   r/   DebugCodeContext.__init__4  r1   r   c                     [        S5        g)z5Return value must be a PyIDebugDocumentContext objectr   Nr3   r-   s    r   r   #DebugCodeContext.GetDocumentContext7  s    )*r   c                     [        S5        g)zbps -- an integer with flags.r   Nr3   )r.   bpss     r   r   DebugCodeContext.SetBreakPoint;  rl   r   r   N)r   r   r   r   r8   r   IID_IDebugCodeContextr   r/   r   r   r   r   r   r   r   r   0  s+    ,o>556+&r   r   c                   ^    \ rS rSrSr/ SQr\R                  /rS r	S r
S rS rS rS	 rS
rg)DebugStackFramei@  zHAbstraction representing a logical stack frame on the stack of a thread.)GetCodeContextGetDescriptionStringGetLanguageString	GetThreadGetDebugPropertyc                     g r,   r   r-   s    r   r/   DebugStackFrame.__init__L  r1   r   c                     [        S5        g)zsReturns the current code context associated with the stack frame.

Return value must be a IDebugCodeContext object
r   Nr3   r-   s    r   r   DebugStackFrame.GetCodeContextO  s    
 	%&r   c                     [        S5        g)zmReturns a textual description of the stack frame.

fLong -- A flag indicating if the long name is requested.
r   Nr3   )r.   fLongs     r   r   $DebugStackFrame.GetDescriptionStringV  s    
 	+,r   c                     [        S5        g)zxReturns a short or long textual description of the language.

fLong -- A flag indicating if the long name is requested.
r   Nr3   r-   s    r   r   !DebugStackFrame.GetLanguageString]  s    
 	()r   c                     [        S5        g)z_Returns the thread associated with this stack frame.

Result must be a IDebugApplicationThread
r   Nr3   r-   s    r   r   DebugStackFrame.GetThreadd  s    
 	[!r   c                     [        S5        g )Nr   r3   r-   s    r   r    DebugStackFrame.GetDebugPropertyk  s    '(r   r   N)r   r   r   r   r   r8   r   IID_IDebugStackFramer   r/   r   r   r   r   r   r   r   r   r   r   r   @  s<    R  445'-*")r   r   c                   d    \ rS rSrSr/ SQr\R                  /rS r	S r
S rS rS rS	 rS
 rSrg)DebugDocumentHostio  zThe interface from the IDebugDocumentHelper back to
the smart host or language engine.  This interface
exposes host specific functionality such as syntax coloring.
)GetDeferredTextGetScriptTextAttributesOnCreateDocumentContextr   r   r   c                     g r,   r   r-   s    r   r/   DebugDocumentHost.__init__  r1   r   c                     [        S5        g )Nr   r3   )r.   dwTextStartCookier   	bWantAttrs       r   r   !DebugDocumentHost.GetDeferredText      &'r   c                     [        S5        g )Nr   r3   )r.   codeTextdelimterTextflagss       r   r   )DebugDocumentHost.GetScriptTextAttributes      ./r   c                     [        S5        g )Nr   r3   r-   s    r   r   )DebugDocumentHost.OnCreateDocumentContext  r  r   c                     [        S5        g )Nr   r3   r-   s    r   r   DebugDocumentHost.GetPathName  r   r   c                     [        S5        g )Nr   r3   r-   s    r   r   DebugDocumentHost.GetFileName  r   r   c                     [        S5        g )Nr   r3   r-   s    r   r   DebugDocumentHost.NotifyChanged  
    _%r   r   N)r   r   r   r   r   r8   r   IID_IDebugDocumentHostr   r/   r   r   r   r   r   r   r   r   r   r   r   r   o  sC    
  667(00$$&r   r   c                       \ rS rSr\R
                  R                  R                  \R
                  R                  R                  -   r	\
R                  \
R                  /rS rS rS rS rS rS rS rS	 rS
rg)DebugDocumentTextConnectServeri  c                      SU l         0 U l        g )N)cookieNoconnectionsr-   s    r   r/   'DebugDocumentTextConnectServer.__init__  s    r   c                     [        S5        g )NEnumConnectionsr3   r-   s    r   r  .DebugDocumentTextConnectServer.EnumConnections  r   r   c                     [        S5        g )NGetConnectionInterfacer3   r-   s    r   r  5DebugDocumentTextConnectServer.GetConnectionInterface      -.r   c                     [        U 5      $ r,   )r   r-   s    r   GetConnectionPointContainer:DebugDocumentTextConnectServer.GetConnectionPointContainer  s    T{r   c                     UR                  [        R                  S5      nU =R                  S-  sl        X R                  U R                  '   U R                  $ )N   )QueryInterfacer   r   r  r  )r.   pUnk	interfaces      r   Advise%DebugDocumentTextConnectServer.Advise  sF     ''(L(LaP	*3'}}r   c                 n     U R                   U	 g ! [         a    [        [        R                  S9s $ f = fN)scode)r  KeyErrorr   winerrorE_UNEXPECTED)r.   cookies     r   Unadvise'DebugDocumentTextConnectServer.Unadvise  s5    	=  ( 	=h&;&;<<	=s    !44c                     [        S5        g )NEnumConnectionPointsr3   r-   s    r   r3  3DebugDocumentTextConnectServer.EnumConnectionPoints      +,r   c                 n    U[         R                  :X  a  [        U 5      $ [        [        R
                  S9er*  )r   r   r   r   r-  E_NOINTERFACE)r.   iids     r   FindConnectionPoint2DebugDocumentTextConnectServer.FindConnectionPoint  s+    '666;!7!788r   )r  r  N)r   r   r   r   win32comserverconnect!IConnectionPointContainer_methodsIConnectionPoint_methodsr8   	pythoncomIID_IConnectionPointIID_IConnectionPointContainerr   r/   r  r  r   r'  r0  r3  r9  r   r   r   r   r  r    sv    AA
//
!
!
:
:	; 
 	&&//(/=-9r   r  c                   r    \ rS rSr/ SQr\R                  /rS rS r	S r
S rS rS rS	 rS
 rS rS rSrg)RemoteDebugApplicationEventsi  )
OnConnectDebuggerOnDisconnectDebugger	OnSetNameOnDebugOutputOnCloseOnEnterBreakPointOnLeaveBreakPointOnCreateThreadOnDestroyThreadOnBreakFlagChangec                     [        S5        g)z'appDebugger -- a PyIApplicationDebuggerrE  Nr3   )r.   appDebuggers     r   rE  .RemoteDebugApplicationEvents.OnConnectDebugger  r   r   c                     [        S5        g )NrF  r3   r-   s    r   rF  1RemoteDebugApplicationEvents.OnDisconnectDebugger  r5  r   c                     [        S5        g )NrG  r3   )r.   names     r   rG  &RemoteDebugApplicationEvents.OnSetName  s
    [!r   c                     [        S5        g )NrH  r3   )r.   strings     r   rH  *RemoteDebugApplicationEvents.OnDebugOutput  r  r   c                     [        S5        g )NrI  r3   r-   s    r   rI  $RemoteDebugApplicationEvents.OnClose  s
    Yr   c                     [        S5        g)'rdat -- PyIRemoteDebugApplicationThreadrJ  Nr3   r.   rdats     r   rJ  .RemoteDebugApplicationEvents.OnEnterBreakPoint  r   r   c                     [        S5        g)r]  rK  Nr3   r^  s     r   rK  .RemoteDebugApplicationEvents.OnLeaveBreakPoint  r   r   c                     [        S5        g)r]  rL  Nr3   r^  s     r   rL  +RemoteDebugApplicationEvents.OnCreateThread  s    %&r   c                     [        S5        g)r]  rM  Nr3   r^  s     r   rM  ,RemoteDebugApplicationEvents.OnDestroyThread  s    &'r   c                     g)zabf -- int - one of the axdebug.APPBREAKFLAGS constants
rdat -- PyIRemoteDebugApplicationThread
RaiseNotImpl("OnBreakFlagChange")
Nr   )r.   abfr_  s      r   rN  .RemoteDebugApplicationEvents.OnBreakFlagChange   s    r   r   N)r   r   r   r   r8   r   !IID_IRemoteDebugApplicationEventsr   rE  rF  rG  rH  rI  rJ  rK  rL  rM  rN  r   r   r   r   rD  rD    sM      AAB*-"& **'(r   rD  c                   H    \ rS rSrSS/r\R                  /rS rS r	S r
Srg)	DebugExpressionContexti  ParseLanguageTextGetLanguageInfoc                     g r,   r   r-   s    r   r/   DebugExpressionContext.__init__  r1   r   c                     [        S5        g)z
result is IDebugExpression
rm  Nr3   )r.   coderadixdelimr  s        r   rm  (DebugExpressionContext.ParseLanguageText  s     	()r   c                     [        S5        g)z)
result is (string langName, iid langId)
rn  Nr3   r-   s    r   rn  &DebugExpressionContext.GetLanguageInfo  s     	&'r   r   N)r   r   r   r   r8   r   IID_IDebugExpressionContextr   r/   rm  rn  r   r   r   r   rl  rl    s,    +->?;;<*(r   rl  c                   T    \ rS rSr/ SQr\R                  /rS rS r	S r
S rS rSrg	)
DebugExpressioni  )StartAbortQueryIsCompleteGetResultAsStringGetResultAsDebugPropertyc                     [        S5        g)z8
callback -- an IDebugExpressionCallback

result - void
r{  Nr3   )r.   callbacks     r   r{  DebugExpression.Start%  s     	Wr   c                     [        S5        g)
no params
result -- void
r|  Nr3   r-   s    r   r|  DebugExpression.Abort-  s    
 	Wr   c                     [        S5        g)r  r}  Nr3   r-   s    r   r}  DebugExpression.QueryIsComplete4  s    
 	&'r   c                     [        S5        g )Nr~  r3   r-   s    r   r~  !DebugExpression.GetResultAsString;  s    ()r   c                     [        S5        g )Nr  r3   r-   s    r   r  (DebugExpression.GetResultAsDebugProperty>  s    /0r   r   N)r   r   r   r   r8   r   IID_IDebugExpressionr   r{  r|  r}  r~  r  r   r   r   r   rz  rz    s4      445(*1r   rz  c                   :    \ rS rSrS/r\R                  /rS rSr	g)ProvideExpressionContextsiB  EnumExpressionContextsc                     [        S5        g )Nr  r3   r-   s    r   r  0ProvideExpressionContexts.EnumExpressionContextsF  r  r   r   N)
r   r   r   r   r8   r   IID_IProvideExpressionContextsr   r  r   r   r   r   r  r  B  s    01>>?/r   r  )#r@  win32com.server.connectr;  r-  win32com.axdebugr   win32com.axdebug.utilr   r   win32com.server.exceptionr   win32com.server.utilr   r	   r   r   r   r#   r'   r;   rB   r`   rv   rz   r   r   r   r   r   r   r  rD  rl  rz  r  r   r   r   <module>r     s#      $ 5 2 6	<1 	<	;0 	;	@ 5 	@B"7 BH(= H+ +($- $%0 %P! !4Y% Y:- :-z& &D3 3D) ) & & ,) ,)^*& *&`/9 /9d3 3l( (($1 $1N/ /r   