Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

230 lines
6.2 KiB

  1. /*++
  2. Copyright (C) Microsoft Corporation, 1991 - 1999
  3. Module Name:
  4. DbgIdl.idl
  5. Abstract:
  6. This file specifies the interface for enhanced debugging in the endpoint mapper
  7. Author:
  8. Kamen Moutafov (kamenm) 11-18-99
  9. Revision History:
  10. --*/
  11. //
  12. // DbgIdl Interface.
  13. //
  14. [
  15. uuid(1d55b526-c137-46c5-ab79-638f2a68e869), version(1.0),
  16. ]
  17. interface DbgIdl
  18. {
  19. import "nbase.idl";
  20. cpp_quote("#if 0")
  21. typedef unsigned short USHORT;
  22. typedef byte BYTE;
  23. typedef unsigned long DWORD;
  24. cpp_quote("#endif")
  25. typedef [context_handle] void * DbgCallEnumHandle;
  26. typedef [context_handle] void * DbgThreadEnumHandle;
  27. typedef [context_handle] void * DbgEndpointEnumHandle;
  28. typedef [context_handle] void * DbgClientCallEnumHandle;
  29. cpp_quote("// the DebugCellID allows to uniquely identify a cell using just a DWORD")
  30. cpp_quote("// Giving any pointer to the cell would require QUADWORD on Win64")
  31. cpp_quote("// The SectionID corresponds to the section id of the containing")
  32. cpp_quote("// section in the dictionary. The CellID is the index of the cell")
  33. cpp_quote("// within the containing section")
  34. typedef struct tagDebugCellID
  35. {
  36. USHORT SectionID;
  37. USHORT CellID;
  38. } DebugCellID;
  39. typedef struct tagLRPCCaller
  40. {
  41. USHORT PID;
  42. USHORT TID;
  43. } LRPCCaller;
  44. typedef enum tagDebugCellType
  45. {
  46. dctInvalid,
  47. dctFree,
  48. dctCallInfo,
  49. dctThreadInfo,
  50. dctEndpointInfo,
  51. dctClientCallInfo,
  52. dctConnectionInfo,
  53. dctCallTargetInfo,
  54. dctUsedGeneric
  55. } DebugCellType;
  56. typedef enum tagConnectionReferenceType
  57. {
  58. crtOsfConnection,
  59. crtLrpcConnection
  60. } ConnectionReferenceType;
  61. typedef [switch_type(short)] union tagConnectionReferenceInfo
  62. {
  63. [case (crtOsfConnection)]
  64. DebugCellID Connection;
  65. [case (crtLrpcConnection)]
  66. LRPCCaller Caller;
  67. } ConnectionReferenceInfo;
  68. typedef struct tagRemoteDebugCallInfo
  69. {
  70. BYTE Type;
  71. BYTE Status;
  72. USHORT ProcNum;
  73. DWORD InterfaceUUIDStart;
  74. DebugCellID ServicingTID;
  75. DWORD CallFlags;
  76. DWORD CallID;
  77. DWORD LastUpdateTime;
  78. ConnectionReferenceType ConnectionType;
  79. [switch_is(ConnectionType)] ConnectionReferenceInfo connInfo;
  80. } RemoteDebugCallInfo;
  81. typedef struct tagRemoteDebugConnectionInfo
  82. {
  83. BYTE Type;
  84. BYTE Flags;
  85. USHORT LastTransmitFragmentSize;
  86. DebugCellID Endpoint;
  87. DWORD ConnectionID[2];
  88. DWORD LastSendTime;
  89. DWORD LastReceiveTime;
  90. } RemoteDebugConnectionInfo;
  91. typedef struct tagRemoteDebugThreadInfo
  92. {
  93. BYTE Type;
  94. USHORT Status;
  95. DWORD LastUpdateTime;
  96. USHORT TID;
  97. DebugCellID Endpoint;
  98. } RemoteDebugThreadInfo;
  99. typedef struct tagRemoteDebugEndpointInfo
  100. {
  101. BYTE Type;
  102. BYTE ProtseqType;
  103. BYTE Status;
  104. short EndpointNameLength;
  105. [size_is(EndpointNameLength)] char *EndpointName;
  106. } RemoteDebugEndpointInfo;
  107. typedef struct tagRemoteDebugClientCallInfo
  108. {
  109. BYTE Type;
  110. USHORT ProcNum;
  111. DebugCellID ServicingThread;
  112. DWORD IfStart;
  113. DWORD CallID;
  114. DebugCellID CallTargetID;
  115. short EndpointLength;
  116. [size_is(EndpointLength)] char *Endpoint;
  117. } RemoteDebugClientCallInfo;
  118. typedef struct tagRemoteDebugCallTargetInfo
  119. {
  120. BYTE Type;
  121. USHORT ProtocolSequence;
  122. DWORD LastUpdateTime;
  123. short TargetServerLength;
  124. [size_is(TargetServerLength)] char *TargetServer;
  125. } RemoteDebugCallTargetInfo;
  126. typedef [switch_type(short)] union tagRemoteDebugCellUnionBody
  127. {
  128. [case (dctCallInfo)]
  129. RemoteDebugCallInfo callInfo;
  130. [case (dctThreadInfo)]
  131. RemoteDebugThreadInfo threadInfo;
  132. [case (dctEndpointInfo)]
  133. RemoteDebugEndpointInfo endpointInfo;
  134. [case (dctClientCallInfo)]
  135. RemoteDebugClientCallInfo clientCallInfo;
  136. [case (dctConnectionInfo)]
  137. RemoteDebugConnectionInfo connectionInfo;
  138. [case (dctCallTargetInfo)]
  139. RemoteDebugCallTargetInfo callTargetInfo;
  140. } RemoteDebugCellUnionBody;
  141. typedef struct tagRemoteDebugCellUnion
  142. {
  143. short UnionType;
  144. [switch_is(UnionType)] RemoteDebugCellUnionBody debugInfo;
  145. } RemoteDebugCellUnion;
  146. // in, out, unique means client side must deallocate it after the call returns
  147. error_status_t RemoteGetCellByDebugCellID([in] DWORD ProcessID, [in] DebugCellID CellID,
  148. [in, out, unique] RemoteDebugCellUnion **debugInfo);
  149. // call enumeration routines
  150. error_status_t RemoteOpenRPCDebugCallInfoEnumeration([out] DbgCallEnumHandle *h, [in] DWORD CallID,
  151. [in] DWORD IfStart, [in] int ProcNum, [in] DWORD ProcessID);
  152. error_status_t RemoteGetNextRPCDebugCallInfo([in] DbgCallEnumHandle h,
  153. [in, out, unique] RemoteDebugCallInfo **debugInfo, [out] DebugCellID *CellID,
  154. [out] DWORD *ProcessID);
  155. error_status_t RemoteFinishRPCDebugCallInfoEnumeration([in, out] DbgCallEnumHandle *h);
  156. // endpoint enumeration routines
  157. error_status_t RemoteOpenRPCDebugEndpointInfoEnumeration([out] DbgEndpointEnumHandle *h,
  158. [in] short EndpointSize, [in, size_is(EndpointSize), unique] char *Endpoint);
  159. error_status_t RemoteGetNextRPCDebugEndpointInfo([in] DbgEndpointEnumHandle h,
  160. [in, out, unique] RemoteDebugEndpointInfo **debugInfo, [out] DebugCellID *CellID,
  161. [out] DWORD *ProcessID);
  162. error_status_t RemoteFinishRPCDebugEndpointInfoEnumeration([in, out] DbgEndpointEnumHandle *h);
  163. // thread enumeration routines
  164. error_status_t RemoteOpenRPCDebugThreadInfoEnumeration([out] DbgThreadEnumHandle *h,
  165. [in] DWORD ProcessID, [in] DWORD ThreadID);
  166. error_status_t RemoteGetNextRPCDebugThreadInfo([in] DbgThreadEnumHandle h,
  167. [in, out, unique] RemoteDebugThreadInfo **debugInfo, [out] DebugCellID *CellID,
  168. [out] DWORD *ProcessID);
  169. error_status_t RemoteFinishRPCDebugThreadInfoEnumeration([in, out] DbgThreadEnumHandle *h);
  170. // client call enumeration routines
  171. error_status_t RemoteOpenRPCDebugClientCallInfoEnumeration([out] DbgClientCallEnumHandle *h,
  172. [in] DWORD CallID, [in] DWORD IfStart, [in] int ProcNum, [in] DWORD ProcessID);
  173. error_status_t RemoteGetNextRPCDebugClientCallInfo([in] DbgClientCallEnumHandle h,
  174. [in, out, unique] RemoteDebugClientCallInfo **debugInfo,
  175. [in, out, unique] RemoteDebugCallTargetInfo **CallTargetDebugInfo,
  176. [out] DebugCellID *CellID,
  177. [out] DWORD *ProcessID);
  178. error_status_t RemoteFinishRPCDebugClientCallInfoEnumeration([in, out] DbgClientCallEnumHandle *h);
  179. } // interface DbgIdl