windows-sys 0.27.0

Rust for Windows
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
#![allow(non_snake_case, non_camel_case_types, non_upper_case_globals, clashing_extern_declarations, clippy::all)]
#[link(name = "windows")]
extern "system" {}
#[repr(transparent)]
pub struct IUsbBulkInEndpointDescriptor(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbBulkInEndpointDescriptor {}
impl ::core::clone::Clone for IUsbBulkInEndpointDescriptor {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbBulkInPipe(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbBulkInPipe {}
impl ::core::clone::Clone for IUsbBulkInPipe {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbBulkOutEndpointDescriptor(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbBulkOutEndpointDescriptor {}
impl ::core::clone::Clone for IUsbBulkOutEndpointDescriptor {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbBulkOutPipe(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbBulkOutPipe {}
impl ::core::clone::Clone for IUsbBulkOutPipe {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbConfiguration(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbConfiguration {}
impl ::core::clone::Clone for IUsbConfiguration {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbConfigurationDescriptor(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbConfigurationDescriptor {}
impl ::core::clone::Clone for IUsbConfigurationDescriptor {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbConfigurationDescriptorStatics(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbConfigurationDescriptorStatics {}
impl ::core::clone::Clone for IUsbConfigurationDescriptorStatics {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbControlRequestType(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbControlRequestType {}
impl ::core::clone::Clone for IUsbControlRequestType {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbDescriptor(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbDescriptor {}
impl ::core::clone::Clone for IUsbDescriptor {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbDevice(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbDevice {}
impl ::core::clone::Clone for IUsbDevice {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbDeviceClass(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbDeviceClass {}
impl ::core::clone::Clone for IUsbDeviceClass {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbDeviceClasses(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbDeviceClasses {}
impl ::core::clone::Clone for IUsbDeviceClasses {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbDeviceClassesStatics(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbDeviceClassesStatics {}
impl ::core::clone::Clone for IUsbDeviceClassesStatics {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbDeviceDescriptor(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbDeviceDescriptor {}
impl ::core::clone::Clone for IUsbDeviceDescriptor {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbDeviceStatics(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbDeviceStatics {}
impl ::core::clone::Clone for IUsbDeviceStatics {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbEndpointDescriptor(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbEndpointDescriptor {}
impl ::core::clone::Clone for IUsbEndpointDescriptor {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbEndpointDescriptorStatics(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbEndpointDescriptorStatics {}
impl ::core::clone::Clone for IUsbEndpointDescriptorStatics {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbInterface(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbInterface {}
impl ::core::clone::Clone for IUsbInterface {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbInterfaceDescriptor(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbInterfaceDescriptor {}
impl ::core::clone::Clone for IUsbInterfaceDescriptor {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbInterfaceDescriptorStatics(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbInterfaceDescriptorStatics {}
impl ::core::clone::Clone for IUsbInterfaceDescriptorStatics {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbInterfaceSetting(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbInterfaceSetting {}
impl ::core::clone::Clone for IUsbInterfaceSetting {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbInterruptInEndpointDescriptor(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbInterruptInEndpointDescriptor {}
impl ::core::clone::Clone for IUsbInterruptInEndpointDescriptor {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbInterruptInEventArgs(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbInterruptInEventArgs {}
impl ::core::clone::Clone for IUsbInterruptInEventArgs {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbInterruptInPipe(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbInterruptInPipe {}
impl ::core::clone::Clone for IUsbInterruptInPipe {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbInterruptOutEndpointDescriptor(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbInterruptOutEndpointDescriptor {}
impl ::core::clone::Clone for IUsbInterruptOutEndpointDescriptor {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbInterruptOutPipe(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbInterruptOutPipe {}
impl ::core::clone::Clone for IUsbInterruptOutPipe {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbSetupPacket(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbSetupPacket {}
impl ::core::clone::Clone for IUsbSetupPacket {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct IUsbSetupPacketFactory(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for IUsbSetupPacketFactory {}
impl ::core::clone::Clone for IUsbSetupPacketFactory {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbBulkInEndpointDescriptor(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbBulkInEndpointDescriptor {}
impl ::core::clone::Clone for UsbBulkInEndpointDescriptor {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbBulkInPipe(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbBulkInPipe {}
impl ::core::clone::Clone for UsbBulkInPipe {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbBulkOutEndpointDescriptor(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbBulkOutEndpointDescriptor {}
impl ::core::clone::Clone for UsbBulkOutEndpointDescriptor {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbBulkOutPipe(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbBulkOutPipe {}
impl ::core::clone::Clone for UsbBulkOutPipe {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbConfiguration(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbConfiguration {}
impl ::core::clone::Clone for UsbConfiguration {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbConfigurationDescriptor(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbConfigurationDescriptor {}
impl ::core::clone::Clone for UsbConfigurationDescriptor {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbControlRecipient(pub i32);
impl UsbControlRecipient {
    pub const Device: Self = Self(0i32);
    pub const SpecifiedInterface: Self = Self(1i32);
    pub const Endpoint: Self = Self(2i32);
    pub const Other: Self = Self(3i32);
    pub const DefaultInterface: Self = Self(4i32);
}
impl ::core::marker::Copy for UsbControlRecipient {}
impl ::core::clone::Clone for UsbControlRecipient {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbControlRequestType(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbControlRequestType {}
impl ::core::clone::Clone for UsbControlRequestType {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbControlTransferType(pub i32);
impl UsbControlTransferType {
    pub const Standard: Self = Self(0i32);
    pub const Class: Self = Self(1i32);
    pub const Vendor: Self = Self(2i32);
}
impl ::core::marker::Copy for UsbControlTransferType {}
impl ::core::clone::Clone for UsbControlTransferType {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbDescriptor(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbDescriptor {}
impl ::core::clone::Clone for UsbDescriptor {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbDevice(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbDevice {}
impl ::core::clone::Clone for UsbDevice {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbDeviceClass(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbDeviceClass {}
impl ::core::clone::Clone for UsbDeviceClass {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbDeviceClasses(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbDeviceClasses {}
impl ::core::clone::Clone for UsbDeviceClasses {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbDeviceDescriptor(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbDeviceDescriptor {}
impl ::core::clone::Clone for UsbDeviceDescriptor {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbEndpointDescriptor(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbEndpointDescriptor {}
impl ::core::clone::Clone for UsbEndpointDescriptor {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbEndpointType(pub i32);
impl UsbEndpointType {
    pub const Control: Self = Self(0i32);
    pub const Isochronous: Self = Self(1i32);
    pub const Bulk: Self = Self(2i32);
    pub const Interrupt: Self = Self(3i32);
}
impl ::core::marker::Copy for UsbEndpointType {}
impl ::core::clone::Clone for UsbEndpointType {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbInterface(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbInterface {}
impl ::core::clone::Clone for UsbInterface {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbInterfaceDescriptor(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbInterfaceDescriptor {}
impl ::core::clone::Clone for UsbInterfaceDescriptor {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbInterfaceSetting(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbInterfaceSetting {}
impl ::core::clone::Clone for UsbInterfaceSetting {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbInterruptInEndpointDescriptor(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbInterruptInEndpointDescriptor {}
impl ::core::clone::Clone for UsbInterruptInEndpointDescriptor {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbInterruptInEventArgs(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbInterruptInEventArgs {}
impl ::core::clone::Clone for UsbInterruptInEventArgs {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbInterruptInPipe(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbInterruptInPipe {}
impl ::core::clone::Clone for UsbInterruptInPipe {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbInterruptOutEndpointDescriptor(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbInterruptOutEndpointDescriptor {}
impl ::core::clone::Clone for UsbInterruptOutEndpointDescriptor {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbInterruptOutPipe(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbInterruptOutPipe {}
impl ::core::clone::Clone for UsbInterruptOutPipe {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbReadOptions(pub u32);
impl UsbReadOptions {
    pub const None: Self = Self(0u32);
    pub const AutoClearStall: Self = Self(1u32);
    pub const OverrideAutomaticBufferManagement: Self = Self(2u32);
    pub const IgnoreShortPacket: Self = Self(4u32);
    pub const AllowPartialReads: Self = Self(8u32);
}
impl ::core::marker::Copy for UsbReadOptions {}
impl ::core::clone::Clone for UsbReadOptions {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbSetupPacket(pub *mut ::core::ffi::c_void);
impl ::core::marker::Copy for UsbSetupPacket {}
impl ::core::clone::Clone for UsbSetupPacket {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbTransferDirection(pub i32);
impl UsbTransferDirection {
    pub const Out: Self = Self(0i32);
    pub const In: Self = Self(1i32);
}
impl ::core::marker::Copy for UsbTransferDirection {}
impl ::core::clone::Clone for UsbTransferDirection {
    fn clone(&self) -> Self {
        *self
    }
}
#[repr(transparent)]
pub struct UsbWriteOptions(pub u32);
impl UsbWriteOptions {
    pub const None: Self = Self(0u32);
    pub const AutoClearStall: Self = Self(1u32);
    pub const ShortPacketTerminate: Self = Self(2u32);
}
impl ::core::marker::Copy for UsbWriteOptions {}
impl ::core::clone::Clone for UsbWriteOptions {
    fn clone(&self) -> Self {
        *self
    }
}