netapi32: Fix tests when the machine is on DOMAIN.
[wine/wine64.git] / include / evntrace.h
blob093696b47fb5c8edef216f69bddd4593ed515ec0
1 /*
2 * Copyright (C) 2005 Mike McCormack
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
19 #ifndef _EVNTRACE_
20 #define _EVNTRACE_
22 #include <guiddef.h>
24 #ifdef __cplusplus
25 extern "C" {
26 #endif
28 typedef ULONG64 TRACEHANDLE, *PTRACEHANDLE;
30 struct _EVENT_TRACE_LOGFILEA;
31 struct _EVENT_TRACE_LOGFILEW;
33 typedef struct _EVENT_TRACE_LOGFILEA EVENT_TRACE_LOGFILEA, *PEVENT_TRACE_LOGFILEA;
34 typedef struct _EVENT_TRACE_LOGFILEW EVENT_TRACE_LOGFILEW, *PEVENT_TRACE_LOGFILEW;
36 typedef ULONG (WINAPI * PEVENT_TRACE_BUFFER_CALLBACKA)( PEVENT_TRACE_LOGFILEA );
37 typedef ULONG (WINAPI * PEVENT_TRACE_BUFFER_CALLBACKW)( PEVENT_TRACE_LOGFILEW );
39 typedef ULONG (WINAPI * WMIDPREQUEST)( WMIDPREQUESTCODE, PVOID, ULONG*, PVOID );
41 typedef struct _TRACE_GUID_REGISTRATION
43 LPCGUID Guid;
44 HANDLE RegHandle;
45 } TRACE_GUID_REGISTRATION, *PTRACE_GUID_REGISTRATION;
47 typedef struct _EVENT_TRACE_HEADER
49 USHORT Size;
50 union
52 USHORT FieldTypeFlags;
53 struct
55 UCHAR HeaderType;
56 UCHAR MarkerFlags;
57 } DUMMYSTRUCTNAME;
58 } DUMMYUNIONNAME;
59 union
61 ULONG Version;
62 struct
64 UCHAR Type;
65 UCHAR Level;
66 USHORT Version;
67 } Class;
68 } DUMMYUNIONNAME1;
69 ULONG ThreadId;
70 ULONG ProcessId;
71 LARGE_INTEGER TimeStamp;
72 union
74 GUID Guid;
75 ULONGLONG GuidPtr;
76 } DUMMYUNIONNAME2;
77 union
79 struct
81 ULONG ClientContext;
82 ULONG Flags;
83 } DUMMYSTRUCTNAME1;
84 struct
86 ULONG KernelTime;
87 ULONG UserTime;
88 } DUMMYSTRUCTNAME2;
89 } DUMMYUNIONNAME3;
90 } EVENT_TRACE_HEADER, *PEVENT_TRACE_HEADER;
92 typedef struct _EVENT_TRACE
94 EVENT_TRACE_HEADER Header;
95 ULONG InstanceId;
96 ULONG ParentInstanceId;
97 GUID ParentGuid;
98 PVOID MofData;
99 ULONG MofLength;
100 ULONG ClientContext;
101 } EVENT_TRACE, *PEVENT_TRACE;
103 typedef VOID (WINAPI * PEVENT_CALLBACK)( PEVENT_TRACE );
105 typedef struct _TRACE_LOGFILE_HEADER
107 ULONG BufferSize;
108 union
110 ULONG Version;
111 struct
113 UCHAR MajorVersion;
114 UCHAR MinorVersion;
115 UCHAR SubVersion;
116 UCHAR SubMinorVersion;
117 } VersionDetail;
118 } DUMMYUNIONNAME;
119 ULONG ProviderVersion;
120 ULONG NumberOfProcessors;
121 LARGE_INTEGER EndTime;
122 ULONG TimerResolution;
123 ULONG MaximumFileSize;
124 ULONG LogFileMode;
125 ULONG BuffersWritten;
126 union
128 GUID LogInstanceGuid;
129 struct
131 ULONG StartBuffers;
132 ULONG PointerSize;
133 ULONG EventsLost;
134 ULONG CpuSpeedInMHZ;
135 } DUMMYSTRUCTNAME;
136 } DUMMYUNIONNAME1;
137 LPWSTR LoggerName;
138 LPWSTR LogFileName;
139 TIME_ZONE_INFORMATION TimeZone;
140 LARGE_INTEGER BootTime;
141 LARGE_INTEGER PerfFreq;
142 LARGE_INTEGER StartTime;
143 ULONG ReservedTime;
144 ULONG BuffersLost;
145 } TRACE_LOGFILE_HEADER, *PTRACE_LOGFILE_HEADER;
147 struct _EVENT_TRACE_LOGFILEW
149 LPWSTR LogFileName;
150 LPWSTR LoggerName;
151 LONGLONG CurrentTime;
152 ULONG LogFileMode;
153 EVENT_TRACE CurrentEvent;
154 TRACE_LOGFILE_HEADER LogfileHeader;
155 PEVENT_TRACE_BUFFER_CALLBACKW BufferCallback;
156 ULONG BufferSize;
157 ULONG Filled;
158 ULONG EventsLost;
159 PEVENT_CALLBACK EventCallback;
160 PVOID Context;
163 struct _EVENT_TRACE_LOGFILEA
165 LPSTR LogFileName;
166 LPSTR LoggerName;
167 LONGLONG CurrentTime;
168 ULONG LogFileMode;
169 EVENT_TRACE CurrentEvent;
170 TRACE_LOGFILE_HEADER LogfileHeader;
171 PEVENT_TRACE_BUFFER_CALLBACKA BufferCallback;
172 ULONG BufferSize;
173 ULONG Filled;
174 ULONG EventsLost;
175 PEVENT_CALLBACK EventCallback;
176 PVOID Context;
179 ULONG WINAPI CloseTrace(TRACEHANDLE);
180 ULONG WINAPI EnableTrace(ULONG,ULONG,ULONG,LPCGUID,TRACEHANDLE);
181 ULONG WINAPI RegisterTraceGuidsA(WMIDPREQUEST,PVOID,LPCGUID,ULONG,PTRACE_GUID_REGISTRATION,LPCSTR,LPCSTR,PTRACEHANDLE);
182 ULONG WINAPI RegisterTraceGuidsW(WMIDPREQUEST,PVOID,LPCGUID,ULONG,PTRACE_GUID_REGISTRATION,LPCWSTR,LPCWSTR,PTRACEHANDLE);
183 #define RegisterTraceGuids WINELIB_NAME_AW(RegisterTraceGuids)
185 #ifdef __cplusplus
187 #endif
189 #endif /* _EVNTRACE_ */