1 // Licensed under the Apache License, Version 2.0 2 // <LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0> or the MIT license 3 // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your option. 4 // All files in the project carrying such notice may not be copied, modified, or distributed 5 // except according to those terms. 6 //! This module defines the 32-Bit Windows Base APIs 7 use ctypes::{c_char, c_int, c_long, c_void}; 8 use shared::basetsd::{ 9 DWORD64, DWORD_PTR, LONG_PTR, PDWORD64, PDWORD_PTR, PSIZE_T, PULONG_PTR, SIZE_T, UINT_PTR, 10 ULONG_PTR, 11 }; 12 use shared::guiddef::GUID; 13 use shared::minwindef::{ 14 ATOM, BOOL, BYTE, DWORD, FARPROC, FILETIME, HFILE, HGLOBAL, HLOCAL, HMODULE, HRSRC, LPBOOL, 15 LPBYTE, LPCVOID, LPDWORD, LPFILETIME, LPVOID, LPWORD, PBOOL, PDWORD, PUCHAR, PULONG, PUSHORT, 16 UCHAR, UINT, ULONG, USHORT, WORD, 17 }; 18 use shared::windef::HWND; 19 use um::cfgmgr32::MAX_PROFILE_LEN; 20 use um::fileapi::STREAM_INFO_LEVELS; 21 use um::libloaderapi::{ 22 ENUMRESLANGPROCA, ENUMRESLANGPROCW, ENUMRESNAMEPROCA, ENUMRESTYPEPROCA, ENUMRESTYPEPROCW, 23 }; 24 use um::minwinbase::{ 25 FILE_INFO_BY_HANDLE_CLASS, FINDEX_INFO_LEVELS, FINDEX_SEARCH_OPS, GET_FILEEX_INFO_LEVELS, 26 LPOVERLAPPED, LPOVERLAPPED_COMPLETION_ROUTINE, LPSECURITY_ATTRIBUTES, PREASON_CONTEXT, 27 }; 28 use um::processthreadsapi::{ 29 LPPROCESS_INFORMATION, LPPROC_THREAD_ATTRIBUTE_LIST, LPSTARTUPINFOA, LPSTARTUPINFOW, 30 STARTUPINFOA, STARTUPINFOW, 31 }; 32 use um::winnt::{ 33 BOOLEAN, CHAR, DWORDLONG, EXECUTION_STATE, FILE_ID_128, HANDLE, HRESULT, INT, LANGID, 34 LARGE_INTEGER, LATENCY_TIME, LONG, LPCCH, LPCH, LPCSTR, LPCWSTR, LPOSVERSIONINFOEXA, 35 LPOSVERSIONINFOEXW, LPSTR, LPWSTR, MAXLONG, PBOOLEAN, PCONTEXT, PCWSTR, PFIRMWARE_TYPE, 36 PHANDLE, PIO_COUNTERS, PJOB_SET_ARRAY, PLUID, POWER_REQUEST_TYPE, PPERFORMANCE_DATA, 37 PPROCESSOR_NUMBER, PQUOTA_LIMITS, PRTL_UMS_SCHEDULER_ENTRY_POINT, 38 PSECURE_MEMORY_CACHE_CALLBACK, PSID, PSID_NAME_USE, PULONGLONG, PVOID, PWOW64_CONTEXT, 39 PWOW64_LDT_ENTRY, PWSTR, RTL_UMS_THREAD_INFO_CLASS, STATUS_ABANDONED_WAIT_0, STATUS_USER_APC, 40 STATUS_WAIT_0, SecurityAnonymous, SecurityDelegation, SecurityIdentification, 41 SecurityImpersonation, THREAD_BASE_PRIORITY_IDLE, THREAD_BASE_PRIORITY_LOWRT, 42 THREAD_BASE_PRIORITY_MAX, THREAD_BASE_PRIORITY_MIN, ULARGE_INTEGER, VOID, WAITORTIMERCALLBACK, 43 WCHAR, WOW64_CONTEXT, 44 }; 45 #[cfg(target_arch = "x86")] 46 use um::winnt::PLDT_ENTRY; 47 use vc::vadefs::va_list; 48 pub const FILE_BEGIN: DWORD = 0; 49 pub const FILE_CURRENT: DWORD = 1; 50 pub const FILE_END: DWORD = 2; 51 pub const WAIT_FAILED: DWORD = 0xFFFFFFFF; 52 pub const WAIT_OBJECT_0: DWORD = STATUS_WAIT_0 as u32; 53 pub const WAIT_ABANDONED: DWORD = STATUS_ABANDONED_WAIT_0 as u32; 54 pub const WAIT_ABANDONED_0: DWORD = STATUS_ABANDONED_WAIT_0 as u32; 55 pub const WAIT_IO_COMPLETION: DWORD = STATUS_USER_APC as u32; 56 pub const FILE_FLAG_WRITE_THROUGH: DWORD = 0x80000000; 57 pub const FILE_FLAG_OVERLAPPED: DWORD = 0x40000000; 58 pub const FILE_FLAG_NO_BUFFERING: DWORD = 0x20000000; 59 pub const FILE_FLAG_RANDOM_ACCESS: DWORD = 0x10000000; 60 pub const FILE_FLAG_SEQUENTIAL_SCAN: DWORD = 0x08000000; 61 pub const FILE_FLAG_DELETE_ON_CLOSE: DWORD = 0x04000000; 62 pub const FILE_FLAG_BACKUP_SEMANTICS: DWORD = 0x02000000; 63 pub const FILE_FLAG_POSIX_SEMANTICS: DWORD = 0x01000000; 64 pub const FILE_FLAG_SESSION_AWARE: DWORD = 0x00800000; 65 pub const FILE_FLAG_OPEN_REPARSE_POINT: DWORD = 0x00200000; 66 pub const FILE_FLAG_OPEN_NO_RECALL: DWORD = 0x00100000; 67 pub const FILE_FLAG_FIRST_PIPE_INSTANCE: DWORD = 0x00080000; 68 pub const FILE_FLAG_OPEN_REQUIRING_OPLOCK: DWORD = 0x00040000; 69 pub const PROGRESS_CONTINUE: DWORD = 0; 70 pub const PROGRESS_CANCEL: DWORD = 1; 71 pub const PROGRESS_STOP: DWORD = 2; 72 pub const PROGRESS_QUIET: DWORD = 3; 73 pub const CALLBACK_CHUNK_FINISHED: DWORD = 0x00000000; 74 pub const CALLBACK_STREAM_SWITCH: DWORD = 0x00000001; 75 pub const COPY_FILE_FAIL_IF_EXISTS: DWORD = 0x00000001; 76 pub const COPY_FILE_RESTARTABLE: DWORD = 0x00000002; 77 pub const COPY_FILE_OPEN_SOURCE_FOR_WRITE: DWORD = 0x00000004; 78 pub const COPY_FILE_ALLOW_DECRYPTED_DESTINATION: DWORD = 0x00000008; 79 pub const COPY_FILE_COPY_SYMLINK: DWORD = 0x00000800; 80 pub const COPY_FILE_NO_BUFFERING: DWORD = 0x00001000; 81 pub const COPY_FILE_REQUEST_SECURITY_PRIVILEGES: DWORD = 0x00002000; 82 pub const COPY_FILE_RESUME_FROM_PAUSE: DWORD = 0x00004000; 83 pub const COPY_FILE_NO_OFFLOAD: DWORD = 0x00040000; 84 pub const COPY_FILE_IGNORE_EDP_BLOCK: DWORD = 0x00400000; 85 pub const COPY_FILE_IGNORE_SOURCE_ENCRYPTION: DWORD = 0x00800000; 86 pub const REPLACEFILE_WRITE_THROUGH: DWORD = 0x00000001; 87 pub const REPLACEFILE_IGNORE_MERGE_ERRORS: DWORD = 0x00000002; 88 pub const REPLACEFILE_IGNORE_ACL_ERRORS: DWORD = 0x00000004; 89 pub const PIPE_ACCESS_INBOUND: DWORD = 0x00000001; 90 pub const PIPE_ACCESS_OUTBOUND: DWORD = 0x00000002; 91 pub const PIPE_ACCESS_DUPLEX: DWORD = 0x00000003; 92 pub const PIPE_CLIENT_END: DWORD = 0x00000000; 93 pub const PIPE_SERVER_END: DWORD = 0x00000001; 94 pub const PIPE_WAIT: DWORD = 0x00000000; 95 pub const PIPE_NOWAIT: DWORD = 0x00000001; 96 pub const PIPE_READMODE_BYTE: DWORD = 0x00000000; 97 pub const PIPE_READMODE_MESSAGE: DWORD = 0x00000002; 98 pub const PIPE_TYPE_BYTE: DWORD = 0x00000000; 99 pub const PIPE_TYPE_MESSAGE: DWORD = 0x00000004; 100 pub const PIPE_ACCEPT_REMOTE_CLIENTS: DWORD = 0x00000000; 101 pub const PIPE_REJECT_REMOTE_CLIENTS: DWORD = 0x00000008; 102 pub const PIPE_UNLIMITED_INSTANCES: DWORD = 255; 103 pub const SECURITY_ANONYMOUS: DWORD = SecurityAnonymous << 16; 104 pub const SECURITY_IDENTIFICATION: DWORD = SecurityIdentification << 16; 105 pub const SECURITY_IMPERSONATION: DWORD = SecurityImpersonation << 16; 106 pub const SECURITY_DELEGATION: DWORD = SecurityDelegation << 16; 107 pub const SECURITY_CONTEXT_TRACKING: DWORD = 0x00040000; 108 pub const SECURITY_EFFECTIVE_ONLY: DWORD = 0x00080000; 109 pub const SECURITY_SQOS_PRESENT: DWORD = 0x00100000; 110 pub const SECURITY_VALID_SQOS_FLAGS: DWORD = 0x001F0000; 111 FN!{stdcall PFIBER_START_ROUTINE( 112 lpFiberParameter: LPVOID, 113 ) -> ()} 114 pub type LPFIBER_START_ROUTINE = PFIBER_START_ROUTINE; 115 FN!{stdcall PFIBER_CALLOUT_ROUTINE( 116 lpParameter: LPVOID, 117 ) -> LPVOID} 118 // FAIL_FAST_* 119 #[cfg(target_arch = "x86")] 120 pub type LPLDT_ENTRY = PLDT_ENTRY; 121 #[cfg(not(target_arch = "x86"))] 122 pub type LPLDT_ENTRY = LPVOID; // TODO - fix this for 32-bit 123 //SP_SERIALCOMM 124 //PST_* 125 // PCF_* 126 // SP_* 127 // BAUD_* 128 // DATABITS_* 129 // STOPBITS_* 130 // PARITY_* 131 STRUCT!{struct COMMPROP { 132 wPacketLength: WORD, 133 wPacketVersion: WORD, 134 dwServiceMask: DWORD, 135 dwReserved1: DWORD, 136 dwMaxTxQueue: DWORD, 137 dwMaxRxQueue: DWORD, 138 dwMaxBaud: DWORD, 139 dwProvSubType: DWORD, 140 dwProvCapabilities: DWORD, 141 dwSettableParams: DWORD, 142 dwSettableBaud: DWORD, 143 wSettableData: WORD, 144 wSettableStopParity: WORD, 145 dwCurrentTxQueue: DWORD, 146 dwCurrentRxQueue: DWORD, 147 dwProvSpec1: DWORD, 148 dwProvSpec2: DWORD, 149 wcProvChar: [WCHAR; 1], 150 }} 151 pub type LPCOMMPROP = *mut COMMPROP; 152 STRUCT!{struct COMSTAT { 153 BitFields: DWORD, 154 cbInQue: DWORD, 155 cbOutQue: DWORD, 156 }} 157 BITFIELD!{COMSTAT BitFields: DWORD [ 158 fCtsHold set_fCtsHold[0..1], 159 fDsrHold set_fDsrHold[1..2], 160 fRlsdHold set_fRlsdHold[2..3], 161 fXoffHold set_fXoffHold[3..4], 162 fXoffSent set_fXoffSent[4..5], 163 fEof set_fEof[5..6], 164 fTxim set_fTxim[6..7], 165 fReserved set_fReserved[7..32], 166 ]} 167 pub type LPCOMSTAT = *mut COMSTAT; 168 pub const DTR_CONTROL_DISABLE: DWORD = 0x00; 169 pub const DTR_CONTROL_ENABLE: DWORD = 0x01; 170 pub const DTR_CONTROL_HANDSHAKE: DWORD = 0x02; 171 pub const RTS_CONTROL_DISABLE: DWORD = 0x00; 172 pub const RTS_CONTROL_ENABLE: DWORD = 0x01; 173 pub const RTS_CONTROL_HANDSHAKE: DWORD = 0x02; 174 pub const RTS_CONTROL_TOGGLE: DWORD = 0x03; 175 STRUCT!{struct DCB { 176 DCBlength: DWORD, 177 BaudRate: DWORD, 178 BitFields: DWORD, 179 wReserved: WORD, 180 XonLim: WORD, 181 XoffLim: WORD, 182 ByteSize: BYTE, 183 Parity: BYTE, 184 StopBits: BYTE, 185 XonChar: c_char, 186 XoffChar: c_char, 187 ErrorChar: c_char, 188 EofChar: c_char, 189 EvtChar: c_char, 190 wReserved1: WORD, 191 }} 192 BITFIELD!{DCB BitFields: DWORD [ 193 fBinary set_fBinary[0..1], 194 fParity set_fParity[1..2], 195 fOutxCtsFlow set_fOutxCtsFlow[2..3], 196 fOutxDsrFlow set_fOutxDsrFlow[3..4], 197 fDtrControl set_fDtrControl[4..6], 198 fDsrSensitivity set_fDsrSensitivity[6..7], 199 fTXContinueOnXoff set_fTXContinueOnXoff[7..8], 200 fOutX set_fOutX[8..9], 201 fInX set_fInX[9..10], 202 fErrorChar set_fErrorChar[10..11], 203 fNull set_fNull[11..12], 204 fRtsControl set_fRtsControl[12..14], 205 fAbortOnError set_fAbortOnError[14..15], 206 fDummy2 set_fDummy2[15..32], 207 ]} 208 pub type LPDCB = *mut DCB; 209 STRUCT!{struct COMMTIMEOUTS { 210 ReadIntervalTimeout: DWORD, 211 ReadTotalTimeoutMultiplier: DWORD, 212 ReadTotalTimeoutConstant: DWORD, 213 WriteTotalTimeoutMultiplier: DWORD, 214 WriteTotalTimeoutConstant: DWORD, 215 }} 216 pub type LPCOMMTIMEOUTS = *mut COMMTIMEOUTS; 217 STRUCT!{struct COMMCONFIG { 218 dwSize: DWORD, 219 wVersion: WORD, 220 wReserved: WORD, 221 dcb: DCB, 222 dwProviderSubType: DWORD, 223 dwProviderOffset: DWORD, 224 dwProviderSize: DWORD, 225 wcProviderData: [WCHAR; 1], 226 }} 227 pub type LPCOMMCONFIG = *mut COMMCONFIG; 228 pub const GMEM_FIXED: UINT = 0x0000; 229 pub const GMEM_MOVEABLE: UINT = 0x0002; 230 pub const GMEM_NOCOMPACT: UINT = 0x0010; 231 pub const GMEM_NODISCARD: UINT = 0x0020; 232 pub const GMEM_ZEROINIT: UINT = 0x0040; 233 pub const GMEM_MODIFY: UINT = 0x0080; 234 pub const GMEM_DISCARDABLE: UINT = 0x0100; 235 pub const GMEM_NOT_BANKED: UINT = 0x1000; 236 pub const GMEM_SHARE: UINT = 0x2000; 237 pub const GMEM_DDESHARE: UINT = 0x2000; 238 pub const GMEM_NOTIFY: UINT = 0x4000; 239 pub const GMEM_LOWER: UINT = GMEM_NOT_BANKED; 240 pub const GMEM_VALID_FLAGS: UINT = 0x7F72; 241 pub const GMEM_INVALID_HANDLE: UINT = 0x8000; 242 pub const GHND: UINT = GMEM_MOVEABLE | GMEM_ZEROINIT; 243 pub const GPTR: UINT = GMEM_FIXED | GMEM_ZEROINIT; 244 pub const GMEM_DISCARDED: UINT = 0x4000; 245 pub const GMEM_LOCKCOUNT: UINT = 0x00FF; 246 STRUCT!{struct MEMORYSTATUS { 247 dwLength: DWORD, 248 dwMemoryLoad: DWORD, 249 dwTotalPhys: SIZE_T, 250 dwAvailPhys: SIZE_T, 251 dwTotalPageFile: SIZE_T, 252 dwAvailPageFile: SIZE_T, 253 dwTotalVirtual: SIZE_T, 254 dwAvailVirtual: SIZE_T, 255 }} 256 pub type LPMEMORYSTATUS = *mut MEMORYSTATUS; 257 // NUMA_NO_PREFERRED_NODE 258 pub const DEBUG_PROCESS: DWORD = 0x00000001; 259 pub const DEBUG_ONLY_THIS_PROCESS: DWORD = 0x00000002; 260 pub const CREATE_SUSPENDED: DWORD = 0x00000004; 261 pub const DETACHED_PROCESS: DWORD = 0x00000008; 262 pub const CREATE_NEW_CONSOLE: DWORD = 0x00000010; 263 pub const NORMAL_PRIORITY_CLASS: DWORD = 0x00000020; 264 pub const IDLE_PRIORITY_CLASS: DWORD = 0x00000040; 265 pub const HIGH_PRIORITY_CLASS: DWORD = 0x00000080; 266 pub const REALTIME_PRIORITY_CLASS: DWORD = 0x00000100; 267 pub const CREATE_NEW_PROCESS_GROUP: DWORD = 0x00000200; 268 pub const CREATE_UNICODE_ENVIRONMENT: DWORD = 0x00000400; 269 pub const CREATE_SEPARATE_WOW_VDM: DWORD = 0x00000800; 270 pub const CREATE_SHARED_WOW_VDM: DWORD = 0x00001000; 271 pub const CREATE_FORCEDOS: DWORD = 0x00002000; 272 pub const BELOW_NORMAL_PRIORITY_CLASS: DWORD = 0x00004000; 273 pub const ABOVE_NORMAL_PRIORITY_CLASS: DWORD = 0x00008000; 274 pub const INHERIT_PARENT_AFFINITY: DWORD = 0x00010000; 275 pub const INHERIT_CALLER_PRIORITY: DWORD = 0x00020000; 276 pub const CREATE_PROTECTED_PROCESS: DWORD = 0x00040000; 277 pub const EXTENDED_STARTUPINFO_PRESENT: DWORD = 0x00080000; 278 pub const PROCESS_MODE_BACKGROUND_BEGIN: DWORD = 0x00100000; 279 pub const PROCESS_MODE_BACKGROUND_END: DWORD = 0x00200000; 280 pub const CREATE_BREAKAWAY_FROM_JOB: DWORD = 0x01000000; 281 pub const CREATE_PRESERVE_CODE_AUTHZ_LEVEL: DWORD = 0x02000000; 282 pub const CREATE_DEFAULT_ERROR_MODE: DWORD = 0x04000000; 283 pub const CREATE_NO_WINDOW: DWORD = 0x08000000; 284 pub const PROFILE_USER: DWORD = 0x10000000; 285 pub const PROFILE_KERNEL: DWORD = 0x20000000; 286 pub const PROFILE_SERVER: DWORD = 0x40000000; 287 pub const CREATE_IGNORE_SYSTEM_DEFAULT: DWORD = 0x80000000; 288 // STACK_SIZE_PARAM_IS_A_RESERVATION 289 pub const THREAD_PRIORITY_LOWEST: DWORD = THREAD_BASE_PRIORITY_MIN; 290 pub const THREAD_PRIORITY_BELOW_NORMAL: DWORD = THREAD_PRIORITY_LOWEST + 1; 291 pub const THREAD_PRIORITY_NORMAL: DWORD = 0; 292 pub const THREAD_PRIORITY_HIGHEST: DWORD = THREAD_BASE_PRIORITY_MAX; 293 pub const THREAD_PRIORITY_ABOVE_NORMAL: DWORD = THREAD_PRIORITY_HIGHEST - 1; 294 pub const THREAD_PRIORITY_ERROR_RETURN: DWORD = MAXLONG as u32; 295 pub const THREAD_PRIORITY_TIME_CRITICAL: DWORD = THREAD_BASE_PRIORITY_LOWRT; 296 pub const THREAD_PRIORITY_IDLE: DWORD = THREAD_BASE_PRIORITY_IDLE; 297 pub const THREAD_MODE_BACKGROUND_BEGIN: DWORD = 0x00010000; 298 pub const THREAD_MODE_BACKGROUND_END: DWORD = 0x00020000; 299 pub const VOLUME_NAME_DOS: DWORD = 0x0; 300 // VOLUME_NAME_* 301 // FILE_NAME_* 302 // JIT_DEBUG_* 303 pub const DRIVE_UNKNOWN: DWORD = 0; 304 pub const DRIVE_NO_ROOT_DIR: DWORD = 1; 305 pub const DRIVE_REMOVABLE: DWORD = 2; 306 pub const DRIVE_FIXED: DWORD = 3; 307 pub const DRIVE_REMOTE: DWORD = 4; 308 pub const DRIVE_CDROM: DWORD = 5; 309 pub const DRIVE_RAMDISK: DWORD = 6; 310 // pub fn GetFreeSpace(); 311 pub const FILE_TYPE_UNKNOWN: DWORD = 0x0000; 312 pub const FILE_TYPE_DISK: DWORD = 0x0001; 313 pub const FILE_TYPE_CHAR: DWORD = 0x0002; 314 pub const FILE_TYPE_PIPE: DWORD = 0x0003; 315 pub const FILE_TYPE_REMOTE: DWORD = 0x8000; 316 pub const STD_INPUT_HANDLE: DWORD = -10i32 as u32; 317 pub const STD_OUTPUT_HANDLE: DWORD = -11i32 as u32; 318 pub const STD_ERROR_HANDLE: DWORD = -12i32 as u32; 319 pub const NOPARITY: BYTE = 0; 320 pub const ODDPARITY: BYTE = 1; 321 pub const EVENPARITY: BYTE = 2; 322 pub const MARKPARITY: BYTE = 3; 323 pub const SPACEPARITY: BYTE = 4; 324 pub const ONESTOPBIT: BYTE = 0; 325 pub const ONE5STOPBITS: BYTE = 1; 326 pub const TWOSTOPBITS: BYTE = 2; 327 pub const IGNORE: DWORD = 0; 328 pub const INFINITE: DWORD = 0xFFFFFFFF; 329 pub const CBR_110: DWORD = 110; 330 pub const CBR_300: DWORD = 300; 331 pub const CBR_600: DWORD = 600; 332 pub const CBR_1200: DWORD = 1200; 333 pub const CBR_2400: DWORD = 2400; 334 pub const CBR_4800: DWORD = 4800; 335 pub const CBR_9600: DWORD = 9600; 336 pub const CBR_14400: DWORD = 14400; 337 pub const CBR_19200: DWORD = 19200; 338 pub const CBR_38400: DWORD = 38400; 339 pub const CBR_56000: DWORD = 56000; 340 pub const CBR_57600: DWORD = 57600; 341 pub const CBR_115200: DWORD = 115200; 342 pub const CBR_128000: DWORD = 128000; 343 pub const CBR_256000: DWORD = 256000; 344 // CE_* 345 // IE_* 346 // EV_* 347 pub const SETXOFF: DWORD = 1; 348 pub const SETXON: DWORD = 2; 349 pub const SETRTS: DWORD = 3; 350 pub const CLRRTS: DWORD = 4; 351 pub const SETDTR: DWORD = 5; 352 pub const CLRDTR: DWORD = 6; 353 pub const RESETDEV: DWORD = 7; 354 pub const SETBREAK: DWORD = 8; 355 pub const CLRBREAK: DWORD = 9; 356 pub const PURGE_TXABORT: DWORD = 0x0001; 357 pub const PURGE_RXABORT: DWORD = 0x0002; 358 pub const PURGE_TXCLEAR: DWORD = 0x0004; 359 pub const PURGE_RXCLEAR: DWORD = 0x0008; 360 pub const MS_CTS_ON: DWORD = 0x0010; 361 pub const MS_DSR_ON: DWORD = 0x0020; 362 pub const MS_RING_ON: DWORD = 0x0040; 363 pub const MS_RLSD_ON: DWORD = 0x0080; 364 // S_* 365 // NMPWAIT_* 366 // FS_* 367 // OF_* 368 pub const OFS_MAXPATHNAME: usize = 128; 369 STRUCT!{struct OFSTRUCT { 370 cBytes: BYTE, 371 fFixedDisk: BYTE, 372 nErrCode: WORD, 373 Reserved1: WORD, 374 Reserved2: WORD, 375 szPathName: [CHAR; OFS_MAXPATHNAME], 376 }} 377 pub type POFSTRUCT = *mut OFSTRUCT; 378 pub type LPOFSTRUCT = *mut OFSTRUCT; 379 extern "system" { GlobalAlloc( uFlags: UINT, dwBytes: SIZE_T, ) -> HGLOBAL380 pub fn GlobalAlloc( 381 uFlags: UINT, 382 dwBytes: SIZE_T, 383 ) -> HGLOBAL; GlobalReAlloc( hMem: HGLOBAL, dwBytes: SIZE_T, uFlags: UINT, ) -> HGLOBAL384 pub fn GlobalReAlloc( 385 hMem: HGLOBAL, 386 dwBytes: SIZE_T, 387 uFlags: UINT, 388 ) -> HGLOBAL; GlobalSize( hMem: HGLOBAL, ) -> SIZE_T389 pub fn GlobalSize( 390 hMem: HGLOBAL, 391 ) -> SIZE_T; GlobalFlags( hMem: HGLOBAL, ) -> UINT392 pub fn GlobalFlags( 393 hMem: HGLOBAL, 394 ) -> UINT; GlobalLock( hMem: HGLOBAL, ) -> LPVOID395 pub fn GlobalLock( 396 hMem: HGLOBAL, 397 ) -> LPVOID; GlobalHandle( pMem: LPCVOID, ) -> HGLOBAL398 pub fn GlobalHandle( 399 pMem: LPCVOID, 400 ) -> HGLOBAL; GlobalUnlock( hMem: HGLOBAL, ) -> BOOL401 pub fn GlobalUnlock( 402 hMem: HGLOBAL, 403 ) -> BOOL; GlobalFree( hMem: HGLOBAL, ) -> HGLOBAL404 pub fn GlobalFree( 405 hMem: HGLOBAL, 406 ) -> HGLOBAL; GlobalCompact( dwMinFree: DWORD, ) -> SIZE_T407 pub fn GlobalCompact( 408 dwMinFree: DWORD, 409 ) -> SIZE_T; GlobalFix( hMem: HGLOBAL, )410 pub fn GlobalFix( 411 hMem: HGLOBAL, 412 ); GlobalUnfix( hMem: HGLOBAL, )413 pub fn GlobalUnfix( 414 hMem: HGLOBAL, 415 ); GlobalWire( hMem: HGLOBAL, ) -> LPVOID416 pub fn GlobalWire( 417 hMem: HGLOBAL, 418 ) -> LPVOID; GlobalUnWire( hMem: HGLOBAL, ) -> BOOL419 pub fn GlobalUnWire( 420 hMem: HGLOBAL, 421 ) -> BOOL; GlobalMemoryStatus( lpBuffer: LPMEMORYSTATUS, )422 pub fn GlobalMemoryStatus( 423 lpBuffer: LPMEMORYSTATUS, 424 ); LocalAlloc( uFlags: UINT, uBytes: SIZE_T, ) -> HLOCAL425 pub fn LocalAlloc( 426 uFlags: UINT, 427 uBytes: SIZE_T, 428 ) -> HLOCAL; LocalReAlloc( hMem: HLOCAL, uBytes: SIZE_T, uFlags: UINT, ) -> HLOCAL429 pub fn LocalReAlloc( 430 hMem: HLOCAL, 431 uBytes: SIZE_T, 432 uFlags: UINT, 433 ) -> HLOCAL; LocalLock( hMem: HLOCAL, ) -> LPVOID434 pub fn LocalLock( 435 hMem: HLOCAL, 436 ) -> LPVOID; LocalHandle( pMem: LPCVOID, ) -> HLOCAL437 pub fn LocalHandle( 438 pMem: LPCVOID, 439 ) -> HLOCAL; LocalUnlock( hMem: HLOCAL, ) -> BOOL440 pub fn LocalUnlock( 441 hMem: HLOCAL, 442 ) -> BOOL; LocalSize( hMem: HLOCAL, ) -> SIZE_T443 pub fn LocalSize( 444 hMem: HLOCAL, 445 ) -> SIZE_T; LocalFlags( hMem: HLOCAL, ) -> UINT446 pub fn LocalFlags( 447 hMem: HLOCAL, 448 ) -> UINT; LocalFree( hMem: HLOCAL, ) -> HLOCAL449 pub fn LocalFree( 450 hMem: HLOCAL, 451 ) -> HLOCAL; LocalShrink( hMem: HLOCAL, cbNewSize: UINT, ) -> SIZE_T452 pub fn LocalShrink( 453 hMem: HLOCAL, 454 cbNewSize: UINT, 455 ) -> SIZE_T; LocalCompact( uMinFree: UINT, ) -> SIZE_T456 pub fn LocalCompact( 457 uMinFree: UINT, 458 ) -> SIZE_T; 459 } 460 // SCS_* 461 extern "system" { GetBinaryTypeA( lpApplicationName: LPCSTR, lpBinaryType: LPDWORD, ) -> BOOL462 pub fn GetBinaryTypeA( 463 lpApplicationName: LPCSTR, 464 lpBinaryType: LPDWORD, 465 ) -> BOOL; GetBinaryTypeW( lpApplicationName: LPCWSTR, lpBinaryType: LPDWORD, ) -> BOOL466 pub fn GetBinaryTypeW( 467 lpApplicationName: LPCWSTR, 468 lpBinaryType: LPDWORD, 469 ) -> BOOL; GetShortPathNameA( lpszLongPath: LPCSTR, lpszShortPath: LPSTR, cchBuffer: DWORD, ) -> DWORD470 pub fn GetShortPathNameA( 471 lpszLongPath: LPCSTR, 472 lpszShortPath: LPSTR, 473 cchBuffer: DWORD, 474 ) -> DWORD; GetLongPathNameTransactedA( lpszShortPath: LPCSTR, lpszLongPath: LPSTR, cchBuffer: DWORD, hTransaction: HANDLE, ) -> DWORD475 pub fn GetLongPathNameTransactedA( 476 lpszShortPath: LPCSTR, 477 lpszLongPath: LPSTR, 478 cchBuffer: DWORD, 479 hTransaction: HANDLE, 480 ) -> DWORD; GetLongPathNameTransactedW( lpszShortPath: LPCWSTR, lpszLongPath: LPWSTR, cchBuffer: DWORD, hTransaction: HANDLE, ) -> DWORD481 pub fn GetLongPathNameTransactedW( 482 lpszShortPath: LPCWSTR, 483 lpszLongPath: LPWSTR, 484 cchBuffer: DWORD, 485 hTransaction: HANDLE, 486 ) -> DWORD; GetProcessAffinityMask( hProcess: HANDLE, lpProcessAffinityMask: PDWORD_PTR, lpSystemAffinityMask: PDWORD_PTR, ) -> BOOL487 pub fn GetProcessAffinityMask( 488 hProcess: HANDLE, 489 lpProcessAffinityMask: PDWORD_PTR, 490 lpSystemAffinityMask: PDWORD_PTR, 491 ) -> BOOL; SetProcessAffinityMask( hProcess: HANDLE, dwProcessAffinityMask: DWORD, ) -> BOOL492 pub fn SetProcessAffinityMask( 493 hProcess: HANDLE, 494 dwProcessAffinityMask: DWORD, 495 ) -> BOOL; GetProcessIoCounters( hProcess: HANDLE, lpIoCounters: PIO_COUNTERS, ) -> BOOL496 pub fn GetProcessIoCounters( 497 hProcess: HANDLE, 498 lpIoCounters: PIO_COUNTERS, 499 ) -> BOOL; GetProcessWorkingSetSize( hProcess: HANDLE, lpMinimumWorkingSetSize: PSIZE_T, lpMaximumWorkingSetSize: PSIZE_T, ) -> BOOL500 pub fn GetProcessWorkingSetSize( 501 hProcess: HANDLE, 502 lpMinimumWorkingSetSize: PSIZE_T, 503 lpMaximumWorkingSetSize: PSIZE_T, 504 ) -> BOOL; SetProcessWorkingSetSize( hProcess: HANDLE, dwMinimumWorkingSetSize: SIZE_T, dwMaximumWorkingSetSize: SIZE_T, ) -> BOOL505 pub fn SetProcessWorkingSetSize( 506 hProcess: HANDLE, 507 dwMinimumWorkingSetSize: SIZE_T, 508 dwMaximumWorkingSetSize: SIZE_T, 509 ) -> BOOL; FatalExit( ExitCode: c_int, )510 pub fn FatalExit( 511 ExitCode: c_int, 512 ); SetEnvironmentStringsA( NewEnvironment: LPCH, ) -> BOOL513 pub fn SetEnvironmentStringsA( 514 NewEnvironment: LPCH, 515 ) -> BOOL; SwitchToFiber( lpFiber: LPVOID, )516 pub fn SwitchToFiber( 517 lpFiber: LPVOID, 518 ); DeleteFiber( lpFiber: LPVOID, )519 pub fn DeleteFiber( 520 lpFiber: LPVOID, 521 ); ConvertFiberToThread() -> BOOL522 pub fn ConvertFiberToThread() -> BOOL; CreateFiberEx( dwStackCommitSize: SIZE_T, dwStackReserveSize: SIZE_T, dwFlags: DWORD, lpStartAddress: LPFIBER_START_ROUTINE, lpParameter: LPVOID, ) -> LPVOID523 pub fn CreateFiberEx( 524 dwStackCommitSize: SIZE_T, 525 dwStackReserveSize: SIZE_T, 526 dwFlags: DWORD, 527 lpStartAddress: LPFIBER_START_ROUTINE, 528 lpParameter: LPVOID, 529 ) -> LPVOID; ConvertThreadToFiberEx( lpParameter: LPVOID, dwFlags: DWORD, ) -> LPVOID530 pub fn ConvertThreadToFiberEx( 531 lpParameter: LPVOID, 532 dwFlags: DWORD, 533 ) -> LPVOID; CreateFiber( dwStackSize: SIZE_T, lpStartAddress: LPFIBER_START_ROUTINE, lpParameter: LPVOID, ) -> LPVOID534 pub fn CreateFiber( 535 dwStackSize: SIZE_T, 536 lpStartAddress: LPFIBER_START_ROUTINE, 537 lpParameter: LPVOID, 538 ) -> LPVOID; ConvertThreadToFiber( lpParameter: LPVOID, ) -> LPVOID539 pub fn ConvertThreadToFiber( 540 lpParameter: LPVOID, 541 ) -> LPVOID; 542 } 543 pub type PUMS_CONTEXT = *mut c_void; 544 pub type PUMS_COMPLETION_LIST = *mut c_void; 545 pub type UMS_THREAD_INFO_CLASS = RTL_UMS_THREAD_INFO_CLASS; 546 pub type PUMS_THREAD_INFO_CLASS = *mut UMS_THREAD_INFO_CLASS; 547 pub type PUMS_SCHEDULER_ENTRY_POINT = PRTL_UMS_SCHEDULER_ENTRY_POINT; 548 STRUCT!{struct UMS_SCHEDULER_STARTUP_INFO { 549 UmsVersion: ULONG, 550 CompletionList: PUMS_COMPLETION_LIST, 551 SchedulerProc: PUMS_SCHEDULER_ENTRY_POINT, 552 SchedulerParam: PVOID, 553 }} 554 pub type PUMS_SCHEDULER_STARTUP_INFO = *mut UMS_SCHEDULER_STARTUP_INFO; 555 STRUCT!{struct UMS_SYSTEM_THREAD_INFORMATION { 556 UmsVersion: ULONG, 557 ThreadUmsFlags: ULONG, 558 }} 559 BITFIELD!{UMS_SYSTEM_THREAD_INFORMATION ThreadUmsFlags: ULONG [ 560 IsUmsSchedulerThread set_IsUmsSchedulerThread[0..1], 561 IsUmsWorkerThread set_IsUmsWorkerThread[1..2], 562 ]} 563 pub type PUMS_SYSTEM_THREAD_INFORMATION = *mut UMS_SYSTEM_THREAD_INFORMATION; 564 extern "system" { 565 #[cfg(target_pointer_width = "64")] CreateUmsCompletionList( UmsCompletionList: *mut PUMS_COMPLETION_LIST, ) -> BOOL566 pub fn CreateUmsCompletionList( 567 UmsCompletionList: *mut PUMS_COMPLETION_LIST, 568 ) -> BOOL; 569 #[cfg(target_pointer_width = "64")] DequeueUmsCompletionListItems( UmsCompletionList: PUMS_COMPLETION_LIST, WaitTimeOut: DWORD, UmsThreadList: *mut PUMS_CONTEXT, ) -> BOOL570 pub fn DequeueUmsCompletionListItems( 571 UmsCompletionList: PUMS_COMPLETION_LIST, 572 WaitTimeOut: DWORD, 573 UmsThreadList: *mut PUMS_CONTEXT, 574 ) -> BOOL; 575 #[cfg(target_pointer_width = "64")] GetUmsCompletionListEvent( UmsCompletionList: PUMS_COMPLETION_LIST, UmsCompletionEvent: PHANDLE, ) -> BOOL576 pub fn GetUmsCompletionListEvent( 577 UmsCompletionList: PUMS_COMPLETION_LIST, 578 UmsCompletionEvent: PHANDLE, 579 ) -> BOOL; 580 #[cfg(target_pointer_width = "64")] ExecuteUmsThread( UmsThread: PUMS_CONTEXT, ) -> BOOL581 pub fn ExecuteUmsThread( 582 UmsThread: PUMS_CONTEXT, 583 ) -> BOOL; 584 #[cfg(target_pointer_width = "64")] UmsThreadYield( SchedulerParam: PVOID, ) -> BOOL585 pub fn UmsThreadYield( 586 SchedulerParam: PVOID, 587 ) -> BOOL; 588 #[cfg(target_pointer_width = "64")] DeleteUmsCompletionList( UmsCompletionList: PUMS_COMPLETION_LIST, ) -> BOOL589 pub fn DeleteUmsCompletionList( 590 UmsCompletionList: PUMS_COMPLETION_LIST, 591 ) -> BOOL; 592 #[cfg(target_pointer_width = "64")] GetCurrentUmsThread() -> PUMS_CONTEXT593 pub fn GetCurrentUmsThread() -> PUMS_CONTEXT; 594 #[cfg(target_pointer_width = "64")] GetNextUmsListItem( UmsContext: PUMS_CONTEXT, ) -> PUMS_CONTEXT595 pub fn GetNextUmsListItem( 596 UmsContext: PUMS_CONTEXT, 597 ) -> PUMS_CONTEXT; 598 #[cfg(target_pointer_width = "64")] QueryUmsThreadInformation( UmsThread: PUMS_CONTEXT, UmsThreadInfoClass: UMS_THREAD_INFO_CLASS, UmsThreadInformation: PVOID, UmsThreadInformationLength: ULONG, ReturnLength: PULONG, ) -> BOOL599 pub fn QueryUmsThreadInformation( 600 UmsThread: PUMS_CONTEXT, 601 UmsThreadInfoClass: UMS_THREAD_INFO_CLASS, 602 UmsThreadInformation: PVOID, 603 UmsThreadInformationLength: ULONG, 604 ReturnLength: PULONG, 605 ) -> BOOL; 606 #[cfg(target_pointer_width = "64")] SetUmsThreadInformation( UmsThread: PUMS_CONTEXT, UmsThreadInfoClass: UMS_THREAD_INFO_CLASS, UmsThreadInformation: PVOID, UmsThreadInformationLength: ULONG, ) -> BOOL607 pub fn SetUmsThreadInformation( 608 UmsThread: PUMS_CONTEXT, 609 UmsThreadInfoClass: UMS_THREAD_INFO_CLASS, 610 UmsThreadInformation: PVOID, 611 UmsThreadInformationLength: ULONG, 612 ) -> BOOL; 613 #[cfg(target_pointer_width = "64")] DeleteUmsThreadContext( UmsThread: PUMS_CONTEXT, ) -> BOOL614 pub fn DeleteUmsThreadContext( 615 UmsThread: PUMS_CONTEXT, 616 ) -> BOOL; 617 #[cfg(target_pointer_width = "64")] CreateUmsThreadContext( lpUmsThread: *mut PUMS_CONTEXT, ) -> BOOL618 pub fn CreateUmsThreadContext( 619 lpUmsThread: *mut PUMS_CONTEXT, 620 ) -> BOOL; 621 #[cfg(target_pointer_width = "64")] EnterUmsSchedulingMode( SchedulerStartupInfo: PUMS_SCHEDULER_STARTUP_INFO, ) -> BOOL622 pub fn EnterUmsSchedulingMode( 623 SchedulerStartupInfo: PUMS_SCHEDULER_STARTUP_INFO, 624 ) -> BOOL; 625 #[cfg(target_pointer_width = "64")] GetUmsSystemThreadInformation( ThreadHandle: HANDLE, SystemThreadInfo: PUMS_SYSTEM_THREAD_INFORMATION, ) -> BOOL626 pub fn GetUmsSystemThreadInformation( 627 ThreadHandle: HANDLE, 628 SystemThreadInfo: PUMS_SYSTEM_THREAD_INFORMATION, 629 ) -> BOOL; SetThreadAffinityMask( hThread: HANDLE, dwThreadAffinityMask: DWORD_PTR, ) -> DWORD_PTR630 pub fn SetThreadAffinityMask( 631 hThread: HANDLE, 632 dwThreadAffinityMask: DWORD_PTR, 633 ) -> DWORD_PTR; SetProcessDEPPolicy( dwFlags: DWORD, ) -> BOOL634 pub fn SetProcessDEPPolicy( 635 dwFlags: DWORD, 636 ) -> BOOL; GetProcessDEPPolicy( hProcess: HANDLE, lpFlags: LPDWORD, lpPermanent: PBOOL, ) -> BOOL637 pub fn GetProcessDEPPolicy( 638 hProcess: HANDLE, 639 lpFlags: LPDWORD, 640 lpPermanent: PBOOL, 641 ) -> BOOL; RequestWakeupLatency( latency: LATENCY_TIME, ) -> BOOL642 pub fn RequestWakeupLatency( 643 latency: LATENCY_TIME, 644 ) -> BOOL; IsSystemResumeAutomatic() -> BOOL645 pub fn IsSystemResumeAutomatic() -> BOOL; GetThreadSelectorEntry( hThread: HANDLE, dwSelector: DWORD, lpSelectorEntry: LPLDT_ENTRY, ) -> BOOL646 pub fn GetThreadSelectorEntry( 647 hThread: HANDLE, 648 dwSelector: DWORD, 649 lpSelectorEntry: LPLDT_ENTRY, 650 ) -> BOOL; SetThreadExecutionState( esFlags: EXECUTION_STATE, ) -> EXECUTION_STATE651 pub fn SetThreadExecutionState( 652 esFlags: EXECUTION_STATE, 653 ) -> EXECUTION_STATE; PowerCreateRequest( Context: PREASON_CONTEXT, ) -> HANDLE654 pub fn PowerCreateRequest( 655 Context: PREASON_CONTEXT, 656 ) -> HANDLE; PowerSetRequest( PowerRequest: HANDLE, RequestType: POWER_REQUEST_TYPE, ) -> BOOL657 pub fn PowerSetRequest( 658 PowerRequest: HANDLE, 659 RequestType: POWER_REQUEST_TYPE, 660 ) -> BOOL; PowerClearRequest( PowerRequest: HANDLE, RequestType: POWER_REQUEST_TYPE, ) -> BOOL661 pub fn PowerClearRequest( 662 PowerRequest: HANDLE, 663 RequestType: POWER_REQUEST_TYPE, 664 ) -> BOOL; RestoreLastError( dwErrCode: DWORD, )665 pub fn RestoreLastError( 666 dwErrCode: DWORD, 667 ); 668 } 669 pub const FILE_SKIP_COMPLETION_PORT_ON_SUCCESS: UCHAR = 0x1; 670 pub const FILE_SKIP_SET_EVENT_ON_HANDLE: UCHAR = 0x2; 671 extern "system" { SetFileCompletionNotificationModes( FileHandle: HANDLE, Flags: UCHAR, ) -> BOOL672 pub fn SetFileCompletionNotificationModes( 673 FileHandle: HANDLE, 674 Flags: UCHAR, 675 ) -> BOOL; 676 } 677 pub const SEM_FAILCRITICALERRORS: UINT = 0x0001; 678 pub const SEM_NOGPFAULTERRORBOX: UINT = 0x0002; 679 pub const SEM_NOALIGNMENTFAULTEXCEPT: UINT = 0x0004; 680 pub const SEM_NOOPENFILEERRORBOX: UINT = 0x8000; 681 extern "system" { Wow64GetThreadContext( hThread: HANDLE, lpContext: PWOW64_CONTEXT, ) -> BOOL682 pub fn Wow64GetThreadContext( 683 hThread: HANDLE, 684 lpContext: PWOW64_CONTEXT, 685 ) -> BOOL; Wow64SetThreadContext( hThread: HANDLE, lpContext: *const WOW64_CONTEXT, ) -> BOOL686 pub fn Wow64SetThreadContext( 687 hThread: HANDLE, 688 lpContext: *const WOW64_CONTEXT, 689 ) -> BOOL; Wow64GetThreadSelectorEntry( hThread: HANDLE, dwSelector: DWORD, lpSelectorEntry: PWOW64_LDT_ENTRY, ) -> BOOL690 pub fn Wow64GetThreadSelectorEntry( 691 hThread: HANDLE, 692 dwSelector: DWORD, 693 lpSelectorEntry: PWOW64_LDT_ENTRY, 694 ) -> BOOL; Wow64SuspendThread( hThread: HANDLE, ) -> DWORD695 pub fn Wow64SuspendThread( 696 hThread: HANDLE, 697 ) -> DWORD; DebugSetProcessKillOnExit( KillOnExit: BOOL, ) -> BOOL698 pub fn DebugSetProcessKillOnExit( 699 KillOnExit: BOOL, 700 ) -> BOOL; DebugBreakProcess( Process: HANDLE, ) -> BOOL701 pub fn DebugBreakProcess( 702 Process: HANDLE, 703 ) -> BOOL; PulseEvent( hEvent: HANDLE, ) -> BOOL704 pub fn PulseEvent( 705 hEvent: HANDLE, 706 ) -> BOOL; GlobalDeleteAtom( nAtom: ATOM, ) -> ATOM707 pub fn GlobalDeleteAtom( 708 nAtom: ATOM, 709 ) -> ATOM; InitAtomTable( nSize: DWORD, ) -> BOOL710 pub fn InitAtomTable( 711 nSize: DWORD, 712 ) -> BOOL; DeleteAtom( nAtom: ATOM, ) -> ATOM713 pub fn DeleteAtom( 714 nAtom: ATOM, 715 ) -> ATOM; SetHandleCount( uNumber: UINT, ) -> UINT716 pub fn SetHandleCount( 717 uNumber: UINT, 718 ) -> UINT; RequestDeviceWakeup( hDevice: HANDLE, ) -> BOOL719 pub fn RequestDeviceWakeup( 720 hDevice: HANDLE, 721 ) -> BOOL; CancelDeviceWakeupRequest( hDevice: HANDLE, ) -> BOOL722 pub fn CancelDeviceWakeupRequest( 723 hDevice: HANDLE, 724 ) -> BOOL; GetDevicePowerState( hDevice: HANDLE, pfOn: *mut BOOL, ) -> BOOL725 pub fn GetDevicePowerState( 726 hDevice: HANDLE, 727 pfOn: *mut BOOL, 728 ) -> BOOL; SetMessageWaitingIndicator( hMsgIndicator: HANDLE, ulMsgCount: ULONG, ) -> BOOL729 pub fn SetMessageWaitingIndicator( 730 hMsgIndicator: HANDLE, 731 ulMsgCount: ULONG, 732 ) -> BOOL; SetFileShortNameA( hFile: HANDLE, lpShortName: LPCSTR, ) -> BOOL733 pub fn SetFileShortNameA( 734 hFile: HANDLE, 735 lpShortName: LPCSTR, 736 ) -> BOOL; SetFileShortNameW( hFile: HANDLE, lpShortName: LPCWSTR, ) -> BOOL737 pub fn SetFileShortNameW( 738 hFile: HANDLE, 739 lpShortName: LPCWSTR, 740 ) -> BOOL; 741 } 742 pub const HANDLE_FLAG_INHERIT: DWORD = 0x00000001; 743 pub const HANDLE_FLAG_PROTECT_FROM_CLOSE: DWORD = 0x00000002; 744 extern "system" { LoadModule( lpModuleName: LPCSTR, lpParameterBlock: LPVOID, ) -> DWORD745 pub fn LoadModule( 746 lpModuleName: LPCSTR, 747 lpParameterBlock: LPVOID, 748 ) -> DWORD; WinExec( lpCmdLine: LPCSTR, uCmdShow: UINT, ) -> UINT749 pub fn WinExec( 750 lpCmdLine: LPCSTR, 751 uCmdShow: UINT, 752 ) -> UINT; 753 // ClearCommBreak 754 // ClearCommError 755 // SetupComm 756 // EscapeCommFunction 757 // GetCommConfig 758 // GetCommMask 759 // GetCommProperties 760 // GetCommModemStatus 761 // GetCommState 762 // GetCommTimeouts 763 // PurgeComm 764 // SetCommBreak 765 // SetCommConfig 766 // SetCommMask 767 // SetCommState 768 // SetCommTimeouts 769 // TransmitCommChar 770 // WaitCommEvent SetTapePosition( hDevice: HANDLE, dwPositionMethod: DWORD, dwPartition: DWORD, dwOffsetLow: DWORD, dwOffsetHigh: DWORD, bImmediate: BOOL, ) -> DWORD771 pub fn SetTapePosition( 772 hDevice: HANDLE, 773 dwPositionMethod: DWORD, 774 dwPartition: DWORD, 775 dwOffsetLow: DWORD, 776 dwOffsetHigh: DWORD, 777 bImmediate: BOOL, 778 ) -> DWORD; GetTapePosition( hDevice: HANDLE, dwPositionType: DWORD, lpdwPartition: LPDWORD, lpdwOffsetLow: LPDWORD, lpdwOffsetHigh: LPDWORD, ) -> DWORD779 pub fn GetTapePosition( 780 hDevice: HANDLE, 781 dwPositionType: DWORD, 782 lpdwPartition: LPDWORD, 783 lpdwOffsetLow: LPDWORD, 784 lpdwOffsetHigh: LPDWORD, 785 ) -> DWORD; PrepareTape( hDevice: HANDLE, dwOperation: DWORD, bImmediate: BOOL, ) -> DWORD786 pub fn PrepareTape( 787 hDevice: HANDLE, 788 dwOperation: DWORD, 789 bImmediate: BOOL, 790 ) -> DWORD; EraseTape( hDevice: HANDLE, dwEraseType: DWORD, bImmediate: BOOL, ) -> DWORD791 pub fn EraseTape( 792 hDevice: HANDLE, 793 dwEraseType: DWORD, 794 bImmediate: BOOL, 795 ) -> DWORD; CreateTapePartition( hDevice: HANDLE, dwPartitionMethod: DWORD, dwCount: DWORD, dwSize: DWORD, ) -> DWORD796 pub fn CreateTapePartition( 797 hDevice: HANDLE, 798 dwPartitionMethod: DWORD, 799 dwCount: DWORD, 800 dwSize: DWORD, 801 ) -> DWORD; WriteTapemark( hDevice: HANDLE, dwTapemarkType: DWORD, dwTapemarkCount: DWORD, bImmediate: BOOL, ) -> DWORD802 pub fn WriteTapemark( 803 hDevice: HANDLE, 804 dwTapemarkType: DWORD, 805 dwTapemarkCount: DWORD, 806 bImmediate: BOOL, 807 ) -> DWORD; GetTapeStatus( hDevice: HANDLE, ) -> DWORD808 pub fn GetTapeStatus( 809 hDevice: HANDLE, 810 ) -> DWORD; GetTapeParameters( hDevice: HANDLE, dwOperation: DWORD, lpdwSize: LPDWORD, lpTapeInformation: LPVOID, ) -> DWORD811 pub fn GetTapeParameters( 812 hDevice: HANDLE, 813 dwOperation: DWORD, 814 lpdwSize: LPDWORD, 815 lpTapeInformation: LPVOID, 816 ) -> DWORD; SetTapeParameters( hDevice: HANDLE, dwOperation: DWORD, lpTapeInformation: LPVOID, ) -> DWORD817 pub fn SetTapeParameters( 818 hDevice: HANDLE, 819 dwOperation: DWORD, 820 lpTapeInformation: LPVOID, 821 ) -> DWORD; MulDiv( nNumber: c_int, nNumerator: c_int, nDenominator: c_int, ) -> c_int822 pub fn MulDiv( 823 nNumber: c_int, 824 nNumerator: c_int, 825 nDenominator: c_int, 826 ) -> c_int; 827 } 828 ENUM!{enum DEP_SYSTEM_POLICY_TYPE { 829 DEPPolicyAlwaysOff = 0, 830 DEPPolicyAlwaysOn, 831 DEPPolicyOptIn, 832 DEPPolicyOptOut, 833 DEPTotalPolicyCount, 834 }} 835 extern "system" { GetSystemDEPPolicy() -> DEP_SYSTEM_POLICY_TYPE836 pub fn GetSystemDEPPolicy() -> DEP_SYSTEM_POLICY_TYPE; GetSystemRegistryQuota( pdwQuotaAllowed: PDWORD, pdwQuotaUsed: PDWORD, ) -> BOOL837 pub fn GetSystemRegistryQuota( 838 pdwQuotaAllowed: PDWORD, 839 pdwQuotaUsed: PDWORD, 840 ) -> BOOL; FileTimeToDosDateTime( lpFileTime: *const FILETIME, lpFatDate: LPWORD, lpFatTime: LPWORD, ) -> BOOL841 pub fn FileTimeToDosDateTime( 842 lpFileTime: *const FILETIME, 843 lpFatDate: LPWORD, 844 lpFatTime: LPWORD, 845 ) -> BOOL; DosDateTimeToFileTime( wFatDate: WORD, wFatTime: WORD, lpFileTime: LPFILETIME, ) -> BOOL846 pub fn DosDateTimeToFileTime( 847 wFatDate: WORD, 848 wFatTime: WORD, 849 lpFileTime: LPFILETIME, 850 ) -> BOOL; FormatMessageA( dwFlags: DWORD, lpSource: LPCVOID, dwMessageId: DWORD, dwLanguageId: DWORD, lpBuffer: LPSTR, nSize: DWORD, Arguments: *mut va_list, ) -> DWORD851 pub fn FormatMessageA( 852 dwFlags: DWORD, 853 lpSource: LPCVOID, 854 dwMessageId: DWORD, 855 dwLanguageId: DWORD, 856 lpBuffer: LPSTR, 857 nSize: DWORD, 858 Arguments: *mut va_list, 859 ) -> DWORD; FormatMessageW( dwFlags: DWORD, lpSource: LPCVOID, dwMessageId: DWORD, dwLanguageId: DWORD, lpBuffer: LPWSTR, nSize: DWORD, Arguments: *mut va_list, ) -> DWORD860 pub fn FormatMessageW( 861 dwFlags: DWORD, 862 lpSource: LPCVOID, 863 dwMessageId: DWORD, 864 dwLanguageId: DWORD, 865 lpBuffer: LPWSTR, 866 nSize: DWORD, 867 Arguments: *mut va_list, 868 ) -> DWORD; 869 } 870 pub const FORMAT_MESSAGE_IGNORE_INSERTS: DWORD = 0x00000200; 871 pub const FORMAT_MESSAGE_FROM_STRING: DWORD = 0x00000400; 872 pub const FORMAT_MESSAGE_FROM_HMODULE: DWORD = 0x00000800; 873 pub const FORMAT_MESSAGE_FROM_SYSTEM: DWORD = 0x00001000; 874 pub const FORMAT_MESSAGE_ARGUMENT_ARRAY: DWORD = 0x00002000; 875 pub const FORMAT_MESSAGE_MAX_WIDTH_MASK: DWORD = 0x000000FF; 876 pub const FORMAT_MESSAGE_ALLOCATE_BUFFER: DWORD = 0x00000100; 877 extern "system" { CreateMailslotA( lpName: LPCSTR, nMaxMessageSize: DWORD, lReadTimeout: DWORD, lpSecurityAttributes: LPSECURITY_ATTRIBUTES, ) -> HANDLE878 pub fn CreateMailslotA( 879 lpName: LPCSTR, 880 nMaxMessageSize: DWORD, 881 lReadTimeout: DWORD, 882 lpSecurityAttributes: LPSECURITY_ATTRIBUTES, 883 ) -> HANDLE; CreateMailslotW( lpName: LPCWSTR, nMaxMessageSize: DWORD, lReadTimeout: DWORD, lpSecurityAttributes: LPSECURITY_ATTRIBUTES, ) -> HANDLE884 pub fn CreateMailslotW( 885 lpName: LPCWSTR, 886 nMaxMessageSize: DWORD, 887 lReadTimeout: DWORD, 888 lpSecurityAttributes: LPSECURITY_ATTRIBUTES, 889 ) -> HANDLE; GetMailslotInfo( hMailslot: HANDLE, lpMaxMessageSize: LPDWORD, lpNextSize: LPDWORD, lpMessageCount: LPDWORD, lpReadTimeout: LPDWORD, ) -> BOOL890 pub fn GetMailslotInfo( 891 hMailslot: HANDLE, 892 lpMaxMessageSize: LPDWORD, 893 lpNextSize: LPDWORD, 894 lpMessageCount: LPDWORD, 895 lpReadTimeout: LPDWORD, 896 ) -> BOOL; SetMailslotInfo( hMailslot: HANDLE, lReadTimeout: DWORD, ) -> BOOL897 pub fn SetMailslotInfo( 898 hMailslot: HANDLE, 899 lReadTimeout: DWORD, 900 ) -> BOOL; 901 // pub fn EncryptFileA(); 902 // pub fn EncryptFileW(); 903 // pub fn DecryptFileA(); 904 // pub fn DecryptFileW(); 905 // pub fn FileEncryptionStatusA(); 906 // pub fn FileEncryptionStatusW(); 907 // pub fn OpenEncryptedFileRawA(); 908 // pub fn OpenEncryptedFileRawW(); 909 // pub fn ReadEncryptedFileRaw(); 910 // pub fn WriteEncryptedFileRaw(); 911 // pub fn CloseEncryptedFileRaw(); lstrcmpA( lpString1: LPCSTR, lpString2: LPCSTR, ) -> c_int912 pub fn lstrcmpA( 913 lpString1: LPCSTR, 914 lpString2: LPCSTR, 915 ) -> c_int; lstrcmpW( lpString1: LPCWSTR, lpString2: LPCWSTR, ) -> c_int916 pub fn lstrcmpW( 917 lpString1: LPCWSTR, 918 lpString2: LPCWSTR, 919 ) -> c_int; lstrcmpiA( lpString1: LPCSTR, lpString2: LPCSTR, ) -> c_int920 pub fn lstrcmpiA( 921 lpString1: LPCSTR, 922 lpString2: LPCSTR, 923 ) -> c_int; lstrcmpiW( lpString1: LPCWSTR, lpString2: LPCWSTR, ) -> c_int924 pub fn lstrcmpiW( 925 lpString1: LPCWSTR, 926 lpString2: LPCWSTR, 927 ) -> c_int; lstrcpynA( lpString1: LPSTR, lpString2: LPCSTR, iMaxLength: c_int, ) -> LPSTR928 pub fn lstrcpynA( 929 lpString1: LPSTR, 930 lpString2: LPCSTR, 931 iMaxLength: c_int, 932 ) -> LPSTR; lstrcpynW( lpString1: LPWSTR, lpString2: LPCWSTR, iMaxLength: c_int, ) -> LPWSTR933 pub fn lstrcpynW( 934 lpString1: LPWSTR, 935 lpString2: LPCWSTR, 936 iMaxLength: c_int, 937 ) -> LPWSTR; lstrcpyA( lpString1: LPSTR, lpString2: LPCSTR, ) -> LPSTR938 pub fn lstrcpyA( 939 lpString1: LPSTR, 940 lpString2: LPCSTR, 941 ) -> LPSTR; lstrcpyW( lpString1: LPWSTR, lpString2: LPCWSTR, ) -> LPWSTR942 pub fn lstrcpyW( 943 lpString1: LPWSTR, 944 lpString2: LPCWSTR, 945 ) -> LPWSTR; lstrcatA( lpString1: LPSTR, lpString2: LPCSTR, ) -> LPSTR946 pub fn lstrcatA( 947 lpString1: LPSTR, 948 lpString2: LPCSTR, 949 ) -> LPSTR; lstrcatW( lpString1: LPWSTR, lpString2: LPCWSTR, ) -> LPWSTR950 pub fn lstrcatW( 951 lpString1: LPWSTR, 952 lpString2: LPCWSTR, 953 ) -> LPWSTR; lstrlenA( lpString: LPCSTR, ) -> c_int954 pub fn lstrlenA( 955 lpString: LPCSTR, 956 ) -> c_int; lstrlenW( lpString: LPCWSTR, ) -> c_int957 pub fn lstrlenW( 958 lpString: LPCWSTR, 959 ) -> c_int; OpenFile( lpFileName: LPCSTR, lpReOpenBuff: LPOFSTRUCT, uStyle: UINT, ) -> HFILE960 pub fn OpenFile( 961 lpFileName: LPCSTR, 962 lpReOpenBuff: LPOFSTRUCT, 963 uStyle: UINT, 964 ) -> HFILE; _lopen( lpPathName: LPCSTR, iReadWrite: c_int, ) -> HFILE965 pub fn _lopen( 966 lpPathName: LPCSTR, 967 iReadWrite: c_int, 968 ) -> HFILE; _lcreat( lpPathName: LPCSTR, iAttrubute: c_int, ) -> HFILE969 pub fn _lcreat( 970 lpPathName: LPCSTR, 971 iAttrubute: c_int, 972 ) -> HFILE; _lread( hFile: HFILE, lpBuffer: LPVOID, uBytes: UINT, ) -> UINT973 pub fn _lread( 974 hFile: HFILE, 975 lpBuffer: LPVOID, 976 uBytes: UINT, 977 ) -> UINT; _lwrite( hFile: HFILE, lpBuffer: LPCCH, uBytes: UINT, ) -> UINT978 pub fn _lwrite( 979 hFile: HFILE, 980 lpBuffer: LPCCH, 981 uBytes: UINT, 982 ) -> UINT; _hread( hFile: HFILE, lpBuffer: LPVOID, lBytes: c_long, ) -> c_long983 pub fn _hread( 984 hFile: HFILE, 985 lpBuffer: LPVOID, 986 lBytes: c_long, 987 ) -> c_long; _hwrite( hFile: HFILE, lpBuffer: LPCCH, lBytes: c_long, ) -> c_long988 pub fn _hwrite( 989 hFile: HFILE, 990 lpBuffer: LPCCH, 991 lBytes: c_long, 992 ) -> c_long; _lclose( hFile: HFILE, ) -> HFILE993 pub fn _lclose( 994 hFile: HFILE, 995 ) -> HFILE; _llseek( hFile: HFILE, lOffset: LONG, iOrigin: c_int, ) -> LONG996 pub fn _llseek( 997 hFile: HFILE, 998 lOffset: LONG, 999 iOrigin: c_int, 1000 ) -> LONG; 1001 // pub fn IsTextUnicode(); 1002 // pub fn SignalObjectAndWait(); BackupRead( hFile: HANDLE, lpBuffer: LPBYTE, nNumberOfBytesToRead: DWORD, lpNumberOfBytesRead: LPDWORD, bAbort: BOOL, bProcessSecurity: BOOL, lpContext: *mut LPVOID, ) -> BOOL1003 pub fn BackupRead( 1004 hFile: HANDLE, 1005 lpBuffer: LPBYTE, 1006 nNumberOfBytesToRead: DWORD, 1007 lpNumberOfBytesRead: LPDWORD, 1008 bAbort: BOOL, 1009 bProcessSecurity: BOOL, 1010 lpContext: *mut LPVOID, 1011 ) -> BOOL; BackupSeek( hFile: HANDLE, dwLowBytesToSeek: DWORD, dwHighBytesToSeek: DWORD, lpdwLowByteSeeked: LPDWORD, lpdwHighByteSeeked: LPDWORD, lpContext: *mut LPVOID, ) -> BOOL1012 pub fn BackupSeek( 1013 hFile: HANDLE, 1014 dwLowBytesToSeek: DWORD, 1015 dwHighBytesToSeek: DWORD, 1016 lpdwLowByteSeeked: LPDWORD, 1017 lpdwHighByteSeeked: LPDWORD, 1018 lpContext: *mut LPVOID, 1019 ) -> BOOL; BackupWrite( hFile: HANDLE, lpBuffer: LPBYTE, nNumberOfBytesToWrite: DWORD, lpNumberOfBytesWritten: LPDWORD, bAbort: BOOL, bProcessSecurity: BOOL, lpContext: *mut LPVOID, ) -> BOOL1020 pub fn BackupWrite( 1021 hFile: HANDLE, 1022 lpBuffer: LPBYTE, 1023 nNumberOfBytesToWrite: DWORD, 1024 lpNumberOfBytesWritten: LPDWORD, 1025 bAbort: BOOL, 1026 bProcessSecurity: BOOL, 1027 lpContext: *mut LPVOID, 1028 ) -> BOOL; 1029 } 1030 //2886 1031 pub const STARTF_USESHOWWINDOW: DWORD = 0x00000001; 1032 pub const STARTF_USESIZE: DWORD = 0x00000002; 1033 pub const STARTF_USEPOSITION: DWORD = 0x00000004; 1034 pub const STARTF_USECOUNTCHARS: DWORD = 0x00000008; 1035 pub const STARTF_USEFILLATTRIBUTE: DWORD = 0x00000010; 1036 pub const STARTF_RUNFULLSCREEN: DWORD = 0x00000020; 1037 pub const STARTF_FORCEONFEEDBACK: DWORD = 0x00000040; 1038 pub const STARTF_FORCEOFFFEEDBACK: DWORD = 0x00000080; 1039 pub const STARTF_USESTDHANDLES: DWORD = 0x00000100; 1040 pub const STARTF_USEHOTKEY: DWORD = 0x00000200; 1041 pub const STARTF_TITLEISLINKNAME: DWORD = 0x00000800; 1042 pub const STARTF_TITLEISAPPID: DWORD = 0x00001000; 1043 pub const STARTF_PREVENTPINNING: DWORD = 0x00002000; 1044 pub const STARTF_UNTRUSTEDSOURCE: DWORD = 0x00008000; 1045 STRUCT!{struct STARTUPINFOEXA { 1046 StartupInfo: STARTUPINFOA, 1047 lpAttributeList: LPPROC_THREAD_ATTRIBUTE_LIST, 1048 }} 1049 pub type LPSTARTUPINFOEXA = *mut STARTUPINFOEXA; 1050 STRUCT!{struct STARTUPINFOEXW { 1051 StartupInfo: STARTUPINFOW, 1052 lpAttributeList: LPPROC_THREAD_ATTRIBUTE_LIST, 1053 }} 1054 pub type LPSTARTUPINFOEXW = *mut STARTUPINFOEXW; 1055 extern "system" { OpenMutexA( dwDesiredAccess: DWORD, bInheritHandle: BOOL, lpName: LPCSTR, ) -> HANDLE1056 pub fn OpenMutexA( 1057 dwDesiredAccess: DWORD, 1058 bInheritHandle: BOOL, 1059 lpName: LPCSTR, 1060 ) -> HANDLE; CreateSemaphoreA( lpSemaphoreAttributes: LPSECURITY_ATTRIBUTES, lInitialCount: LONG, lMaximumCount: LONG, lpName: LPCSTR, ) -> HANDLE1061 pub fn CreateSemaphoreA( 1062 lpSemaphoreAttributes: LPSECURITY_ATTRIBUTES, 1063 lInitialCount: LONG, 1064 lMaximumCount: LONG, 1065 lpName: LPCSTR, 1066 ) -> HANDLE; OpenSemaphoreA( dwDesiredAccess: DWORD, bInheritHandle: BOOL, lpName: LPCSTR, ) -> HANDLE1067 pub fn OpenSemaphoreA( 1068 dwDesiredAccess: DWORD, 1069 bInheritHandle: BOOL, 1070 lpName: LPCSTR, 1071 ) -> HANDLE; CreateWaitableTimerA( lpTimerAttributes: LPSECURITY_ATTRIBUTES, bManualReset: BOOL, lpTimerName: LPCSTR, ) -> HANDLE1072 pub fn CreateWaitableTimerA( 1073 lpTimerAttributes: LPSECURITY_ATTRIBUTES, 1074 bManualReset: BOOL, 1075 lpTimerName: LPCSTR, 1076 ) -> HANDLE; OpenWaitableTimerA( dwDesiredAccess: DWORD, bInheritHandle: BOOL, lpTimerName: LPCSTR, ) -> HANDLE1077 pub fn OpenWaitableTimerA( 1078 dwDesiredAccess: DWORD, 1079 bInheritHandle: BOOL, 1080 lpTimerName: LPCSTR, 1081 ) -> HANDLE; CreateSemaphoreExA( lpSemaphoreAttributes: LPSECURITY_ATTRIBUTES, lInitialCount: LONG, lMaximumCount: LONG, lpName: LPCSTR, dwFlags: DWORD, dwDesiredAccess: DWORD, ) -> HANDLE1082 pub fn CreateSemaphoreExA( 1083 lpSemaphoreAttributes: LPSECURITY_ATTRIBUTES, 1084 lInitialCount: LONG, 1085 lMaximumCount: LONG, 1086 lpName: LPCSTR, 1087 dwFlags: DWORD, 1088 dwDesiredAccess: DWORD, 1089 ) -> HANDLE; CreateWaitableTimerExA( lpTimerAttributes: LPSECURITY_ATTRIBUTES, lpTimerName: LPCSTR, dwFlags: DWORD, dwDesiredAccess: DWORD, ) -> HANDLE1090 pub fn CreateWaitableTimerExA( 1091 lpTimerAttributes: LPSECURITY_ATTRIBUTES, 1092 lpTimerName: LPCSTR, 1093 dwFlags: DWORD, 1094 dwDesiredAccess: DWORD, 1095 ) -> HANDLE; CreateFileMappingA( hFile: HANDLE, lpAttributes: LPSECURITY_ATTRIBUTES, flProtect: DWORD, dwMaximumSizeHigh: DWORD, dwMaximumSizeLow: DWORD, lpName: LPCSTR, ) -> HANDLE1096 pub fn CreateFileMappingA( 1097 hFile: HANDLE, 1098 lpAttributes: LPSECURITY_ATTRIBUTES, 1099 flProtect: DWORD, 1100 dwMaximumSizeHigh: DWORD, 1101 dwMaximumSizeLow: DWORD, 1102 lpName: LPCSTR, 1103 ) -> HANDLE; CreateFileMappingNumaA( hFile: HANDLE, lpFileMappingAttributes: LPSECURITY_ATTRIBUTES, flProtect: DWORD, dwMaximumSizeHigh: DWORD, dwMaximumSizeLow: DWORD, lpName: LPCSTR, nndPreferred: DWORD, ) -> HANDLE1104 pub fn CreateFileMappingNumaA( 1105 hFile: HANDLE, 1106 lpFileMappingAttributes: LPSECURITY_ATTRIBUTES, 1107 flProtect: DWORD, 1108 dwMaximumSizeHigh: DWORD, 1109 dwMaximumSizeLow: DWORD, 1110 lpName: LPCSTR, 1111 nndPreferred: DWORD, 1112 ) -> HANDLE; OpenFileMappingA( dwDesiredAccess: DWORD, bInheritHandle: BOOL, lpName: LPCSTR, ) -> HANDLE1113 pub fn OpenFileMappingA( 1114 dwDesiredAccess: DWORD, 1115 bInheritHandle: BOOL, 1116 lpName: LPCSTR, 1117 ) -> HANDLE; GetLogicalDriveStringsA( nBufferLength: DWORD, lpBuffer: LPSTR, ) -> DWORD1118 pub fn GetLogicalDriveStringsA( 1119 nBufferLength: DWORD, 1120 lpBuffer: LPSTR, 1121 ) -> DWORD; LoadPackagedLibrary( lpwLibFileName: LPCWSTR, Reserved: DWORD, ) -> HMODULE1122 pub fn LoadPackagedLibrary( 1123 lpwLibFileName: LPCWSTR, 1124 Reserved: DWORD, 1125 ) -> HMODULE; QueryFullProcessImageNameA( hProcess: HANDLE, dwFlags: DWORD, lpExeName: LPSTR, lpdwSize: PDWORD, ) -> BOOL1126 pub fn QueryFullProcessImageNameA( 1127 hProcess: HANDLE, 1128 dwFlags: DWORD, 1129 lpExeName: LPSTR, 1130 lpdwSize: PDWORD, 1131 ) -> BOOL; QueryFullProcessImageNameW( hProcess: HANDLE, dwFlags: DWORD, lpExeName: LPWSTR, lpdwSize: PDWORD, ) -> BOOL1132 pub fn QueryFullProcessImageNameW( 1133 hProcess: HANDLE, 1134 dwFlags: DWORD, 1135 lpExeName: LPWSTR, 1136 lpdwSize: PDWORD, 1137 ) -> BOOL; 1138 } 1139 //3233 1140 extern "system" { GetStartupInfoA( lpStartupInfo: LPSTARTUPINFOA, )1141 pub fn GetStartupInfoA( 1142 lpStartupInfo: LPSTARTUPINFOA, 1143 ); GetFirmwareEnvironmentVariableA( lpName: LPCSTR, lpGuid: LPCSTR, pBuffer: PVOID, nSize: DWORD, ) -> DWORD1144 pub fn GetFirmwareEnvironmentVariableA( 1145 lpName: LPCSTR, 1146 lpGuid: LPCSTR, 1147 pBuffer: PVOID, 1148 nSize: DWORD, 1149 ) -> DWORD; GetFirmwareEnvironmentVariableW( lpName: LPCWSTR, lpGuid: LPCWSTR, pBuffer: PVOID, nSize: DWORD, ) -> DWORD1150 pub fn GetFirmwareEnvironmentVariableW( 1151 lpName: LPCWSTR, 1152 lpGuid: LPCWSTR, 1153 pBuffer: PVOID, 1154 nSize: DWORD, 1155 ) -> DWORD; GetFirmwareEnvironmentVariableExA( lpName: LPCSTR, lpGuid: LPCSTR, pBuffer: PVOID, nSize: DWORD, pdwAttribubutes: PDWORD, ) -> DWORD1156 pub fn GetFirmwareEnvironmentVariableExA( 1157 lpName: LPCSTR, 1158 lpGuid: LPCSTR, 1159 pBuffer: PVOID, 1160 nSize: DWORD, 1161 pdwAttribubutes: PDWORD, 1162 ) -> DWORD; GetFirmwareEnvironmentVariableExW( lpName: LPCWSTR, lpGuid: LPCWSTR, pBuffer: PVOID, nSize: DWORD, pdwAttribubutes: PDWORD, ) -> DWORD1163 pub fn GetFirmwareEnvironmentVariableExW( 1164 lpName: LPCWSTR, 1165 lpGuid: LPCWSTR, 1166 pBuffer: PVOID, 1167 nSize: DWORD, 1168 pdwAttribubutes: PDWORD, 1169 ) -> DWORD; SetFirmwareEnvironmentVariableA( lpName: LPCSTR, lpGuid: LPCSTR, pValue: PVOID, nSize: DWORD, ) -> BOOL1170 pub fn SetFirmwareEnvironmentVariableA( 1171 lpName: LPCSTR, 1172 lpGuid: LPCSTR, 1173 pValue: PVOID, 1174 nSize: DWORD, 1175 ) -> BOOL; SetFirmwareEnvironmentVariableW( lpName: LPCWSTR, lpGuid: LPCWSTR, pValue: PVOID, nSize: DWORD, ) -> BOOL1176 pub fn SetFirmwareEnvironmentVariableW( 1177 lpName: LPCWSTR, 1178 lpGuid: LPCWSTR, 1179 pValue: PVOID, 1180 nSize: DWORD, 1181 ) -> BOOL; SetFirmwareEnvironmentVariableExA( lpName: LPCSTR, lpGuid: LPCSTR, pValue: PVOID, nSize: DWORD, dwAttributes: DWORD, ) -> BOOL1182 pub fn SetFirmwareEnvironmentVariableExA( 1183 lpName: LPCSTR, 1184 lpGuid: LPCSTR, 1185 pValue: PVOID, 1186 nSize: DWORD, 1187 dwAttributes: DWORD, 1188 ) -> BOOL; SetFirmwareEnvironmentVariableExW( lpName: LPCWSTR, lpGuid: LPCWSTR, pValue: PVOID, nSize: DWORD, dwAttributes: DWORD, ) -> BOOL1189 pub fn SetFirmwareEnvironmentVariableExW( 1190 lpName: LPCWSTR, 1191 lpGuid: LPCWSTR, 1192 pValue: PVOID, 1193 nSize: DWORD, 1194 dwAttributes: DWORD, 1195 ) -> BOOL; GetFirmwareType( FirmwareType: PFIRMWARE_TYPE, ) -> BOOL1196 pub fn GetFirmwareType( 1197 FirmwareType: PFIRMWARE_TYPE, 1198 ) -> BOOL; IsNativeVhdBoot( NativeVhdBoot: PBOOL, ) -> BOOL1199 pub fn IsNativeVhdBoot( 1200 NativeVhdBoot: PBOOL, 1201 ) -> BOOL; FindResourceA( hModule: HMODULE, lpName: LPCSTR, lpType: LPCSTR, ) -> HRSRC1202 pub fn FindResourceA( 1203 hModule: HMODULE, 1204 lpName: LPCSTR, 1205 lpType: LPCSTR, 1206 ) -> HRSRC; FindResourceExA( hModule: HMODULE, lpName: LPCSTR, lpType: LPCSTR, wLanguage: WORD, ) -> HRSRC1207 pub fn FindResourceExA( 1208 hModule: HMODULE, 1209 lpName: LPCSTR, 1210 lpType: LPCSTR, 1211 wLanguage: WORD, 1212 ) -> HRSRC; EnumResourceTypesA( hModule: HMODULE, lpEnumFunc: ENUMRESTYPEPROCA, lParam: LONG_PTR, ) -> BOOL1213 pub fn EnumResourceTypesA( 1214 hModule: HMODULE, 1215 lpEnumFunc: ENUMRESTYPEPROCA, 1216 lParam: LONG_PTR, 1217 ) -> BOOL; EnumResourceTypesW( hModule: HMODULE, lpEnumFunc: ENUMRESTYPEPROCW, lParam: LONG_PTR, ) -> BOOL1218 pub fn EnumResourceTypesW( 1219 hModule: HMODULE, 1220 lpEnumFunc: ENUMRESTYPEPROCW, 1221 lParam: LONG_PTR, 1222 ) -> BOOL; EnumResourceNamesA( hModule: HMODULE, lpType: LPCSTR, lpEnumFunc: ENUMRESNAMEPROCA, lParam: LONG_PTR, ) -> BOOL1223 pub fn EnumResourceNamesA( 1224 hModule: HMODULE, 1225 lpType: LPCSTR, 1226 lpEnumFunc: ENUMRESNAMEPROCA, 1227 lParam: LONG_PTR, 1228 ) -> BOOL; EnumResourceLanguagesA( hModule: HMODULE, lpType: LPCSTR, lpName: LPCSTR, lpEnumFunc: ENUMRESLANGPROCA, lParam: LONG_PTR, ) -> BOOL1229 pub fn EnumResourceLanguagesA( 1230 hModule: HMODULE, 1231 lpType: LPCSTR, 1232 lpName: LPCSTR, 1233 lpEnumFunc: ENUMRESLANGPROCA, 1234 lParam: LONG_PTR, 1235 ) -> BOOL; EnumResourceLanguagesW( hModule: HMODULE, lpType: LPCWSTR, lpName: LPCWSTR, lpEnumFunc: ENUMRESLANGPROCW, lParam: LONG_PTR, ) -> BOOL1236 pub fn EnumResourceLanguagesW( 1237 hModule: HMODULE, 1238 lpType: LPCWSTR, 1239 lpName: LPCWSTR, 1240 lpEnumFunc: ENUMRESLANGPROCW, 1241 lParam: LONG_PTR, 1242 ) -> BOOL; BeginUpdateResourceA( pFileName: LPCSTR, bDeleteExistingResources: BOOL, ) -> HANDLE1243 pub fn BeginUpdateResourceA( 1244 pFileName: LPCSTR, 1245 bDeleteExistingResources: BOOL, 1246 ) -> HANDLE; BeginUpdateResourceW( pFileName: LPCWSTR, bDeleteExistingResources: BOOL, ) -> HANDLE1247 pub fn BeginUpdateResourceW( 1248 pFileName: LPCWSTR, 1249 bDeleteExistingResources: BOOL, 1250 ) -> HANDLE; UpdateResourceA( hUpdate: HANDLE, lpType: LPCSTR, lpName: LPCSTR, wLanguage: WORD, lpData: LPVOID, cb: DWORD, ) -> BOOL1251 pub fn UpdateResourceA( 1252 hUpdate: HANDLE, 1253 lpType: LPCSTR, 1254 lpName: LPCSTR, 1255 wLanguage: WORD, 1256 lpData: LPVOID, 1257 cb: DWORD, 1258 ) -> BOOL; UpdateResourceW( hUpdate: HANDLE, lpType: LPCWSTR, lpName: LPCWSTR, wLanguage: WORD, lpData: LPVOID, cb: DWORD, ) -> BOOL1259 pub fn UpdateResourceW( 1260 hUpdate: HANDLE, 1261 lpType: LPCWSTR, 1262 lpName: LPCWSTR, 1263 wLanguage: WORD, 1264 lpData: LPVOID, 1265 cb: DWORD, 1266 ) -> BOOL; EndUpdateResourceA( hUpdate: HANDLE, fDiscard: BOOL, ) -> BOOL1267 pub fn EndUpdateResourceA( 1268 hUpdate: HANDLE, 1269 fDiscard: BOOL, 1270 ) -> BOOL; EndUpdateResourceW( hUpdate: HANDLE, fDiscard: BOOL, ) -> BOOL1271 pub fn EndUpdateResourceW( 1272 hUpdate: HANDLE, 1273 fDiscard: BOOL, 1274 ) -> BOOL; GlobalAddAtomA( lpString: LPCSTR, ) -> ATOM1275 pub fn GlobalAddAtomA( 1276 lpString: LPCSTR, 1277 ) -> ATOM; GlobalAddAtomW( lpString: LPCWSTR, ) -> ATOM1278 pub fn GlobalAddAtomW( 1279 lpString: LPCWSTR, 1280 ) -> ATOM; GlobalAddAtomExA( lpString: LPCSTR, Flags: DWORD, ) -> ATOM1281 pub fn GlobalAddAtomExA( 1282 lpString: LPCSTR, 1283 Flags: DWORD, 1284 ) -> ATOM; GlobalAddAtomExW( lpString: LPCWSTR, Flags: DWORD, ) -> ATOM1285 pub fn GlobalAddAtomExW( 1286 lpString: LPCWSTR, 1287 Flags: DWORD, 1288 ) -> ATOM; GlobalFindAtomA( lpString: LPCSTR, ) -> ATOM1289 pub fn GlobalFindAtomA( 1290 lpString: LPCSTR, 1291 ) -> ATOM; GlobalFindAtomW( lpString: LPCWSTR, ) -> ATOM1292 pub fn GlobalFindAtomW( 1293 lpString: LPCWSTR, 1294 ) -> ATOM; GlobalGetAtomNameA( nAtom: ATOM, lpBuffer: LPSTR, nSize: c_int, ) -> UINT1295 pub fn GlobalGetAtomNameA( 1296 nAtom: ATOM, 1297 lpBuffer: LPSTR, 1298 nSize: c_int, 1299 ) -> UINT; GlobalGetAtomNameW( nAtom: ATOM, lpBuffer: LPWSTR, nSize: c_int, ) -> UINT1300 pub fn GlobalGetAtomNameW( 1301 nAtom: ATOM, 1302 lpBuffer: LPWSTR, 1303 nSize: c_int, 1304 ) -> UINT; AddAtomA( lpString: LPCSTR, ) -> ATOM1305 pub fn AddAtomA( 1306 lpString: LPCSTR, 1307 ) -> ATOM; AddAtomW( lpString: LPCWSTR, ) -> ATOM1308 pub fn AddAtomW( 1309 lpString: LPCWSTR, 1310 ) -> ATOM; FindAtomA( lpString: LPCSTR, ) -> ATOM1311 pub fn FindAtomA( 1312 lpString: LPCSTR, 1313 ) -> ATOM; FindAtomW( lpString: LPCWSTR, ) -> ATOM1314 pub fn FindAtomW( 1315 lpString: LPCWSTR, 1316 ) -> ATOM; GetAtomNameA( nAtom: ATOM, lpBuffer: LPSTR, nSize: c_int, ) -> UINT1317 pub fn GetAtomNameA( 1318 nAtom: ATOM, 1319 lpBuffer: LPSTR, 1320 nSize: c_int, 1321 ) -> UINT; GetAtomNameW( nAtom: ATOM, lpBuffer: LPWSTR, nSize: c_int, ) -> UINT1322 pub fn GetAtomNameW( 1323 nAtom: ATOM, 1324 lpBuffer: LPWSTR, 1325 nSize: c_int, 1326 ) -> UINT; GetProfileIntA( lpAppName: LPCSTR, lpKeyName: LPCSTR, nDefault: INT, ) -> UINT1327 pub fn GetProfileIntA( 1328 lpAppName: LPCSTR, 1329 lpKeyName: LPCSTR, 1330 nDefault: INT, 1331 ) -> UINT; GetProfileIntW( lpAppName: LPCWSTR, lpKeyName: LPCWSTR, nDefault: INT, ) -> UINT1332 pub fn GetProfileIntW( 1333 lpAppName: LPCWSTR, 1334 lpKeyName: LPCWSTR, 1335 nDefault: INT, 1336 ) -> UINT; GetProfileStringA( lpAppName: LPCSTR, lpKeyName: LPCSTR, lpDefault: LPCSTR, lpReturnedString: LPSTR, nSize: DWORD, ) -> DWORD1337 pub fn GetProfileStringA( 1338 lpAppName: LPCSTR, 1339 lpKeyName: LPCSTR, 1340 lpDefault: LPCSTR, 1341 lpReturnedString: LPSTR, 1342 nSize: DWORD, 1343 ) -> DWORD; GetProfileStringW( lpAppName: LPCWSTR, lpKeyName: LPCWSTR, lpDefault: LPCWSTR, lpReturnedString: LPWSTR, nSize: DWORD, ) -> DWORD1344 pub fn GetProfileStringW( 1345 lpAppName: LPCWSTR, 1346 lpKeyName: LPCWSTR, 1347 lpDefault: LPCWSTR, 1348 lpReturnedString: LPWSTR, 1349 nSize: DWORD, 1350 ) -> DWORD; WriteProfileStringA( lpAppName: LPCSTR, lpKeyName: LPCSTR, lpString: LPCSTR, ) -> BOOL1351 pub fn WriteProfileStringA( 1352 lpAppName: LPCSTR, 1353 lpKeyName: LPCSTR, 1354 lpString: LPCSTR, 1355 ) -> BOOL; WriteProfileStringW( lpAppName: LPCWSTR, lpKeyName: LPCWSTR, lpString: LPCWSTR, ) -> BOOL1356 pub fn WriteProfileStringW( 1357 lpAppName: LPCWSTR, 1358 lpKeyName: LPCWSTR, 1359 lpString: LPCWSTR, 1360 ) -> BOOL; GetProfileSectionA( lpAppName: LPCSTR, lpReturnedString: LPSTR, nSize: DWORD, ) -> DWORD1361 pub fn GetProfileSectionA( 1362 lpAppName: LPCSTR, 1363 lpReturnedString: LPSTR, 1364 nSize: DWORD, 1365 ) -> DWORD; GetProfileSectionW( lpAppName: LPCWSTR, lpReturnedString: LPWSTR, nSize: DWORD, ) -> DWORD1366 pub fn GetProfileSectionW( 1367 lpAppName: LPCWSTR, 1368 lpReturnedString: LPWSTR, 1369 nSize: DWORD, 1370 ) -> DWORD; WriteProfileSectionA( lpAppName: LPCSTR, lpString: LPCSTR, ) -> BOOL1371 pub fn WriteProfileSectionA( 1372 lpAppName: LPCSTR, 1373 lpString: LPCSTR, 1374 ) -> BOOL; WriteProfileSectionW( lpAppName: LPCWSTR, lpString: LPCWSTR, ) -> BOOL1375 pub fn WriteProfileSectionW( 1376 lpAppName: LPCWSTR, 1377 lpString: LPCWSTR, 1378 ) -> BOOL; GetPrivateProfileIntA( lpAppName: LPCSTR, lpKeyName: LPCSTR, nDefault: INT, lpFileName: LPCSTR, ) -> UINT1379 pub fn GetPrivateProfileIntA( 1380 lpAppName: LPCSTR, 1381 lpKeyName: LPCSTR, 1382 nDefault: INT, 1383 lpFileName: LPCSTR, 1384 ) -> UINT; GetPrivateProfileIntW( lpAppName: LPCWSTR, lpKeyName: LPCWSTR, nDefault: INT, lpFileName: LPCWSTR, ) -> UINT1385 pub fn GetPrivateProfileIntW( 1386 lpAppName: LPCWSTR, 1387 lpKeyName: LPCWSTR, 1388 nDefault: INT, 1389 lpFileName: LPCWSTR, 1390 ) -> UINT; GetPrivateProfileStringA( lpAppName: LPCSTR, lpKeyName: LPCSTR, lpDefault: LPCSTR, lpReturnedString: LPSTR, nSize: DWORD, lpFileName: LPCSTR, ) -> DWORD1391 pub fn GetPrivateProfileStringA( 1392 lpAppName: LPCSTR, 1393 lpKeyName: LPCSTR, 1394 lpDefault: LPCSTR, 1395 lpReturnedString: LPSTR, 1396 nSize: DWORD, 1397 lpFileName: LPCSTR, 1398 ) -> DWORD; GetPrivateProfileStringW( lpAppName: LPCWSTR, lpKeyName: LPCWSTR, lpDefault: LPCWSTR, lpReturnedString: LPWSTR, nSize: DWORD, lpFileName: LPCWSTR, ) -> DWORD1399 pub fn GetPrivateProfileStringW( 1400 lpAppName: LPCWSTR, 1401 lpKeyName: LPCWSTR, 1402 lpDefault: LPCWSTR, 1403 lpReturnedString: LPWSTR, 1404 nSize: DWORD, 1405 lpFileName: LPCWSTR, 1406 ) -> DWORD; WritePrivateProfileStringA( lpAppName: LPCSTR, lpKeyName: LPCSTR, lpString: LPCSTR, lpFileName: LPCSTR, ) -> BOOL1407 pub fn WritePrivateProfileStringA( 1408 lpAppName: LPCSTR, 1409 lpKeyName: LPCSTR, 1410 lpString: LPCSTR, 1411 lpFileName: LPCSTR, 1412 ) -> BOOL; WritePrivateProfileStringW( lpAppName: LPCWSTR, lpKeyName: LPCWSTR, lpString: LPCWSTR, lpFileName: LPCWSTR, ) -> BOOL1413 pub fn WritePrivateProfileStringW( 1414 lpAppName: LPCWSTR, 1415 lpKeyName: LPCWSTR, 1416 lpString: LPCWSTR, 1417 lpFileName: LPCWSTR, 1418 ) -> BOOL; GetPrivateProfileSectionA( lpAppName: LPCSTR, lpReturnedString: LPSTR, nSize: DWORD, lpFileName: LPCSTR, ) -> DWORD1419 pub fn GetPrivateProfileSectionA( 1420 lpAppName: LPCSTR, 1421 lpReturnedString: LPSTR, 1422 nSize: DWORD, 1423 lpFileName: LPCSTR, 1424 ) -> DWORD; GetPrivateProfileSectionW( lpAppName: LPCWSTR, lpReturnedString: LPWSTR, nSize: DWORD, lpFileName: LPCWSTR, ) -> DWORD1425 pub fn GetPrivateProfileSectionW( 1426 lpAppName: LPCWSTR, 1427 lpReturnedString: LPWSTR, 1428 nSize: DWORD, 1429 lpFileName: LPCWSTR, 1430 ) -> DWORD; WritePrivateProfileSectionA( lpAppName: LPCSTR, lpString: LPCSTR, lpFileName: LPCSTR, ) -> BOOL1431 pub fn WritePrivateProfileSectionA( 1432 lpAppName: LPCSTR, 1433 lpString: LPCSTR, 1434 lpFileName: LPCSTR, 1435 ) -> BOOL; WritePrivateProfileSectionW( lpAppName: LPCWSTR, lpString: LPCWSTR, lpFileName: LPCWSTR, ) -> BOOL1436 pub fn WritePrivateProfileSectionW( 1437 lpAppName: LPCWSTR, 1438 lpString: LPCWSTR, 1439 lpFileName: LPCWSTR, 1440 ) -> BOOL; GetPrivateProfileSectionNamesA( lpszReturnBuffer: LPSTR, nSize: DWORD, lpFileName: LPCSTR, ) -> DWORD1441 pub fn GetPrivateProfileSectionNamesA( 1442 lpszReturnBuffer: LPSTR, 1443 nSize: DWORD, 1444 lpFileName: LPCSTR, 1445 ) -> DWORD; GetPrivateProfileSectionNamesW( lpszReturnBuffer: LPWSTR, nSize: DWORD, lpFileName: LPCWSTR, ) -> DWORD1446 pub fn GetPrivateProfileSectionNamesW( 1447 lpszReturnBuffer: LPWSTR, 1448 nSize: DWORD, 1449 lpFileName: LPCWSTR, 1450 ) -> DWORD; GetPrivateProfileStructA( lpszSection: LPCSTR, lpszKey: LPCSTR, lpStruct: LPVOID, uSizeStruct: UINT, szFile: LPCSTR, ) -> BOOL1451 pub fn GetPrivateProfileStructA( 1452 lpszSection: LPCSTR, 1453 lpszKey: LPCSTR, 1454 lpStruct: LPVOID, 1455 uSizeStruct: UINT, 1456 szFile: LPCSTR, 1457 ) -> BOOL; GetPrivateProfileStructW( lpszSection: LPCWSTR, lpszKey: LPCWSTR, lpStruct: LPVOID, uSizeStruct: UINT, szFile: LPCWSTR, ) -> BOOL1458 pub fn GetPrivateProfileStructW( 1459 lpszSection: LPCWSTR, 1460 lpszKey: LPCWSTR, 1461 lpStruct: LPVOID, 1462 uSizeStruct: UINT, 1463 szFile: LPCWSTR, 1464 ) -> BOOL; WritePrivateProfileStructA( lpszSection: LPCSTR, lpszKey: LPCSTR, lpStruct: LPVOID, uSizeStruct: UINT, szFile: LPCSTR, ) -> BOOL1465 pub fn WritePrivateProfileStructA( 1466 lpszSection: LPCSTR, 1467 lpszKey: LPCSTR, 1468 lpStruct: LPVOID, 1469 uSizeStruct: UINT, 1470 szFile: LPCSTR, 1471 ) -> BOOL; WritePrivateProfileStructW( lpszSection: LPCWSTR, lpszKey: LPCWSTR, lpStruct: LPVOID, uSizeStruct: UINT, szFile: LPCWSTR, ) -> BOOL1472 pub fn WritePrivateProfileStructW( 1473 lpszSection: LPCWSTR, 1474 lpszKey: LPCWSTR, 1475 lpStruct: LPVOID, 1476 uSizeStruct: UINT, 1477 szFile: LPCWSTR, 1478 ) -> BOOL; Wow64EnableWow64FsRedirection( Wow64FsEnableRedirection: BOOLEAN, ) -> BOOLEAN1479 pub fn Wow64EnableWow64FsRedirection( 1480 Wow64FsEnableRedirection: BOOLEAN, 1481 ) -> BOOLEAN; SetDllDirectoryA( lpPathName: LPCSTR, ) -> BOOL1482 pub fn SetDllDirectoryA( 1483 lpPathName: LPCSTR, 1484 ) -> BOOL; SetDllDirectoryW( lpPathName: LPCWSTR, ) -> BOOL1485 pub fn SetDllDirectoryW( 1486 lpPathName: LPCWSTR, 1487 ) -> BOOL; GetDllDirectoryA( nBufferLength: DWORD, lpBuffer: LPSTR, ) -> DWORD1488 pub fn GetDllDirectoryA( 1489 nBufferLength: DWORD, 1490 lpBuffer: LPSTR, 1491 ) -> DWORD; GetDllDirectoryW( nBufferLength: DWORD, lpBuffer: LPWSTR, ) -> DWORD1492 pub fn GetDllDirectoryW( 1493 nBufferLength: DWORD, 1494 lpBuffer: LPWSTR, 1495 ) -> DWORD; SetSearchPathMode( Flags: DWORD, ) -> BOOL1496 pub fn SetSearchPathMode( 1497 Flags: DWORD, 1498 ) -> BOOL; CreateDirectoryExA( lpTemplateDirectory: LPCSTR, lpNewDirectory: LPCSTR, lpSecurityAttributes: LPSECURITY_ATTRIBUTES, ) -> BOOL1499 pub fn CreateDirectoryExA( 1500 lpTemplateDirectory: LPCSTR, 1501 lpNewDirectory: LPCSTR, 1502 lpSecurityAttributes: LPSECURITY_ATTRIBUTES, 1503 ) -> BOOL; CreateDirectoryExW( lpTemplateDirectory: LPCWSTR, lpNewDirectory: LPCWSTR, lpSecurityAttributes: LPSECURITY_ATTRIBUTES, ) -> BOOL1504 pub fn CreateDirectoryExW( 1505 lpTemplateDirectory: LPCWSTR, 1506 lpNewDirectory: LPCWSTR, 1507 lpSecurityAttributes: LPSECURITY_ATTRIBUTES, 1508 ) -> BOOL; CreateDirectoryTransactedA( lpTemplateDirectory: LPCSTR, lpNewDirectory: LPCSTR, lpSecurityAttributes: LPSECURITY_ATTRIBUTES, hTransaction: HANDLE, ) -> BOOL1509 pub fn CreateDirectoryTransactedA( 1510 lpTemplateDirectory: LPCSTR, 1511 lpNewDirectory: LPCSTR, 1512 lpSecurityAttributes: LPSECURITY_ATTRIBUTES, 1513 hTransaction: HANDLE, 1514 ) -> BOOL; CreateDirectoryTransactedW( lpTemplateDirectory: LPCWSTR, lpNewDirectory: LPCWSTR, lpSecurityAttributes: LPSECURITY_ATTRIBUTES, hTransaction: HANDLE, ) -> BOOL1515 pub fn CreateDirectoryTransactedW( 1516 lpTemplateDirectory: LPCWSTR, 1517 lpNewDirectory: LPCWSTR, 1518 lpSecurityAttributes: LPSECURITY_ATTRIBUTES, 1519 hTransaction: HANDLE, 1520 ) -> BOOL; RemoveDirectoryTransactedA( lpPathName: LPCSTR, hTransaction: HANDLE, ) -> BOOL1521 pub fn RemoveDirectoryTransactedA( 1522 lpPathName: LPCSTR, 1523 hTransaction: HANDLE, 1524 ) -> BOOL; RemoveDirectoryTransactedW( lpPathName: LPCWSTR, hTransaction: HANDLE, ) -> BOOL1525 pub fn RemoveDirectoryTransactedW( 1526 lpPathName: LPCWSTR, 1527 hTransaction: HANDLE, 1528 ) -> BOOL; GetFullPathNameTransactedA( lpFileName: LPCSTR, nBufferLength: DWORD, lpBuffer: LPSTR, lpFilePart: *mut LPSTR, hTransaction: HANDLE, ) -> DWORD1529 pub fn GetFullPathNameTransactedA( 1530 lpFileName: LPCSTR, 1531 nBufferLength: DWORD, 1532 lpBuffer: LPSTR, 1533 lpFilePart: *mut LPSTR, 1534 hTransaction: HANDLE, 1535 ) -> DWORD; GetFullPathNameTransactedW( lpFileName: LPCWSTR, nBufferLength: DWORD, lpBuffer: LPWSTR, lpFilePart: *mut LPWSTR, hTransaction: HANDLE, )1536 pub fn GetFullPathNameTransactedW( 1537 lpFileName: LPCWSTR, 1538 nBufferLength: DWORD, 1539 lpBuffer: LPWSTR, 1540 lpFilePart: *mut LPWSTR, 1541 hTransaction: HANDLE, 1542 ); DefineDosDeviceA( dwFlags: DWORD, lpDeviceName: LPCSTR, lpTargetPath: LPCSTR, ) -> BOOL1543 pub fn DefineDosDeviceA( 1544 dwFlags: DWORD, 1545 lpDeviceName: LPCSTR, 1546 lpTargetPath: LPCSTR, 1547 ) -> BOOL; QueryDosDeviceA( lpDeviceName: LPCSTR, lpTargetPath: LPSTR, ucchMax: DWORD, ) -> DWORD1548 pub fn QueryDosDeviceA( 1549 lpDeviceName: LPCSTR, 1550 lpTargetPath: LPSTR, 1551 ucchMax: DWORD, 1552 ) -> DWORD; CreateFileTransactedA( lpFileName: LPCSTR, dwDesiredAccess: DWORD, dwShareMode: DWORD, lpSecurityAttributes: LPSECURITY_ATTRIBUTES, dwCreationDisposition: DWORD, dwFlagsAndAttributes: DWORD, hTemplateFile: HANDLE, hTransaction: HANDLE, pusMiniVersion: PUSHORT, lpExtendedParameter: PVOID, ) -> HANDLE1553 pub fn CreateFileTransactedA( 1554 lpFileName: LPCSTR, 1555 dwDesiredAccess: DWORD, 1556 dwShareMode: DWORD, 1557 lpSecurityAttributes: LPSECURITY_ATTRIBUTES, 1558 dwCreationDisposition: DWORD, 1559 dwFlagsAndAttributes: DWORD, 1560 hTemplateFile: HANDLE, 1561 hTransaction: HANDLE, 1562 pusMiniVersion: PUSHORT, 1563 lpExtendedParameter: PVOID, 1564 ) -> HANDLE; CreateFileTransactedW( lpFileName: LPCWSTR, dwDesiredAccess: DWORD, dwShareMode: DWORD, lpSecurityAttributes: LPSECURITY_ATTRIBUTES, dwCreationDisposition: DWORD, dwFlagsAndAttributes: DWORD, hTemplateFile: HANDLE, hTransaction: HANDLE, pusMiniVersion: PUSHORT, lpExtendedParameter: PVOID, ) -> HANDLE1565 pub fn CreateFileTransactedW( 1566 lpFileName: LPCWSTR, 1567 dwDesiredAccess: DWORD, 1568 dwShareMode: DWORD, 1569 lpSecurityAttributes: LPSECURITY_ATTRIBUTES, 1570 dwCreationDisposition: DWORD, 1571 dwFlagsAndAttributes: DWORD, 1572 hTemplateFile: HANDLE, 1573 hTransaction: HANDLE, 1574 pusMiniVersion: PUSHORT, 1575 lpExtendedParameter: PVOID, 1576 ) -> HANDLE; ReOpenFile( hOriginalFile: HANDLE, dwDesiredAccess: DWORD, dwShareMode: DWORD, dwFlags: DWORD, ) -> HANDLE1577 pub fn ReOpenFile( 1578 hOriginalFile: HANDLE, 1579 dwDesiredAccess: DWORD, 1580 dwShareMode: DWORD, 1581 dwFlags: DWORD, 1582 ) -> HANDLE; SetFileAttributesTransactedA( lpFileName: LPCSTR, dwFileAttributes: DWORD, hTransaction: HANDLE, ) -> BOOL1583 pub fn SetFileAttributesTransactedA( 1584 lpFileName: LPCSTR, 1585 dwFileAttributes: DWORD, 1586 hTransaction: HANDLE, 1587 ) -> BOOL; SetFileAttributesTransactedW( lpFileName: LPCWSTR, dwFileAttributes: DWORD, hTransaction: HANDLE, ) -> BOOL1588 pub fn SetFileAttributesTransactedW( 1589 lpFileName: LPCWSTR, 1590 dwFileAttributes: DWORD, 1591 hTransaction: HANDLE, 1592 ) -> BOOL; GetFileAttributesTransactedA( lpFileName: LPCSTR, fInfoLevelId: GET_FILEEX_INFO_LEVELS, lpFileInformation: LPVOID, hTransaction: HANDLE, ) -> BOOL1593 pub fn GetFileAttributesTransactedA( 1594 lpFileName: LPCSTR, 1595 fInfoLevelId: GET_FILEEX_INFO_LEVELS, 1596 lpFileInformation: LPVOID, 1597 hTransaction: HANDLE, 1598 ) -> BOOL; GetFileAttributesTransactedW( lpFileName: LPCWSTR, fInfoLevelId: GET_FILEEX_INFO_LEVELS, lpFileInformation: LPVOID, hTransaction: HANDLE, ) -> BOOL1599 pub fn GetFileAttributesTransactedW( 1600 lpFileName: LPCWSTR, 1601 fInfoLevelId: GET_FILEEX_INFO_LEVELS, 1602 lpFileInformation: LPVOID, 1603 hTransaction: HANDLE, 1604 ) -> BOOL; GetCompressedFileSizeTransactedA( lpFileName: LPCSTR, lpFileSizeHigh: LPDWORD, hTransaction: HANDLE, ) -> DWORD1605 pub fn GetCompressedFileSizeTransactedA( 1606 lpFileName: LPCSTR, 1607 lpFileSizeHigh: LPDWORD, 1608 hTransaction: HANDLE, 1609 ) -> DWORD; GetCompressedFileSizeTransactedW( lpFileName: LPCWSTR, lpFileSizeHigh: LPDWORD, hTransaction: HANDLE, )1610 pub fn GetCompressedFileSizeTransactedW( 1611 lpFileName: LPCWSTR, 1612 lpFileSizeHigh: LPDWORD, 1613 hTransaction: HANDLE, 1614 ); DeleteFileTransactedA( lpFileName: LPCSTR, hTransaction: HANDLE, ) -> BOOL1615 pub fn DeleteFileTransactedA( 1616 lpFileName: LPCSTR, 1617 hTransaction: HANDLE, 1618 ) -> BOOL; DeleteFileTransactedW( lpFileName: LPCWSTR, hTransaction: HANDLE, ) -> BOOL1619 pub fn DeleteFileTransactedW( 1620 lpFileName: LPCWSTR, 1621 hTransaction: HANDLE, 1622 ) -> BOOL; CheckNameLegalDOS8Dot3A( lpName: LPCSTR, lpOemName: LPSTR, OemNameSize: DWORD, pbNameContainsSpaces: PBOOL, pbNameLegal: PBOOL, ) -> BOOL1623 pub fn CheckNameLegalDOS8Dot3A( 1624 lpName: LPCSTR, 1625 lpOemName: LPSTR, 1626 OemNameSize: DWORD, 1627 pbNameContainsSpaces: PBOOL, 1628 pbNameLegal: PBOOL, 1629 ) -> BOOL; CheckNameLegalDOS8Dot3W( lpName: LPCWSTR, lpOemName: LPSTR, OemNameSize: DWORD, pbNameContainsSpaces: PBOOL, pbNameLegal: PBOOL, ) -> BOOL1630 pub fn CheckNameLegalDOS8Dot3W( 1631 lpName: LPCWSTR, 1632 lpOemName: LPSTR, 1633 OemNameSize: DWORD, 1634 pbNameContainsSpaces: PBOOL, 1635 pbNameLegal: PBOOL, 1636 ) -> BOOL; FindFirstFileTransactedA( lpFileName: LPCSTR, fInfoLevelId: FINDEX_INFO_LEVELS, lpFindFileData: LPVOID, fSearchOp: FINDEX_SEARCH_OPS, lpSearchFilter: LPVOID, dwAdditionalFlags: DWORD, hTransaction: HANDLE, ) -> HANDLE1637 pub fn FindFirstFileTransactedA( 1638 lpFileName: LPCSTR, 1639 fInfoLevelId: FINDEX_INFO_LEVELS, 1640 lpFindFileData: LPVOID, 1641 fSearchOp: FINDEX_SEARCH_OPS, 1642 lpSearchFilter: LPVOID, 1643 dwAdditionalFlags: DWORD, 1644 hTransaction: HANDLE, 1645 ) -> HANDLE; FindFirstFileTransactedW( lpFileName: LPCWSTR, fInfoLevelId: FINDEX_INFO_LEVELS, lpFindFileData: LPVOID, fSearchOp: FINDEX_SEARCH_OPS, lpSearchFilter: LPVOID, dwAdditionalFlags: DWORD, hTransaction: HANDLE, ) -> HANDLE1646 pub fn FindFirstFileTransactedW( 1647 lpFileName: LPCWSTR, 1648 fInfoLevelId: FINDEX_INFO_LEVELS, 1649 lpFindFileData: LPVOID, 1650 fSearchOp: FINDEX_SEARCH_OPS, 1651 lpSearchFilter: LPVOID, 1652 dwAdditionalFlags: DWORD, 1653 hTransaction: HANDLE, 1654 ) -> HANDLE; CopyFileA( lpExistingFileName: LPCSTR, lpNewFileName: LPCSTR, bFailIfExists: BOOL, ) -> BOOL1655 pub fn CopyFileA( 1656 lpExistingFileName: LPCSTR, 1657 lpNewFileName: LPCSTR, 1658 bFailIfExists: BOOL, 1659 ) -> BOOL; CopyFileW( lpExistingFileName: LPCWSTR, lpNewFileName: LPCWSTR, bFailIfExists: BOOL, ) -> BOOL1660 pub fn CopyFileW( 1661 lpExistingFileName: LPCWSTR, 1662 lpNewFileName: LPCWSTR, 1663 bFailIfExists: BOOL, 1664 ) -> BOOL; 1665 } 1666 FN!{stdcall LPPROGRESS_ROUTINE( 1667 TotalFileSize: LARGE_INTEGER, 1668 TotalBytesTransferred: LARGE_INTEGER, 1669 StreamSize: LARGE_INTEGER, 1670 StreamBytesTransferred: LARGE_INTEGER, 1671 dwStreamNumber: DWORD, 1672 dwCallbackReason: DWORD, 1673 hSourceFile: HANDLE, 1674 hDestinationFile: HANDLE, 1675 lpData: LPVOID, 1676 ) -> DWORD} 1677 extern "system" { CopyFileExA( lpExistingFileName: LPCSTR, lpNewFileName: LPCSTR, lpProgressRoutine: LPPROGRESS_ROUTINE, lpData: LPVOID, pbCancel: LPBOOL, dwCopyFlags: DWORD, ) -> BOOL1678 pub fn CopyFileExA( 1679 lpExistingFileName: LPCSTR, 1680 lpNewFileName: LPCSTR, 1681 lpProgressRoutine: LPPROGRESS_ROUTINE, 1682 lpData: LPVOID, 1683 pbCancel: LPBOOL, 1684 dwCopyFlags: DWORD, 1685 ) -> BOOL; CopyFileExW( lpExistingFileName: LPCWSTR, lpNewFileName: LPCWSTR, lpProgressRoutine: LPPROGRESS_ROUTINE, lpData: LPVOID, pbCancel: LPBOOL, dwCopyFlags: DWORD, ) -> BOOL1686 pub fn CopyFileExW( 1687 lpExistingFileName: LPCWSTR, 1688 lpNewFileName: LPCWSTR, 1689 lpProgressRoutine: LPPROGRESS_ROUTINE, 1690 lpData: LPVOID, 1691 pbCancel: LPBOOL, 1692 dwCopyFlags: DWORD, 1693 ) -> BOOL; CopyFileTransactedA( lpExistingFileName: LPCWSTR, lpNewFileName: LPCWSTR, lpProgressRoutine: LPPROGRESS_ROUTINE, lpData: LPVOID, pbCancel: LPBOOL, dwCopyFlags: DWORD, hTransaction: HANDLE, ) -> BOOL1694 pub fn CopyFileTransactedA( 1695 lpExistingFileName: LPCWSTR, 1696 lpNewFileName: LPCWSTR, 1697 lpProgressRoutine: LPPROGRESS_ROUTINE, 1698 lpData: LPVOID, 1699 pbCancel: LPBOOL, 1700 dwCopyFlags: DWORD, 1701 hTransaction: HANDLE, 1702 ) -> BOOL; CopyFileTransactedW( lpExistingFileName: LPCWSTR, lpNewFileName: LPCWSTR, lpProgressRoutine: LPPROGRESS_ROUTINE, lpData: LPVOID, pbCancel: LPBOOL, dwCopyFlags: DWORD, hTransaction: HANDLE, ) -> BOOL1703 pub fn CopyFileTransactedW( 1704 lpExistingFileName: LPCWSTR, 1705 lpNewFileName: LPCWSTR, 1706 lpProgressRoutine: LPPROGRESS_ROUTINE, 1707 lpData: LPVOID, 1708 pbCancel: LPBOOL, 1709 dwCopyFlags: DWORD, 1710 hTransaction: HANDLE, 1711 ) -> BOOL; 1712 } 1713 ENUM!{enum COPYFILE2_MESSAGE_TYPE { 1714 COPYFILE2_CALLBACK_NONE = 0, 1715 COPYFILE2_CALLBACK_CHUNK_STARTED, 1716 COPYFILE2_CALLBACK_CHUNK_FINISHED, 1717 COPYFILE2_CALLBACK_STREAM_STARTED, 1718 COPYFILE2_CALLBACK_STREAM_FINISHED, 1719 COPYFILE2_CALLBACK_POLL_CONTINUE, 1720 COPYFILE2_CALLBACK_ERROR, 1721 COPYFILE2_CALLBACK_MAX, 1722 }} 1723 ENUM!{enum COPYFILE2_MESSAGE_ACTION { 1724 COPYFILE2_PROGRESS_CONTINUE = 0, 1725 COPYFILE2_PROGRESS_CANCEL, 1726 COPYFILE2_PROGRESS_STOP, 1727 COPYFILE2_PROGRESS_QUIET, 1728 COPYFILE2_PROGRESS_PAUSE, 1729 }} 1730 ENUM!{enum COPYFILE2_COPY_PHASE { 1731 COPYFILE2_PHASE_NONE = 0, 1732 COPYFILE2_PHASE_PREPARE_SOURCE, 1733 COPYFILE2_PHASE_PREPARE_DEST, 1734 COPYFILE2_PHASE_READ_SOURCE, 1735 COPYFILE2_PHASE_WRITE_DESTINATION, 1736 COPYFILE2_PHASE_SERVER_COPY, 1737 COPYFILE2_PHASE_NAMEGRAFT_COPY, 1738 COPYFILE2_PHASE_MAX, 1739 }} 1740 STRUCT!{struct COPYFILE2_MESSAGE_ChunkStarted { 1741 dwStreamNumber: DWORD, 1742 dwReserved: DWORD, 1743 hSourceFile: HANDLE, 1744 hDestinationFile: HANDLE, 1745 uliChunkNumber: ULARGE_INTEGER, 1746 uliChunkSize: ULARGE_INTEGER, 1747 uliStreamSize: ULARGE_INTEGER, 1748 uliTotalFileSize: ULARGE_INTEGER, 1749 }} 1750 STRUCT!{struct COPYFILE2_MESSAGE_ChunkFinished { 1751 dwStreamNumber: DWORD, 1752 dwFlags: DWORD, 1753 hSourceFile: HANDLE, 1754 hDestinationFile: HANDLE, 1755 uliChunkNumber: ULARGE_INTEGER, 1756 uliChunkSize: ULARGE_INTEGER, 1757 uliStreamSize: ULARGE_INTEGER, 1758 uliStreamBytesTransferred: ULARGE_INTEGER, 1759 uliTotalFileSize: ULARGE_INTEGER, 1760 uliTotalBytesTransferred: ULARGE_INTEGER, 1761 }} 1762 STRUCT!{struct COPYFILE2_MESSAGE_StreamStarted { 1763 dwStreamNumber: DWORD, 1764 dwReserved: DWORD, 1765 hSourceFile: HANDLE, 1766 hDestinationFile: HANDLE, 1767 uliStreamSize: ULARGE_INTEGER, 1768 uliTotalFileSize: ULARGE_INTEGER, 1769 }} 1770 STRUCT!{struct COPYFILE2_MESSAGE_StreamFinished { 1771 dwStreamNumber: DWORD, 1772 dwReserved: DWORD, 1773 hSourceFile: HANDLE, 1774 hDestinationFile: HANDLE, 1775 uliStreamSize: ULARGE_INTEGER, 1776 uliStreamBytesTransferred: ULARGE_INTEGER, 1777 uliTotalFileSize: ULARGE_INTEGER, 1778 uliTotalBytesTransferred: ULARGE_INTEGER, 1779 }} 1780 STRUCT!{struct COPYFILE2_MESSAGE_PollContinue { 1781 dwReserved: DWORD, 1782 }} 1783 STRUCT!{struct COPYFILE2_MESSAGE_Error { 1784 CopyPhase: COPYFILE2_COPY_PHASE, 1785 dwStreamNumber: DWORD, 1786 hrFailure: HRESULT, 1787 dwReserved: DWORD, 1788 uliChunkNumber: ULARGE_INTEGER, 1789 uliStreamSize: ULARGE_INTEGER, 1790 uliStreamBytesTransferred: ULARGE_INTEGER, 1791 uliTotalFileSize: ULARGE_INTEGER, 1792 uliTotalBytesTransferred: ULARGE_INTEGER, 1793 }} 1794 UNION!{union COPYFILE2_MESSAGE_Info { 1795 [u64; 8] [u64; 9], 1796 ChunkStarted ChunkStarted_mut: COPYFILE2_MESSAGE_ChunkStarted, 1797 ChunkFinished ChunkFinished_mut: COPYFILE2_MESSAGE_ChunkFinished, 1798 StreamStarted StreamStarted_mut: COPYFILE2_MESSAGE_StreamStarted, 1799 StreamFinished StreamFinished_mut: COPYFILE2_MESSAGE_StreamFinished, 1800 PollContinue PollContinue_mut: COPYFILE2_MESSAGE_PollContinue, 1801 Error Error_mut: COPYFILE2_MESSAGE_Error, 1802 }} 1803 STRUCT!{struct COPYFILE2_MESSAGE { 1804 Type: COPYFILE2_MESSAGE_TYPE, 1805 dwPadding: DWORD, 1806 Info: COPYFILE2_MESSAGE_Info, 1807 }} 1808 FN!{stdcall PCOPYFILE2_PROGRESS_ROUTINE( 1809 pMessage: *const COPYFILE2_MESSAGE, 1810 pvCallbackContext: PVOID, 1811 ) -> COPYFILE2_MESSAGE_ACTION} 1812 STRUCT!{struct COPYFILE2_EXTENDED_PARAMETERS { 1813 dwSize: DWORD, 1814 dwCopyFlags: DWORD, 1815 pfCancel: *mut BOOL, 1816 pProgressRoutine: PCOPYFILE2_PROGRESS_ROUTINE, 1817 pvCallbackContext: PVOID, 1818 }} 1819 extern "system" { CopyFile2( pwszExistingFileName: PCWSTR, pwszNewFileName: PCWSTR, pExtendedParameters: *mut COPYFILE2_EXTENDED_PARAMETERS, ) -> HRESULT1820 pub fn CopyFile2( 1821 pwszExistingFileName: PCWSTR, 1822 pwszNewFileName: PCWSTR, 1823 pExtendedParameters: *mut COPYFILE2_EXTENDED_PARAMETERS, 1824 ) -> HRESULT; MoveFileA( lpExistingFileName: LPCSTR, lpNewFileName: LPCSTR, ) -> BOOL1825 pub fn MoveFileA( 1826 lpExistingFileName: LPCSTR, 1827 lpNewFileName: LPCSTR, 1828 ) -> BOOL; MoveFileW( lpExistingFileName: LPCWSTR, lpNewFileName: LPCWSTR, ) -> BOOL1829 pub fn MoveFileW( 1830 lpExistingFileName: LPCWSTR, 1831 lpNewFileName: LPCWSTR, 1832 ) -> BOOL; MoveFileExA( lpExistingFileName: LPCSTR, lpNewFileName: LPCSTR, dwFlags: DWORD, ) -> BOOL1833 pub fn MoveFileExA( 1834 lpExistingFileName: LPCSTR, 1835 lpNewFileName: LPCSTR, 1836 dwFlags: DWORD, 1837 ) -> BOOL; MoveFileExW( lpExistingFileName: LPCWSTR, lpNewFileName: LPCWSTR, dwFlags: DWORD, ) -> BOOL1838 pub fn MoveFileExW( 1839 lpExistingFileName: LPCWSTR, 1840 lpNewFileName: LPCWSTR, 1841 dwFlags: DWORD, 1842 ) -> BOOL; MoveFileWithProgressA( lpExistingFileName: LPCSTR, lpNewFileName: LPCSTR, lpProgressRoutine: LPPROGRESS_ROUTINE, lpData: LPVOID, dwFlags: DWORD, ) -> BOOL1843 pub fn MoveFileWithProgressA( 1844 lpExistingFileName: LPCSTR, 1845 lpNewFileName: LPCSTR, 1846 lpProgressRoutine: LPPROGRESS_ROUTINE, 1847 lpData: LPVOID, 1848 dwFlags: DWORD, 1849 ) -> BOOL; MoveFileWithProgressW( lpExistingFileName: LPCWSTR, lpNewFileName: LPCWSTR, lpProgressRoutine: LPPROGRESS_ROUTINE, lpData: LPVOID, dwFlags: DWORD, ) -> BOOL1850 pub fn MoveFileWithProgressW( 1851 lpExistingFileName: LPCWSTR, 1852 lpNewFileName: LPCWSTR, 1853 lpProgressRoutine: LPPROGRESS_ROUTINE, 1854 lpData: LPVOID, 1855 dwFlags: DWORD, 1856 ) -> BOOL; MoveFileTransactedA( lpExistingFileName: LPCSTR, lpNewFileName: LPCSTR, lpProgressRoutine: LPPROGRESS_ROUTINE, lpData: LPVOID, dwFlags: DWORD, hTransaction: HANDLE, ) -> BOOL1857 pub fn MoveFileTransactedA( 1858 lpExistingFileName: LPCSTR, 1859 lpNewFileName: LPCSTR, 1860 lpProgressRoutine: LPPROGRESS_ROUTINE, 1861 lpData: LPVOID, 1862 dwFlags: DWORD, 1863 hTransaction: HANDLE, 1864 ) -> BOOL; MoveFileTransactedW( lpExistingFileName: LPCWSTR, lpNewFileName: LPCWSTR, lpProgressRoutine: LPPROGRESS_ROUTINE, lpData: LPVOID, dwFlags: DWORD, hTransaction: HANDLE, ) -> BOOL1865 pub fn MoveFileTransactedW( 1866 lpExistingFileName: LPCWSTR, 1867 lpNewFileName: LPCWSTR, 1868 lpProgressRoutine: LPPROGRESS_ROUTINE, 1869 lpData: LPVOID, 1870 dwFlags: DWORD, 1871 hTransaction: HANDLE, 1872 ) -> BOOL; 1873 } 1874 pub const MOVEFILE_REPLACE_EXISTING: DWORD = 0x00000001; 1875 pub const MOVEFILE_COPY_ALLOWED: DWORD = 0x00000002; 1876 pub const MOVEFILE_DELAY_UNTIL_REBOOT: DWORD = 0x00000004; 1877 pub const MOVEFILE_WRITE_THROUGH: DWORD = 0x00000008; 1878 pub const MOVEFILE_CREATE_HARDLINK: DWORD = 0x00000010; 1879 pub const MOVEFILE_FAIL_IF_NOT_TRACKABLE: DWORD = 0x00000020; 1880 extern "system" { ReplaceFileA( lpReplacedFileName: LPCSTR, lpReplacementFileName: LPCSTR, lpBackupFileName: LPCSTR, dwReplaceFlags: DWORD, lpExclude: LPVOID, lpReserved: LPVOID, )1881 pub fn ReplaceFileA( 1882 lpReplacedFileName: LPCSTR, 1883 lpReplacementFileName: LPCSTR, 1884 lpBackupFileName: LPCSTR, 1885 dwReplaceFlags: DWORD, 1886 lpExclude: LPVOID, 1887 lpReserved: LPVOID, 1888 ); ReplaceFileW( lpReplacedFileName: LPCWSTR, lpReplacementFileName: LPCWSTR, lpBackupFileName: LPCWSTR, dwReplaceFlags: DWORD, lpExclude: LPVOID, lpReserved: LPVOID, )1889 pub fn ReplaceFileW( 1890 lpReplacedFileName: LPCWSTR, 1891 lpReplacementFileName: LPCWSTR, 1892 lpBackupFileName: LPCWSTR, 1893 dwReplaceFlags: DWORD, 1894 lpExclude: LPVOID, 1895 lpReserved: LPVOID, 1896 ); CreateHardLinkA( lpFileName: LPCSTR, lpExistingFileName: LPCSTR, lpSecurityAttributes: LPSECURITY_ATTRIBUTES, ) -> BOOL1897 pub fn CreateHardLinkA( 1898 lpFileName: LPCSTR, 1899 lpExistingFileName: LPCSTR, 1900 lpSecurityAttributes: LPSECURITY_ATTRIBUTES, 1901 ) -> BOOL; CreateHardLinkW( lpFileName: LPCWSTR, lpExistingFileName: LPCWSTR, lpSecurityAttributes: LPSECURITY_ATTRIBUTES, ) -> BOOL1902 pub fn CreateHardLinkW( 1903 lpFileName: LPCWSTR, 1904 lpExistingFileName: LPCWSTR, 1905 lpSecurityAttributes: LPSECURITY_ATTRIBUTES, 1906 ) -> BOOL; CreateHardLinkTransactedA( lpFileName: LPCSTR, lpExistingFileName: LPCSTR, lpSecurityAttributes: LPSECURITY_ATTRIBUTES, hTransaction: HANDLE, ) -> BOOL1907 pub fn CreateHardLinkTransactedA( 1908 lpFileName: LPCSTR, 1909 lpExistingFileName: LPCSTR, 1910 lpSecurityAttributes: LPSECURITY_ATTRIBUTES, 1911 hTransaction: HANDLE, 1912 ) -> BOOL; CreateHardLinkTransactedW( lpFileName: LPCWSTR, lpExistingFileName: LPCWSTR, lpSecurityAttributes: LPSECURITY_ATTRIBUTES, hTransaction: HANDLE, )1913 pub fn CreateHardLinkTransactedW( 1914 lpFileName: LPCWSTR, 1915 lpExistingFileName: LPCWSTR, 1916 lpSecurityAttributes: LPSECURITY_ATTRIBUTES, 1917 hTransaction: HANDLE, 1918 ); FindFirstStreamTransactedW( lpFileName: LPCWSTR, InfoLevel: STREAM_INFO_LEVELS, lpFindStreamData: LPVOID, dwFlags: DWORD, hTransaction: HANDLE, ) -> HANDLE1919 pub fn FindFirstStreamTransactedW( 1920 lpFileName: LPCWSTR, 1921 InfoLevel: STREAM_INFO_LEVELS, 1922 lpFindStreamData: LPVOID, 1923 dwFlags: DWORD, 1924 hTransaction: HANDLE, 1925 ) -> HANDLE; FindFirstFileNameTransactedW( lpFileName: LPCWSTR, dwFlags: DWORD, StringLength: LPDWORD, LinkName: PWSTR, hTransaction: HANDLE, ) -> HANDLE1926 pub fn FindFirstFileNameTransactedW( 1927 lpFileName: LPCWSTR, 1928 dwFlags: DWORD, 1929 StringLength: LPDWORD, 1930 LinkName: PWSTR, 1931 hTransaction: HANDLE, 1932 ) -> HANDLE; CreateNamedPipeA( lpName: LPCSTR, dwOpenMode: DWORD, dwPipeMode: DWORD, nMaxInstances: DWORD, nOutBufferSize: DWORD, nInBufferSize: DWORD, nDefaultTimeOut: DWORD, lpSecurityAttributes: LPSECURITY_ATTRIBUTES, ) -> HANDLE1933 pub fn CreateNamedPipeA( 1934 lpName: LPCSTR, 1935 dwOpenMode: DWORD, 1936 dwPipeMode: DWORD, 1937 nMaxInstances: DWORD, 1938 nOutBufferSize: DWORD, 1939 nInBufferSize: DWORD, 1940 nDefaultTimeOut: DWORD, 1941 lpSecurityAttributes: LPSECURITY_ATTRIBUTES, 1942 ) -> HANDLE; GetNamedPipeHandleStateA( hNamedPipe: HANDLE, lpState: LPDWORD, lpCurInstances: LPDWORD, lpMaxCollectionCount: LPDWORD, lpCollectDataTimeout: LPDWORD, lpUserName: LPSTR, nMaxUserNameSize: DWORD, ) -> BOOL1943 pub fn GetNamedPipeHandleStateA( 1944 hNamedPipe: HANDLE, 1945 lpState: LPDWORD, 1946 lpCurInstances: LPDWORD, 1947 lpMaxCollectionCount: LPDWORD, 1948 lpCollectDataTimeout: LPDWORD, 1949 lpUserName: LPSTR, 1950 nMaxUserNameSize: DWORD, 1951 ) -> BOOL; CallNamedPipeA( lpNamedPipeName: LPCSTR, lpInBuffer: LPVOID, nInBufferSize: DWORD, lpOutBuffer: LPVOID, nOutBufferSize: DWORD, lpBytesRead: LPDWORD, nTimeOut: DWORD, ) -> BOOL1952 pub fn CallNamedPipeA( 1953 lpNamedPipeName: LPCSTR, 1954 lpInBuffer: LPVOID, 1955 nInBufferSize: DWORD, 1956 lpOutBuffer: LPVOID, 1957 nOutBufferSize: DWORD, 1958 lpBytesRead: LPDWORD, 1959 nTimeOut: DWORD, 1960 ) -> BOOL; WaitNamedPipeA( lpNamedPipeName: LPCSTR, nTimeOut: DWORD, ) -> BOOL1961 pub fn WaitNamedPipeA( 1962 lpNamedPipeName: LPCSTR, 1963 nTimeOut: DWORD, 1964 ) -> BOOL; GetNamedPipeClientComputerNameA( Pipe: HANDLE, ClientComputerName: LPSTR, ClientComputerNameLength: ULONG, ) -> BOOL1965 pub fn GetNamedPipeClientComputerNameA( 1966 Pipe: HANDLE, 1967 ClientComputerName: LPSTR, 1968 ClientComputerNameLength: ULONG, 1969 ) -> BOOL; GetNamedPipeClientProcessId( Pipe: HANDLE, ClientProcessId: PULONG, ) -> BOOL1970 pub fn GetNamedPipeClientProcessId( 1971 Pipe: HANDLE, 1972 ClientProcessId: PULONG, 1973 ) -> BOOL; GetNamedPipeClientSessionId( Pipe: HANDLE, ClientSessionId: PULONG, ) -> BOOL1974 pub fn GetNamedPipeClientSessionId( 1975 Pipe: HANDLE, 1976 ClientSessionId: PULONG, 1977 ) -> BOOL; GetNamedPipeServerProcessId( Pipe: HANDLE, ServerProcessId: PULONG, ) -> BOOL1978 pub fn GetNamedPipeServerProcessId( 1979 Pipe: HANDLE, 1980 ServerProcessId: PULONG, 1981 ) -> BOOL; GetNamedPipeServerSessionId( Pipe: HANDLE, ServerSessionId: PULONG, ) -> BOOL1982 pub fn GetNamedPipeServerSessionId( 1983 Pipe: HANDLE, 1984 ServerSessionId: PULONG, 1985 ) -> BOOL; SetVolumeLabelA( lpRootPathName: LPCSTR, lpVolumeName: LPCSTR, ) -> BOOL1986 pub fn SetVolumeLabelA( 1987 lpRootPathName: LPCSTR, 1988 lpVolumeName: LPCSTR, 1989 ) -> BOOL; SetVolumeLabelW( lpRootPathName: LPCWSTR, lpVolumeName: LPCWSTR, ) -> BOOL1990 pub fn SetVolumeLabelW( 1991 lpRootPathName: LPCWSTR, 1992 lpVolumeName: LPCWSTR, 1993 ) -> BOOL; SetFileBandwidthReservation( hFile: HANDLE, nPeriodMilliseconds: DWORD, nBytesPerPeriod: DWORD, bDiscardable: BOOL, lpTransferSize: LPDWORD, lpNumOutstandingRequests: LPDWORD, ) -> BOOL1994 pub fn SetFileBandwidthReservation( 1995 hFile: HANDLE, 1996 nPeriodMilliseconds: DWORD, 1997 nBytesPerPeriod: DWORD, 1998 bDiscardable: BOOL, 1999 lpTransferSize: LPDWORD, 2000 lpNumOutstandingRequests: LPDWORD, 2001 ) -> BOOL; GetFileBandwidthReservation( hFile: HANDLE, lpPeriodMilliseconds: LPDWORD, lpBytesPerPeriod: LPDWORD, pDiscardable: LPBOOL, lpTransferSize: LPDWORD, lpNumOutstandingRequests: LPDWORD, ) -> BOOL2002 pub fn GetFileBandwidthReservation( 2003 hFile: HANDLE, 2004 lpPeriodMilliseconds: LPDWORD, 2005 lpBytesPerPeriod: LPDWORD, 2006 pDiscardable: LPBOOL, 2007 lpTransferSize: LPDWORD, 2008 lpNumOutstandingRequests: LPDWORD, 2009 ) -> BOOL; 2010 // pub fn ClearEventLogA(); 2011 // pub fn ClearEventLogW(); 2012 // pub fn BackupEventLogA(); 2013 // pub fn BackupEventLogW(); 2014 // pub fn CloseEventLog(); DeregisterEventSource( hEventLog: HANDLE, ) -> BOOL2015 pub fn DeregisterEventSource( 2016 hEventLog: HANDLE, 2017 ) -> BOOL; 2018 // pub fn NotifyChangeEventLog(); 2019 // pub fn GetNumberOfEventLogRecords(); 2020 // pub fn GetOldestEventLogRecord(); 2021 // pub fn OpenEventLogA(); 2022 // pub fn OpenEventLogW(); RegisterEventSourceA( lpUNCServerName: LPCSTR, lpSourceName: LPCSTR, ) -> HANDLE2023 pub fn RegisterEventSourceA( 2024 lpUNCServerName: LPCSTR, 2025 lpSourceName: LPCSTR, 2026 ) -> HANDLE; RegisterEventSourceW( lpUNCServerName: LPCWSTR, lpSourceName: LPCWSTR, ) -> HANDLE2027