winrt-Windows.Devices.Custom 2.3.0__tar.gz → 3.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {winrt_windows_devices_custom-2.3.0 → winrt_windows_devices_custom-3.1.0}/PKG-INFO +7 -7
- winrt_windows_devices_custom-3.1.0/all-requirements.txt +4 -0
- {winrt_windows_devices_custom-2.3.0 → winrt_windows_devices_custom-3.1.0}/py.Windows.Devices.Custom.cpp +335 -86
- {winrt_windows_devices_custom-2.3.0 → winrt_windows_devices_custom-3.1.0}/pyproject.toml +4 -4
- winrt_windows_devices_custom-3.1.0/pywinrt-version.txt +1 -0
- {winrt_windows_devices_custom-2.3.0 → winrt_windows_devices_custom-3.1.0}/requirements.txt +2 -2
- {winrt_windows_devices_custom-2.3.0 → winrt_windows_devices_custom-3.1.0}/setup.py +1 -1
- winrt_windows_devices_custom-3.1.0/winrt/_winrt_windows_devices_custom.pyi +93 -0
- {winrt_windows_devices_custom-2.3.0 → winrt_windows_devices_custom-3.1.0}/winrt/windows/devices/custom/__init__.py +8 -6
- {winrt_windows_devices_custom-2.3.0 → winrt_windows_devices_custom-3.1.0}/winrt_Windows.Devices.Custom.egg-info/PKG-INFO +7 -7
- winrt_windows_devices_custom-3.1.0/winrt_Windows.Devices.Custom.egg-info/requires.txt +5 -0
- winrt_windows_devices_custom-2.3.0/all-requirements.txt +0 -4
- winrt_windows_devices_custom-2.3.0/pywinrt-version.txt +0 -1
- winrt_windows_devices_custom-2.3.0/winrt/_winrt_windows_devices_custom.pyi +0 -74
- winrt_windows_devices_custom-2.3.0/winrt_Windows.Devices.Custom.egg-info/requires.txt +0 -5
- {winrt_windows_devices_custom-2.3.0 → winrt_windows_devices_custom-3.1.0}/README.md +0 -0
- {winrt_windows_devices_custom-2.3.0 → winrt_windows_devices_custom-3.1.0}/setup.cfg +0 -0
- {winrt_windows_devices_custom-2.3.0 → winrt_windows_devices_custom-3.1.0}/winrt/windows/devices/custom/py.typed +0 -0
- {winrt_windows_devices_custom-2.3.0 → winrt_windows_devices_custom-3.1.0}/winrt_Windows.Devices.Custom.egg-info/SOURCES.txt +0 -0
- {winrt_windows_devices_custom-2.3.0 → winrt_windows_devices_custom-3.1.0}/winrt_Windows.Devices.Custom.egg-info/dependency_links.txt +0 -0
- {winrt_windows_devices_custom-2.3.0 → winrt_windows_devices_custom-3.1.0}/winrt_Windows.Devices.Custom.egg-info/top_level.txt +0 -0
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
2
|
Name: winrt-Windows.Devices.Custom
|
|
3
|
-
Version:
|
|
3
|
+
Version: 3.1.0
|
|
4
4
|
Summary: Python projection of Windows Runtime (WinRT) APIs
|
|
5
|
-
License: MIT
|
|
5
|
+
License-Expression: MIT
|
|
6
6
|
Project-URL: Documentation, https://pywinrt.readthedocs.io
|
|
7
7
|
Project-URL: Repository, https://github.com/pywinrt/pywinrt
|
|
8
8
|
Project-URL: Changelog, https://github.com/pywinrt/pywinrt/blob/main/CHANGELOG.md
|
|
@@ -10,12 +10,12 @@ Classifier: Operating System :: Microsoft :: Windows
|
|
|
10
10
|
Classifier: Programming Language :: Python :: 3
|
|
11
11
|
Classifier: Programming Language :: Python :: Implementation :: CPython
|
|
12
12
|
Classifier: Intended Audience :: Developers
|
|
13
|
-
Requires-Python:
|
|
13
|
+
Requires-Python: >=3.9
|
|
14
14
|
Description-Content-Type: text/markdown
|
|
15
|
-
Requires-Dist: winrt-runtime==
|
|
15
|
+
Requires-Dist: winrt-runtime==3.1.0
|
|
16
16
|
Provides-Extra: all
|
|
17
|
-
Requires-Dist: winrt-Windows.Foundation[all]==
|
|
18
|
-
Requires-Dist: winrt-Windows.Storage.Streams[all]==
|
|
17
|
+
Requires-Dist: winrt-Windows.Foundation[all]==3.1.0; extra == "all"
|
|
18
|
+
Requires-Dist: winrt-Windows.Storage.Streams[all]==3.1.0; extra == "all"
|
|
19
19
|
|
|
20
20
|
<!-- warning: Please don't edit this file. It was automatically generated. -->
|
|
21
21
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// WARNING: Please don't edit this file. It was generated by Python/WinRT
|
|
1
|
+
// WARNING: Please don't edit this file. It was generated by Python/WinRT v3.1.0
|
|
2
2
|
|
|
3
3
|
#include "py.Windows.Devices.Custom.h"
|
|
4
4
|
|
|
@@ -23,7 +23,7 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
23
23
|
|
|
24
24
|
static PyObject* CustomDevice_FromIdAsync(PyObject* /*unused*/, PyObject* args) noexcept
|
|
25
25
|
{
|
|
26
|
-
auto arg_count =
|
|
26
|
+
auto arg_count = PyTuple_GET_SIZE(args);
|
|
27
27
|
|
|
28
28
|
if (arg_count == 3)
|
|
29
29
|
{
|
|
@@ -46,7 +46,11 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
46
46
|
auto param1 = py::convert_to<winrt::Windows::Devices::Custom::DeviceAccessMode>(args, 1);
|
|
47
47
|
auto param2 = py::convert_to<winrt::Windows::Devices::Custom::DeviceSharingMode>(args, 2);
|
|
48
48
|
|
|
49
|
-
return py::convert(
|
|
49
|
+
return py::convert([&]()
|
|
50
|
+
{
|
|
51
|
+
auto _gil = release_gil();
|
|
52
|
+
return winrt::Windows::Devices::Custom::CustomDevice::FromIdAsync(param0, param1, param2);
|
|
53
|
+
}());
|
|
50
54
|
}
|
|
51
55
|
catch (...)
|
|
52
56
|
{
|
|
@@ -63,7 +67,7 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
63
67
|
|
|
64
68
|
static PyObject* CustomDevice_GetDeviceSelector(PyObject* /*unused*/, PyObject* args) noexcept
|
|
65
69
|
{
|
|
66
|
-
auto arg_count =
|
|
70
|
+
auto arg_count = PyTuple_GET_SIZE(args);
|
|
67
71
|
|
|
68
72
|
if (arg_count == 1)
|
|
69
73
|
{
|
|
@@ -84,7 +88,11 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
84
88
|
|
|
85
89
|
auto param0 = py::convert_to<winrt::guid>(args, 0);
|
|
86
90
|
|
|
87
|
-
return py::convert(
|
|
91
|
+
return py::convert([&]()
|
|
92
|
+
{
|
|
93
|
+
auto _gil = release_gil();
|
|
94
|
+
return winrt::Windows::Devices::Custom::CustomDevice::GetDeviceSelector(param0);
|
|
95
|
+
}());
|
|
88
96
|
}
|
|
89
97
|
catch (...)
|
|
90
98
|
{
|
|
@@ -101,7 +109,7 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
101
109
|
|
|
102
110
|
static PyObject* CustomDevice_SendIOControlAsync(py::wrapper::Windows::Devices::Custom::CustomDevice* self, PyObject* args) noexcept
|
|
103
111
|
{
|
|
104
|
-
auto arg_count =
|
|
112
|
+
auto arg_count = PyTuple_GET_SIZE(args);
|
|
105
113
|
|
|
106
114
|
if (arg_count == 3)
|
|
107
115
|
{
|
|
@@ -124,7 +132,11 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
124
132
|
auto param1 = py::convert_to<winrt::Windows::Storage::Streams::IBuffer>(args, 1);
|
|
125
133
|
auto param2 = py::convert_to<winrt::Windows::Storage::Streams::IBuffer>(args, 2);
|
|
126
134
|
|
|
127
|
-
return py::convert(
|
|
135
|
+
return py::convert([&]()
|
|
136
|
+
{
|
|
137
|
+
auto _gil = release_gil();
|
|
138
|
+
return self->obj.SendIOControlAsync(param0, param1, param2);
|
|
139
|
+
}());
|
|
128
140
|
}
|
|
129
141
|
catch (...)
|
|
130
142
|
{
|
|
@@ -141,7 +153,7 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
141
153
|
|
|
142
154
|
static PyObject* CustomDevice_TrySendIOControlAsync(py::wrapper::Windows::Devices::Custom::CustomDevice* self, PyObject* args) noexcept
|
|
143
155
|
{
|
|
144
|
-
auto arg_count =
|
|
156
|
+
auto arg_count = PyTuple_GET_SIZE(args);
|
|
145
157
|
|
|
146
158
|
if (arg_count == 3)
|
|
147
159
|
{
|
|
@@ -164,7 +176,11 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
164
176
|
auto param1 = py::convert_to<winrt::Windows::Storage::Streams::IBuffer>(args, 1);
|
|
165
177
|
auto param2 = py::convert_to<winrt::Windows::Storage::Streams::IBuffer>(args, 2);
|
|
166
178
|
|
|
167
|
-
return py::convert(
|
|
179
|
+
return py::convert([&]()
|
|
180
|
+
{
|
|
181
|
+
auto _gil = release_gil();
|
|
182
|
+
return self->obj.TrySendIOControlAsync(param0, param1, param2);
|
|
183
|
+
}());
|
|
168
184
|
}
|
|
169
185
|
catch (...)
|
|
170
186
|
{
|
|
@@ -196,7 +212,11 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
196
212
|
return nullptr;
|
|
197
213
|
}
|
|
198
214
|
|
|
199
|
-
return py::convert(
|
|
215
|
+
return py::convert([&]()
|
|
216
|
+
{
|
|
217
|
+
auto _gil = release_gil();
|
|
218
|
+
return self->obj.InputStream();
|
|
219
|
+
}());
|
|
200
220
|
}
|
|
201
221
|
catch (...)
|
|
202
222
|
{
|
|
@@ -222,7 +242,11 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
222
242
|
return nullptr;
|
|
223
243
|
}
|
|
224
244
|
|
|
225
|
-
return py::convert(
|
|
245
|
+
return py::convert([&]()
|
|
246
|
+
{
|
|
247
|
+
auto _gil = release_gil();
|
|
248
|
+
return self->obj.OutputStream();
|
|
249
|
+
}());
|
|
226
250
|
}
|
|
227
251
|
catch (...)
|
|
228
252
|
{
|
|
@@ -256,26 +280,23 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
256
280
|
}
|
|
257
281
|
|
|
258
282
|
static PyMethodDef _methods_CustomDevice[] = {
|
|
259
|
-
{ "
|
|
260
|
-
{ "
|
|
283
|
+
{ "send_io_control_async", reinterpret_cast<PyCFunction>(CustomDevice_SendIOControlAsync), METH_VARARGS, nullptr },
|
|
284
|
+
{ "try_send_io_control_async", reinterpret_cast<PyCFunction>(CustomDevice_TrySendIOControlAsync), METH_VARARGS, nullptr },
|
|
261
285
|
{ "_assign_array_", _assign_array_CustomDevice, METH_O | METH_STATIC, nullptr },
|
|
262
286
|
{ "_from", reinterpret_cast<PyCFunction>(_from_CustomDevice), METH_O | METH_STATIC, nullptr },
|
|
263
|
-
{ }
|
|
264
|
-
};
|
|
287
|
+
{ }};
|
|
265
288
|
|
|
266
289
|
static PyGetSetDef _getset_CustomDevice[] = {
|
|
267
290
|
{ "input_stream", reinterpret_cast<getter>(CustomDevice_get_InputStream), nullptr, nullptr, nullptr },
|
|
268
291
|
{ "output_stream", reinterpret_cast<getter>(CustomDevice_get_OutputStream), nullptr, nullptr, nullptr },
|
|
269
|
-
{ }
|
|
270
|
-
};
|
|
292
|
+
{ }};
|
|
271
293
|
|
|
272
294
|
static PyType_Slot _type_slots_CustomDevice[] = {
|
|
273
295
|
{ Py_tp_new, reinterpret_cast<void*>(_new_CustomDevice) },
|
|
274
296
|
{ Py_tp_dealloc, reinterpret_cast<void*>(_dealloc_CustomDevice) },
|
|
275
297
|
{ Py_tp_methods, reinterpret_cast<void*>(_methods_CustomDevice) },
|
|
276
298
|
{ Py_tp_getset, reinterpret_cast<void*>(_getset_CustomDevice) },
|
|
277
|
-
{ }
|
|
278
|
-
};
|
|
299
|
+
{ }};
|
|
279
300
|
|
|
280
301
|
static PyType_Spec type_spec_CustomDevice = {
|
|
281
302
|
"winrt._winrt_windows_devices_custom.CustomDevice",
|
|
@@ -285,14 +306,12 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
285
306
|
_type_slots_CustomDevice};
|
|
286
307
|
|
|
287
308
|
static PyGetSetDef getset_CustomDevice_Static[] = {
|
|
288
|
-
{ }
|
|
289
|
-
};
|
|
309
|
+
{ }};
|
|
290
310
|
|
|
291
311
|
static PyMethodDef methods_CustomDevice_Static[] = {
|
|
292
312
|
{ "from_id_async", reinterpret_cast<PyCFunction>(CustomDevice_FromIdAsync), METH_VARARGS, nullptr },
|
|
293
313
|
{ "get_device_selector", reinterpret_cast<PyCFunction>(CustomDevice_GetDeviceSelector), METH_VARARGS, nullptr },
|
|
294
|
-
{ }
|
|
295
|
-
};
|
|
314
|
+
{ }};
|
|
296
315
|
|
|
297
316
|
static PyType_Slot type_slots_CustomDevice_Static[] =
|
|
298
317
|
{
|
|
@@ -302,26 +321,24 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
302
321
|
{ }
|
|
303
322
|
};
|
|
304
323
|
|
|
305
|
-
static PyType_Spec type_spec_CustomDevice_Static =
|
|
306
|
-
{
|
|
324
|
+
static PyType_Spec type_spec_CustomDevice_Static = {
|
|
307
325
|
"winrt._winrt_windows_devices_custom.CustomDevice_Static",
|
|
308
326
|
static_cast<int>(PyType_Type.tp_basicsize),
|
|
309
327
|
static_cast<int>(PyType_Type.tp_itemsize),
|
|
310
328
|
Py_TPFLAGS_DEFAULT,
|
|
311
|
-
type_slots_CustomDevice_Static
|
|
312
|
-
};
|
|
329
|
+
type_slots_CustomDevice_Static};
|
|
313
330
|
|
|
314
331
|
// ----- IOControlCode class --------------------
|
|
315
332
|
|
|
316
333
|
static PyObject* _new_IOControlCode(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
|
|
317
334
|
{
|
|
318
|
-
if (kwds
|
|
335
|
+
if (kwds)
|
|
319
336
|
{
|
|
320
337
|
py::set_invalid_kwd_args_error();
|
|
321
338
|
return nullptr;
|
|
322
339
|
}
|
|
323
340
|
|
|
324
|
-
auto arg_count =
|
|
341
|
+
auto arg_count = PyTuple_GET_SIZE(args);
|
|
325
342
|
if (arg_count == 4)
|
|
326
343
|
{
|
|
327
344
|
try
|
|
@@ -372,7 +389,11 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
372
389
|
return nullptr;
|
|
373
390
|
}
|
|
374
391
|
|
|
375
|
-
return py::convert(
|
|
392
|
+
return py::convert([&]()
|
|
393
|
+
{
|
|
394
|
+
auto _gil = release_gil();
|
|
395
|
+
return self->obj.AccessMode();
|
|
396
|
+
}());
|
|
376
397
|
}
|
|
377
398
|
catch (...)
|
|
378
399
|
{
|
|
@@ -398,7 +419,11 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
398
419
|
return nullptr;
|
|
399
420
|
}
|
|
400
421
|
|
|
401
|
-
return py::convert(
|
|
422
|
+
return py::convert([&]()
|
|
423
|
+
{
|
|
424
|
+
auto _gil = release_gil();
|
|
425
|
+
return self->obj.BufferingMethod();
|
|
426
|
+
}());
|
|
402
427
|
}
|
|
403
428
|
catch (...)
|
|
404
429
|
{
|
|
@@ -424,7 +449,11 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
424
449
|
return nullptr;
|
|
425
450
|
}
|
|
426
451
|
|
|
427
|
-
return py::convert(
|
|
452
|
+
return py::convert([&]()
|
|
453
|
+
{
|
|
454
|
+
auto _gil = release_gil();
|
|
455
|
+
return self->obj.ControlCode();
|
|
456
|
+
}());
|
|
428
457
|
}
|
|
429
458
|
catch (...)
|
|
430
459
|
{
|
|
@@ -450,7 +479,11 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
450
479
|
return nullptr;
|
|
451
480
|
}
|
|
452
481
|
|
|
453
|
-
return py::convert(
|
|
482
|
+
return py::convert([&]()
|
|
483
|
+
{
|
|
484
|
+
auto _gil = release_gil();
|
|
485
|
+
return self->obj.DeviceType();
|
|
486
|
+
}());
|
|
454
487
|
}
|
|
455
488
|
catch (...)
|
|
456
489
|
{
|
|
@@ -476,7 +509,11 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
476
509
|
return nullptr;
|
|
477
510
|
}
|
|
478
511
|
|
|
479
|
-
return py::convert(
|
|
512
|
+
return py::convert([&]()
|
|
513
|
+
{
|
|
514
|
+
auto _gil = release_gil();
|
|
515
|
+
return self->obj.Function();
|
|
516
|
+
}());
|
|
480
517
|
}
|
|
481
518
|
catch (...)
|
|
482
519
|
{
|
|
@@ -512,8 +549,7 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
512
549
|
static PyMethodDef _methods_IOControlCode[] = {
|
|
513
550
|
{ "_assign_array_", _assign_array_IOControlCode, METH_O | METH_STATIC, nullptr },
|
|
514
551
|
{ "_from", reinterpret_cast<PyCFunction>(_from_IOControlCode), METH_O | METH_STATIC, nullptr },
|
|
515
|
-
{ }
|
|
516
|
-
};
|
|
552
|
+
{ }};
|
|
517
553
|
|
|
518
554
|
static PyGetSetDef _getset_IOControlCode[] = {
|
|
519
555
|
{ "access_mode", reinterpret_cast<getter>(IOControlCode_get_AccessMode), nullptr, nullptr, nullptr },
|
|
@@ -521,16 +557,14 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
521
557
|
{ "control_code", reinterpret_cast<getter>(IOControlCode_get_ControlCode), nullptr, nullptr, nullptr },
|
|
522
558
|
{ "device_type", reinterpret_cast<getter>(IOControlCode_get_DeviceType), nullptr, nullptr, nullptr },
|
|
523
559
|
{ "function", reinterpret_cast<getter>(IOControlCode_get_Function), nullptr, nullptr, nullptr },
|
|
524
|
-
{ }
|
|
525
|
-
};
|
|
560
|
+
{ }};
|
|
526
561
|
|
|
527
562
|
static PyType_Slot _type_slots_IOControlCode[] = {
|
|
528
563
|
{ Py_tp_new, reinterpret_cast<void*>(_new_IOControlCode) },
|
|
529
564
|
{ Py_tp_dealloc, reinterpret_cast<void*>(_dealloc_IOControlCode) },
|
|
530
565
|
{ Py_tp_methods, reinterpret_cast<void*>(_methods_IOControlCode) },
|
|
531
566
|
{ Py_tp_getset, reinterpret_cast<void*>(_getset_IOControlCode) },
|
|
532
|
-
{ }
|
|
533
|
-
};
|
|
567
|
+
{ }};
|
|
534
568
|
|
|
535
569
|
static PyType_Spec type_spec_IOControlCode = {
|
|
536
570
|
"winrt._winrt_windows_devices_custom.IOControlCode",
|
|
@@ -565,7 +599,11 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
565
599
|
return nullptr;
|
|
566
600
|
}
|
|
567
601
|
|
|
568
|
-
return py::convert(
|
|
602
|
+
return py::convert([&]()
|
|
603
|
+
{
|
|
604
|
+
auto _gil = release_gil();
|
|
605
|
+
return winrt::Windows::Devices::Custom::KnownDeviceTypes::Unknown();
|
|
606
|
+
}());
|
|
569
607
|
}
|
|
570
608
|
catch (...)
|
|
571
609
|
{
|
|
@@ -575,19 +613,16 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
575
613
|
}
|
|
576
614
|
|
|
577
615
|
static PyMethodDef _methods_KnownDeviceTypes[] = {
|
|
578
|
-
{ }
|
|
579
|
-
};
|
|
616
|
+
{ }};
|
|
580
617
|
|
|
581
618
|
static PyGetSetDef _getset_KnownDeviceTypes[] = {
|
|
582
|
-
{ }
|
|
583
|
-
};
|
|
619
|
+
{ }};
|
|
584
620
|
|
|
585
621
|
static PyType_Slot _type_slots_KnownDeviceTypes[] = {
|
|
586
622
|
{ Py_tp_new, reinterpret_cast<void*>(_new_KnownDeviceTypes) },
|
|
587
623
|
{ Py_tp_methods, reinterpret_cast<void*>(_methods_KnownDeviceTypes) },
|
|
588
624
|
{ Py_tp_getset, reinterpret_cast<void*>(_getset_KnownDeviceTypes) },
|
|
589
|
-
{ }
|
|
590
|
-
};
|
|
625
|
+
{ }};
|
|
591
626
|
|
|
592
627
|
static PyType_Spec type_spec_KnownDeviceTypes = {
|
|
593
628
|
"winrt._winrt_windows_devices_custom.KnownDeviceTypes",
|
|
@@ -598,12 +633,10 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
598
633
|
|
|
599
634
|
static PyGetSetDef getset_KnownDeviceTypes_Static[] = {
|
|
600
635
|
{ "unknown", reinterpret_cast<getter>(KnownDeviceTypes_get_Unknown), nullptr, nullptr, nullptr },
|
|
601
|
-
{ }
|
|
602
|
-
};
|
|
636
|
+
{ }};
|
|
603
637
|
|
|
604
638
|
static PyMethodDef methods_KnownDeviceTypes_Static[] = {
|
|
605
|
-
{ }
|
|
606
|
-
};
|
|
639
|
+
{ }};
|
|
607
640
|
|
|
608
641
|
static PyType_Slot type_slots_KnownDeviceTypes_Static[] =
|
|
609
642
|
{
|
|
@@ -613,23 +646,23 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
613
646
|
{ }
|
|
614
647
|
};
|
|
615
648
|
|
|
616
|
-
static PyType_Spec type_spec_KnownDeviceTypes_Static =
|
|
617
|
-
{
|
|
649
|
+
static PyType_Spec type_spec_KnownDeviceTypes_Static = {
|
|
618
650
|
"winrt._winrt_windows_devices_custom.KnownDeviceTypes_Static",
|
|
619
651
|
static_cast<int>(PyType_Type.tp_basicsize),
|
|
620
652
|
static_cast<int>(PyType_Type.tp_itemsize),
|
|
621
653
|
Py_TPFLAGS_DEFAULT,
|
|
622
|
-
type_slots_KnownDeviceTypes_Static
|
|
623
|
-
};
|
|
654
|
+
type_slots_KnownDeviceTypes_Static};
|
|
624
655
|
|
|
625
656
|
// ----- IIOControlCode interface --------------------
|
|
626
657
|
|
|
658
|
+
#if PY_VERSION_HEX < 0x030A0000
|
|
627
659
|
static PyObject* _new_IIOControlCode(PyTypeObject* /*unused*/, PyObject* /*unused*/, PyObject* /*unused*/) noexcept
|
|
628
660
|
{
|
|
629
661
|
static_assert(py::py_type<winrt::Windows::Devices::Custom::IIOControlCode>::type_name);
|
|
630
662
|
py::set_invalid_activation_error(py::py_type<winrt::Windows::Devices::Custom::IIOControlCode>::type_name);
|
|
631
663
|
return nullptr;
|
|
632
664
|
}
|
|
665
|
+
#endif
|
|
633
666
|
|
|
634
667
|
static void _dealloc_IIOControlCode(py::wrapper::Windows::Devices::Custom::IIOControlCode* self) noexcept
|
|
635
668
|
{
|
|
@@ -656,7 +689,11 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
656
689
|
return nullptr;
|
|
657
690
|
}
|
|
658
691
|
|
|
659
|
-
return py::convert(
|
|
692
|
+
return py::convert([&]()
|
|
693
|
+
{
|
|
694
|
+
auto _gil = release_gil();
|
|
695
|
+
return self->obj.AccessMode();
|
|
696
|
+
}());
|
|
660
697
|
}
|
|
661
698
|
catch (...)
|
|
662
699
|
{
|
|
@@ -682,7 +719,11 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
682
719
|
return nullptr;
|
|
683
720
|
}
|
|
684
721
|
|
|
685
|
-
return py::convert(
|
|
722
|
+
return py::convert([&]()
|
|
723
|
+
{
|
|
724
|
+
auto _gil = release_gil();
|
|
725
|
+
return self->obj.BufferingMethod();
|
|
726
|
+
}());
|
|
686
727
|
}
|
|
687
728
|
catch (...)
|
|
688
729
|
{
|
|
@@ -708,7 +749,11 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
708
749
|
return nullptr;
|
|
709
750
|
}
|
|
710
751
|
|
|
711
|
-
return py::convert(
|
|
752
|
+
return py::convert([&]()
|
|
753
|
+
{
|
|
754
|
+
auto _gil = release_gil();
|
|
755
|
+
return self->obj.ControlCode();
|
|
756
|
+
}());
|
|
712
757
|
}
|
|
713
758
|
catch (...)
|
|
714
759
|
{
|
|
@@ -734,7 +779,11 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
734
779
|
return nullptr;
|
|
735
780
|
}
|
|
736
781
|
|
|
737
|
-
return py::convert(
|
|
782
|
+
return py::convert([&]()
|
|
783
|
+
{
|
|
784
|
+
auto _gil = release_gil();
|
|
785
|
+
return self->obj.DeviceType();
|
|
786
|
+
}());
|
|
738
787
|
}
|
|
739
788
|
catch (...)
|
|
740
789
|
{
|
|
@@ -760,7 +809,11 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
760
809
|
return nullptr;
|
|
761
810
|
}
|
|
762
811
|
|
|
763
|
-
return py::convert(
|
|
812
|
+
return py::convert([&]()
|
|
813
|
+
{
|
|
814
|
+
auto _gil = release_gil();
|
|
815
|
+
return self->obj.Function();
|
|
816
|
+
}());
|
|
764
817
|
}
|
|
765
818
|
catch (...)
|
|
766
819
|
{
|
|
@@ -769,6 +822,145 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
769
822
|
}
|
|
770
823
|
}
|
|
771
824
|
|
|
825
|
+
static PyMethodDef _methods_IIOControlCode[] = {
|
|
826
|
+
{ }};
|
|
827
|
+
|
|
828
|
+
static PyGetSetDef _getset_IIOControlCode[] = {
|
|
829
|
+
{ "access_mode", reinterpret_cast<getter>(IIOControlCode_get_AccessMode), nullptr, nullptr, nullptr },
|
|
830
|
+
{ "buffering_method", reinterpret_cast<getter>(IIOControlCode_get_BufferingMethod), nullptr, nullptr, nullptr },
|
|
831
|
+
{ "control_code", reinterpret_cast<getter>(IIOControlCode_get_ControlCode), nullptr, nullptr, nullptr },
|
|
832
|
+
{ "device_type", reinterpret_cast<getter>(IIOControlCode_get_DeviceType), nullptr, nullptr, nullptr },
|
|
833
|
+
{ "function", reinterpret_cast<getter>(IIOControlCode_get_Function), nullptr, nullptr, nullptr },
|
|
834
|
+
{ }};
|
|
835
|
+
|
|
836
|
+
static PyType_Slot _type_slots_IIOControlCode[] = {
|
|
837
|
+
#if PY_VERSION_HEX < 0x030A0000
|
|
838
|
+
{ Py_tp_new, reinterpret_cast<void*>(_new_IIOControlCode) },
|
|
839
|
+
#endif
|
|
840
|
+
{ Py_tp_dealloc, reinterpret_cast<void*>(_dealloc_IIOControlCode) },
|
|
841
|
+
{ Py_tp_methods, reinterpret_cast<void*>(_methods_IIOControlCode) },
|
|
842
|
+
{ Py_tp_getset, reinterpret_cast<void*>(_getset_IIOControlCode) },
|
|
843
|
+
{ }};
|
|
844
|
+
|
|
845
|
+
static PyType_Spec type_spec_IIOControlCode = {
|
|
846
|
+
"winrt._winrt_windows_devices_custom._IIOControlCode",
|
|
847
|
+
sizeof(py::wrapper::Windows::Devices::Custom::IIOControlCode),
|
|
848
|
+
0,
|
|
849
|
+
Py_TPFLAGS_DEFAULT
|
|
850
|
+
#if PY_VERSION_HEX >= 0x030A0000
|
|
851
|
+
| Py_TPFLAGS_DISALLOW_INSTANTIATION
|
|
852
|
+
#endif
|
|
853
|
+
,
|
|
854
|
+
_type_slots_IIOControlCode};
|
|
855
|
+
|
|
856
|
+
struct ImplementsIIOControlCode : py::ImplementsInterfaceT<ImplementsIIOControlCode, winrt::Windows::Devices::Custom::IIOControlCode>
|
|
857
|
+
{
|
|
858
|
+
ImplementsIIOControlCode() = delete;
|
|
859
|
+
ImplementsIIOControlCode(PyObject* py_obj, winrt::impl::inspectable_abi* runtime_class) : py::ImplementsInterfaceT<ImplementsIIOControlCode, winrt::Windows::Devices::Custom::IIOControlCode>(py_obj, runtime_class)
|
|
860
|
+
{
|
|
861
|
+
}
|
|
862
|
+
|
|
863
|
+
auto AccessMode()
|
|
864
|
+
{
|
|
865
|
+
try
|
|
866
|
+
{
|
|
867
|
+
py::pyobj_handle self{this->get_py_obj()};
|
|
868
|
+
|
|
869
|
+
py::pyobj_handle value{PyObject_GetAttrString(self.get(), "access_mode")};
|
|
870
|
+
if (!value)
|
|
871
|
+
{
|
|
872
|
+
throw python_exception();
|
|
873
|
+
}
|
|
874
|
+
|
|
875
|
+
return py::convert_to<winrt::Windows::Devices::Custom::IOControlAccessMode>(value.get());
|
|
876
|
+
}
|
|
877
|
+
catch (python_exception)
|
|
878
|
+
{
|
|
879
|
+
py::write_unraisable_and_throw();
|
|
880
|
+
}
|
|
881
|
+
}
|
|
882
|
+
|
|
883
|
+
auto BufferingMethod()
|
|
884
|
+
{
|
|
885
|
+
try
|
|
886
|
+
{
|
|
887
|
+
py::pyobj_handle self{this->get_py_obj()};
|
|
888
|
+
|
|
889
|
+
py::pyobj_handle value{PyObject_GetAttrString(self.get(), "buffering_method")};
|
|
890
|
+
if (!value)
|
|
891
|
+
{
|
|
892
|
+
throw python_exception();
|
|
893
|
+
}
|
|
894
|
+
|
|
895
|
+
return py::convert_to<winrt::Windows::Devices::Custom::IOControlBufferingMethod>(value.get());
|
|
896
|
+
}
|
|
897
|
+
catch (python_exception)
|
|
898
|
+
{
|
|
899
|
+
py::write_unraisable_and_throw();
|
|
900
|
+
}
|
|
901
|
+
}
|
|
902
|
+
|
|
903
|
+
auto ControlCode()
|
|
904
|
+
{
|
|
905
|
+
try
|
|
906
|
+
{
|
|
907
|
+
py::pyobj_handle self{this->get_py_obj()};
|
|
908
|
+
|
|
909
|
+
py::pyobj_handle value{PyObject_GetAttrString(self.get(), "control_code")};
|
|
910
|
+
if (!value)
|
|
911
|
+
{
|
|
912
|
+
throw python_exception();
|
|
913
|
+
}
|
|
914
|
+
|
|
915
|
+
return py::convert_to<uint32_t>(value.get());
|
|
916
|
+
}
|
|
917
|
+
catch (python_exception)
|
|
918
|
+
{
|
|
919
|
+
py::write_unraisable_and_throw();
|
|
920
|
+
}
|
|
921
|
+
}
|
|
922
|
+
|
|
923
|
+
auto DeviceType()
|
|
924
|
+
{
|
|
925
|
+
try
|
|
926
|
+
{
|
|
927
|
+
py::pyobj_handle self{this->get_py_obj()};
|
|
928
|
+
|
|
929
|
+
py::pyobj_handle value{PyObject_GetAttrString(self.get(), "device_type")};
|
|
930
|
+
if (!value)
|
|
931
|
+
{
|
|
932
|
+
throw python_exception();
|
|
933
|
+
}
|
|
934
|
+
|
|
935
|
+
return py::convert_to<uint16_t>(value.get());
|
|
936
|
+
}
|
|
937
|
+
catch (python_exception)
|
|
938
|
+
{
|
|
939
|
+
py::write_unraisable_and_throw();
|
|
940
|
+
}
|
|
941
|
+
}
|
|
942
|
+
|
|
943
|
+
auto Function()
|
|
944
|
+
{
|
|
945
|
+
try
|
|
946
|
+
{
|
|
947
|
+
py::pyobj_handle self{this->get_py_obj()};
|
|
948
|
+
|
|
949
|
+
py::pyobj_handle value{PyObject_GetAttrString(self.get(), "function")};
|
|
950
|
+
if (!value)
|
|
951
|
+
{
|
|
952
|
+
throw python_exception();
|
|
953
|
+
}
|
|
954
|
+
|
|
955
|
+
return py::convert_to<uint16_t>(value.get());
|
|
956
|
+
}
|
|
957
|
+
catch (python_exception)
|
|
958
|
+
{
|
|
959
|
+
py::write_unraisable_and_throw();
|
|
960
|
+
}
|
|
961
|
+
}
|
|
962
|
+
};
|
|
963
|
+
|
|
772
964
|
static PyObject* _assign_array_IIOControlCode(PyObject* /*unused*/, PyObject* arg) noexcept
|
|
773
965
|
{
|
|
774
966
|
auto array = std::make_unique<py::ComArray<winrt::Windows::Devices::Custom::IIOControlCode>>();
|
|
@@ -793,35 +985,63 @@ namespace py::cpp::Windows::Devices::Custom
|
|
|
793
985
|
}
|
|
794
986
|
}
|
|
795
987
|
|
|
796
|
-
static
|
|
988
|
+
static PyObject* _guid_ImplementsIIOControlCode(PyObject* /*unused*/, PyObject* /*unused*/) noexcept
|
|
989
|
+
{
|
|
990
|
+
try
|
|
991
|
+
{
|
|
992
|
+
return py::convert(winrt::guid_of<winrt::Windows::Devices::Custom::IIOControlCode>());
|
|
993
|
+
}
|
|
994
|
+
catch (...)
|
|
995
|
+
{
|
|
996
|
+
py::to_PyErr();
|
|
997
|
+
return nullptr;
|
|
998
|
+
}
|
|
999
|
+
}
|
|
1000
|
+
|
|
1001
|
+
static PyObject* _make_ImplementsIIOControlCode(PyObject* /*unused*/, PyObject* args) noexcept
|
|
1002
|
+
{
|
|
1003
|
+
try
|
|
1004
|
+
{
|
|
1005
|
+
PyObject* py_obj;
|
|
1006
|
+
winrt::impl::inspectable_abi* runtime_class;
|
|
1007
|
+
|
|
1008
|
+
if (!PyArg_ParseTuple(args, "On", &py_obj, &runtime_class))
|
|
1009
|
+
{
|
|
1010
|
+
return nullptr;
|
|
1011
|
+
}
|
|
1012
|
+
|
|
1013
|
+
auto iface{std::make_unique<ImplementsIIOControlCode>(py_obj, runtime_class)};
|
|
1014
|
+
|
|
1015
|
+
return PyLong_FromVoidPtr(iface.release());
|
|
1016
|
+
}
|
|
1017
|
+
catch (...)
|
|
1018
|
+
{
|
|
1019
|
+
py::to_PyErr();
|
|
1020
|
+
return nullptr;
|
|
1021
|
+
}
|
|
1022
|
+
}
|
|
1023
|
+
|
|
1024
|
+
static PyMethodDef methods_ImplementsIIOControlCode[] = {
|
|
797
1025
|
{ "_assign_array_", _assign_array_IIOControlCode, METH_O | METH_STATIC, nullptr },
|
|
798
1026
|
{ "_from", reinterpret_cast<PyCFunction>(_from_IIOControlCode), METH_O | METH_STATIC, nullptr },
|
|
799
|
-
{ }
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
static PyGetSetDef _getset_IIOControlCode[] = {
|
|
803
|
-
{ "access_mode", reinterpret_cast<getter>(IIOControlCode_get_AccessMode), nullptr, nullptr, nullptr },
|
|
804
|
-
{ "buffering_method", reinterpret_cast<getter>(IIOControlCode_get_BufferingMethod), nullptr, nullptr, nullptr },
|
|
805
|
-
{ "control_code", reinterpret_cast<getter>(IIOControlCode_get_ControlCode), nullptr, nullptr, nullptr },
|
|
806
|
-
{ "device_type", reinterpret_cast<getter>(IIOControlCode_get_DeviceType), nullptr, nullptr, nullptr },
|
|
807
|
-
{ "function", reinterpret_cast<getter>(IIOControlCode_get_Function), nullptr, nullptr, nullptr },
|
|
808
|
-
{ }
|
|
809
|
-
};
|
|
1027
|
+
{ "_guid_", reinterpret_cast<PyCFunction>(_guid_ImplementsIIOControlCode), METH_NOARGS | METH_STATIC, nullptr },
|
|
1028
|
+
{ "_make_", reinterpret_cast<PyCFunction>(_make_ImplementsIIOControlCode), METH_VARARGS | METH_STATIC, nullptr },
|
|
1029
|
+
{ }};
|
|
810
1030
|
|
|
811
|
-
static PyType_Slot
|
|
812
|
-
{
|
|
813
|
-
{
|
|
814
|
-
{ Py_tp_methods, reinterpret_cast<void*>(_methods_IIOControlCode) },
|
|
815
|
-
{ Py_tp_getset, reinterpret_cast<void*>(_getset_IIOControlCode) },
|
|
816
|
-
{ }
|
|
817
|
-
};
|
|
1031
|
+
static PyType_Slot type_slots_ImplementsIIOControlCode[] = {
|
|
1032
|
+
{ Py_tp_methods, reinterpret_cast<void*>(methods_ImplementsIIOControlCode) },
|
|
1033
|
+
{ }};
|
|
818
1034
|
|
|
819
|
-
static PyType_Spec
|
|
1035
|
+
static PyType_Spec type_spec_ImplementsIIOControlCode = {
|
|
820
1036
|
"winrt._winrt_windows_devices_custom.IIOControlCode",
|
|
821
|
-
sizeof(py::wrapper::Windows::Devices::Custom::IIOControlCode),
|
|
822
1037
|
0,
|
|
823
|
-
|
|
824
|
-
|
|
1038
|
+
0,
|
|
1039
|
+
Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE
|
|
1040
|
+
#if PY_VERSION_HEX >= 0x030A0000
|
|
1041
|
+
| Py_TPFLAGS_DISALLOW_INSTANTIATION
|
|
1042
|
+
#endif
|
|
1043
|
+
,
|
|
1044
|
+
type_slots_ImplementsIIOControlCode};
|
|
825
1045
|
|
|
826
1046
|
// ----- Windows.Devices.Custom Initialization --------------------
|
|
827
1047
|
|
|
@@ -855,6 +1075,12 @@ PyMODINIT_FUNC PyInit__winrt_windows_devices_custom(void) noexcept
|
|
|
855
1075
|
return nullptr;
|
|
856
1076
|
}
|
|
857
1077
|
|
|
1078
|
+
auto inspectable_meta_type = py::get_inspectable_meta_type();
|
|
1079
|
+
if (!inspectable_meta_type)
|
|
1080
|
+
{
|
|
1081
|
+
return nullptr;
|
|
1082
|
+
}
|
|
1083
|
+
|
|
858
1084
|
auto object_type = py::get_object_type();
|
|
859
1085
|
if (!object_type)
|
|
860
1086
|
{
|
|
@@ -868,7 +1094,13 @@ PyMODINIT_FUNC PyInit__winrt_windows_devices_custom(void) noexcept
|
|
|
868
1094
|
return nullptr;
|
|
869
1095
|
}
|
|
870
1096
|
|
|
871
|
-
py::pyobj_handle
|
|
1097
|
+
py::pyobj_handle CustomDevice_Static_bases{PyTuple_Pack(1, reinterpret_cast<PyObject*>(inspectable_meta_type))};
|
|
1098
|
+
if (!CustomDevice_Static_bases)
|
|
1099
|
+
{
|
|
1100
|
+
return nullptr;
|
|
1101
|
+
}
|
|
1102
|
+
|
|
1103
|
+
py::pyobj_handle type_CustomDevice_Static{PyType_FromSpecWithBases(&type_spec_CustomDevice_Static, CustomDevice_Static_bases.get())};
|
|
872
1104
|
if (!type_CustomDevice_Static)
|
|
873
1105
|
{
|
|
874
1106
|
return nullptr;
|
|
@@ -880,13 +1112,19 @@ PyMODINIT_FUNC PyInit__winrt_windows_devices_custom(void) noexcept
|
|
|
880
1112
|
return nullptr;
|
|
881
1113
|
}
|
|
882
1114
|
|
|
883
|
-
py::pytype_handle IOControlCode_type{py::register_python_type(module.get(), &type_spec_IOControlCode, object_bases.get(),
|
|
1115
|
+
py::pytype_handle IOControlCode_type{py::register_python_type(module.get(), &type_spec_IOControlCode, object_bases.get(), inspectable_meta_type)};
|
|
884
1116
|
if (!IOControlCode_type)
|
|
885
1117
|
{
|
|
886
1118
|
return nullptr;
|
|
887
1119
|
}
|
|
888
1120
|
|
|
889
|
-
py::pyobj_handle
|
|
1121
|
+
py::pyobj_handle KnownDeviceTypes_Static_bases{PyTuple_Pack(1, reinterpret_cast<PyObject*>(inspectable_meta_type))};
|
|
1122
|
+
if (!KnownDeviceTypes_Static_bases)
|
|
1123
|
+
{
|
|
1124
|
+
return nullptr;
|
|
1125
|
+
}
|
|
1126
|
+
|
|
1127
|
+
py::pyobj_handle type_KnownDeviceTypes_Static{PyType_FromSpecWithBases(&type_spec_KnownDeviceTypes_Static, KnownDeviceTypes_Static_bases.get())};
|
|
890
1128
|
if (!type_KnownDeviceTypes_Static)
|
|
891
1129
|
{
|
|
892
1130
|
return nullptr;
|
|
@@ -904,6 +1142,17 @@ PyMODINIT_FUNC PyInit__winrt_windows_devices_custom(void) noexcept
|
|
|
904
1142
|
return nullptr;
|
|
905
1143
|
}
|
|
906
1144
|
|
|
1145
|
+
py::pytype_handle ImplementsIIOControlCode_type{py::register_python_type(module.get(), &type_spec_ImplementsIIOControlCode, nullptr, inspectable_meta_type)};
|
|
1146
|
+
if (!ImplementsIIOControlCode_type)
|
|
1147
|
+
{
|
|
1148
|
+
return nullptr;
|
|
1149
|
+
}
|
|
1150
|
+
|
|
1151
|
+
if (PyModule_AddType(module.get(), ImplementsIIOControlCode_type.get()) == -1)
|
|
1152
|
+
{
|
|
1153
|
+
return nullptr;
|
|
1154
|
+
}
|
|
1155
|
+
|
|
907
1156
|
|
|
908
1157
|
return module.detach();
|
|
909
1158
|
}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
# WARNING: Please don't edit this file. It was automatically generated.
|
|
2
2
|
|
|
3
3
|
[build-system]
|
|
4
|
-
requires = ["setuptools", "winrt-sdk"]
|
|
4
|
+
requires = ["setuptools>=78", "winrt-sdk"]
|
|
5
5
|
build-backend = "setuptools.build_meta"
|
|
6
6
|
|
|
7
7
|
[project]
|
|
8
8
|
name = "winrt-Windows.Devices.Custom"
|
|
9
9
|
description = "Python projection of Windows Runtime (WinRT) APIs"
|
|
10
10
|
readme = "README.md"
|
|
11
|
-
license =
|
|
11
|
+
license = "MIT"
|
|
12
12
|
classifiers = [
|
|
13
13
|
"Operating System :: Microsoft :: Windows",
|
|
14
14
|
"Programming Language :: Python :: 3",
|
|
@@ -16,7 +16,7 @@ classifiers = [
|
|
|
16
16
|
"Intended Audience :: Developers",
|
|
17
17
|
]
|
|
18
18
|
dynamic = ["version", "dependencies", "optional-dependencies"]
|
|
19
|
-
requires-python = ">=3.9
|
|
19
|
+
requires-python = ">=3.9"
|
|
20
20
|
|
|
21
21
|
[project.urls]
|
|
22
22
|
# Homepage = "https://github.com/pywinrt/pywinrt"
|
|
@@ -34,7 +34,7 @@ optional-dependencies.all = { file = "all-requirements.txt" }
|
|
|
34
34
|
|
|
35
35
|
[tool.cibuildwheel]
|
|
36
36
|
# use local winrt-sdk build dependency
|
|
37
|
-
environment = { PYTHONPATH="
|
|
37
|
+
environment = { PYTHONPATH="../../winrt-sdk/src" }
|
|
38
38
|
# don't install winrt-sdk from PyPI
|
|
39
39
|
build-frontend = { name = "build[uv]", args = ["--skip-dependency-check", "--no-isolation"] }
|
|
40
40
|
before-build = "uv pip install setuptools"
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
3.1.0
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
# WARNING: Please don't edit this file. It was generated by Python/WinRT
|
|
1
|
+
# WARNING: Please don't edit this file. It was generated by Python/WinRT v3.1.0
|
|
2
2
|
|
|
3
|
-
winrt-runtime==
|
|
3
|
+
winrt-runtime==3.1.0
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
# WARNING: Please don't edit this file. It was generated by Python/WinRT v3.1.0
|
|
2
|
+
|
|
3
|
+
import datetime
|
|
4
|
+
import sys
|
|
5
|
+
import types
|
|
6
|
+
import typing
|
|
7
|
+
import uuid as _uuid
|
|
8
|
+
from builtins import property as _property
|
|
9
|
+
from abc import abstractmethod
|
|
10
|
+
|
|
11
|
+
import winrt._winrt
|
|
12
|
+
import winrt.system
|
|
13
|
+
import winrt.windows.foundation as windows_foundation
|
|
14
|
+
import winrt.windows.storage.streams as windows_storage_streams
|
|
15
|
+
|
|
16
|
+
from winrt.windows.devices.custom import DeviceAccessMode, DeviceSharingMode, IOControlAccessMode, IOControlBufferingMethod
|
|
17
|
+
|
|
18
|
+
Self = typing.TypeVar('Self')
|
|
19
|
+
|
|
20
|
+
@typing.final
|
|
21
|
+
class CustomDevice_Static(winrt._winrt.IInspectable_Static):
|
|
22
|
+
# Windows.Foundation.IAsyncOperation`1<Windows.Devices.Custom.CustomDevice> Windows.Devices.Custom.CustomDevice::FromIdAsync(System.String,Windows.Devices.Custom.DeviceAccessMode,Windows.Devices.Custom.DeviceSharingMode)
|
|
23
|
+
def from_id_async(cls, device_id: str, desired_access: DeviceAccessMode, sharing_mode: DeviceSharingMode, /) -> windows_foundation.IAsyncOperation[CustomDevice]: ...
|
|
24
|
+
# System.String Windows.Devices.Custom.CustomDevice::GetDeviceSelector(System.Guid)
|
|
25
|
+
def get_device_selector(cls, class_guid: _uuid.UUID, /) -> str: ...
|
|
26
|
+
|
|
27
|
+
@typing.final
|
|
28
|
+
class CustomDevice(winrt.system.Object, metaclass=CustomDevice_Static):
|
|
29
|
+
# Windows.Foundation.IAsyncOperation`1<System.UInt32> Windows.Devices.Custom.CustomDevice::SendIOControlAsync(Windows.Devices.Custom.IIOControlCode,Windows.Storage.Streams.IBuffer,Windows.Storage.Streams.IBuffer)
|
|
30
|
+
def send_io_control_async(self, io_control_code: IIOControlCode, input_buffer: windows_storage_streams.IBuffer, output_buffer: windows_storage_streams.IBuffer, /) -> windows_foundation.IAsyncOperation[winrt.system.UInt32]: ...
|
|
31
|
+
# Windows.Foundation.IAsyncOperation`1<System.Boolean> Windows.Devices.Custom.CustomDevice::TrySendIOControlAsync(Windows.Devices.Custom.IIOControlCode,Windows.Storage.Streams.IBuffer,Windows.Storage.Streams.IBuffer)
|
|
32
|
+
def try_send_io_control_async(self, io_control_code: IIOControlCode, input_buffer: windows_storage_streams.IBuffer, output_buffer: windows_storage_streams.IBuffer, /) -> windows_foundation.IAsyncOperation[bool]: ...
|
|
33
|
+
# Windows.Storage.Streams.IInputStream Windows.Devices.Custom.CustomDevice::get_InputStream()
|
|
34
|
+
@_property
|
|
35
|
+
def input_stream(self) -> windows_storage_streams.IInputStream: ...
|
|
36
|
+
# Windows.Storage.Streams.IOutputStream Windows.Devices.Custom.CustomDevice::get_OutputStream()
|
|
37
|
+
@_property
|
|
38
|
+
def output_stream(self) -> windows_storage_streams.IOutputStream: ...
|
|
39
|
+
|
|
40
|
+
@typing.final
|
|
41
|
+
class IOControlCode(winrt.system.Object, IIOControlCode):
|
|
42
|
+
def __new__(cls: typing.Type[Self], device_type: winrt.system.UInt16, function: winrt.system.UInt16, access_mode: IOControlAccessMode, buffering_method: IOControlBufferingMethod) -> Self: ...
|
|
43
|
+
# Windows.Devices.Custom.IOControlAccessMode Windows.Devices.Custom.IOControlCode::get_AccessMode()
|
|
44
|
+
@_property
|
|
45
|
+
def access_mode(self) -> IOControlAccessMode: ...
|
|
46
|
+
# Windows.Devices.Custom.IOControlBufferingMethod Windows.Devices.Custom.IOControlCode::get_BufferingMethod()
|
|
47
|
+
@_property
|
|
48
|
+
def buffering_method(self) -> IOControlBufferingMethod: ...
|
|
49
|
+
# System.UInt32 Windows.Devices.Custom.IOControlCode::get_ControlCode()
|
|
50
|
+
@_property
|
|
51
|
+
def control_code(self) -> winrt.system.UInt32: ...
|
|
52
|
+
# System.UInt16 Windows.Devices.Custom.IOControlCode::get_DeviceType()
|
|
53
|
+
@_property
|
|
54
|
+
def device_type(self) -> winrt.system.UInt16: ...
|
|
55
|
+
# System.UInt16 Windows.Devices.Custom.IOControlCode::get_Function()
|
|
56
|
+
@_property
|
|
57
|
+
def function(self) -> winrt.system.UInt16: ...
|
|
58
|
+
|
|
59
|
+
@typing.final
|
|
60
|
+
class KnownDeviceTypes_Static(winrt._winrt.IInspectable_Static):
|
|
61
|
+
# System.UInt16 Windows.Devices.Custom.KnownDeviceTypes::get_Unknown()
|
|
62
|
+
@_property
|
|
63
|
+
def unknown(cls) -> winrt.system.UInt16: ...
|
|
64
|
+
|
|
65
|
+
@typing.final
|
|
66
|
+
class KnownDeviceTypes(winrt.system.Object, metaclass=KnownDeviceTypes_Static):
|
|
67
|
+
pass
|
|
68
|
+
|
|
69
|
+
@typing.final
|
|
70
|
+
class _IIOControlCode: ...
|
|
71
|
+
|
|
72
|
+
class IIOControlCode(winrt._winrt.IInspectable):
|
|
73
|
+
# Windows.Devices.Custom.IOControlAccessMode Windows.Devices.Custom.IIOControlCode::get_AccessMode()
|
|
74
|
+
@_property
|
|
75
|
+
@abstractmethod
|
|
76
|
+
def access_mode(self) -> IOControlAccessMode: ...
|
|
77
|
+
# Windows.Devices.Custom.IOControlBufferingMethod Windows.Devices.Custom.IIOControlCode::get_BufferingMethod()
|
|
78
|
+
@_property
|
|
79
|
+
@abstractmethod
|
|
80
|
+
def buffering_method(self) -> IOControlBufferingMethod: ...
|
|
81
|
+
# System.UInt32 Windows.Devices.Custom.IIOControlCode::get_ControlCode()
|
|
82
|
+
@_property
|
|
83
|
+
@abstractmethod
|
|
84
|
+
def control_code(self) -> winrt.system.UInt32: ...
|
|
85
|
+
# System.UInt16 Windows.Devices.Custom.IIOControlCode::get_DeviceType()
|
|
86
|
+
@_property
|
|
87
|
+
@abstractmethod
|
|
88
|
+
def device_type(self) -> winrt.system.UInt16: ...
|
|
89
|
+
# System.UInt16 Windows.Devices.Custom.IIOControlCode::get_Function()
|
|
90
|
+
@_property
|
|
91
|
+
@abstractmethod
|
|
92
|
+
def function(self) -> winrt.system.UInt16: ...
|
|
93
|
+
|
|
@@ -1,9 +1,15 @@
|
|
|
1
|
-
# WARNING: Please don't edit this file. It was generated by Python/WinRT
|
|
1
|
+
# WARNING: Please don't edit this file. It was generated by Python/WinRT v3.1.0
|
|
2
2
|
|
|
3
3
|
import enum
|
|
4
4
|
|
|
5
5
|
import winrt.system
|
|
6
|
-
from winrt import
|
|
6
|
+
from winrt._winrt_windows_devices_custom import (
|
|
7
|
+
CustomDevice,
|
|
8
|
+
IOControlCode,
|
|
9
|
+
KnownDeviceTypes,
|
|
10
|
+
_IIOControlCode,
|
|
11
|
+
IIOControlCode,
|
|
12
|
+
)
|
|
7
13
|
|
|
8
14
|
__all__ = [
|
|
9
15
|
"DeviceAccessMode",
|
|
@@ -37,7 +43,3 @@ class IOControlBufferingMethod(enum.IntEnum):
|
|
|
37
43
|
DIRECT_OUTPUT = 2
|
|
38
44
|
NEITHER = 3
|
|
39
45
|
|
|
40
|
-
CustomDevice = _winrt_windows_devices_custom.CustomDevice
|
|
41
|
-
IOControlCode = _winrt_windows_devices_custom.IOControlCode
|
|
42
|
-
KnownDeviceTypes = _winrt_windows_devices_custom.KnownDeviceTypes
|
|
43
|
-
IIOControlCode = _winrt_windows_devices_custom.IIOControlCode
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
2
|
Name: winrt-Windows.Devices.Custom
|
|
3
|
-
Version:
|
|
3
|
+
Version: 3.1.0
|
|
4
4
|
Summary: Python projection of Windows Runtime (WinRT) APIs
|
|
5
|
-
License: MIT
|
|
5
|
+
License-Expression: MIT
|
|
6
6
|
Project-URL: Documentation, https://pywinrt.readthedocs.io
|
|
7
7
|
Project-URL: Repository, https://github.com/pywinrt/pywinrt
|
|
8
8
|
Project-URL: Changelog, https://github.com/pywinrt/pywinrt/blob/main/CHANGELOG.md
|
|
@@ -10,12 +10,12 @@ Classifier: Operating System :: Microsoft :: Windows
|
|
|
10
10
|
Classifier: Programming Language :: Python :: 3
|
|
11
11
|
Classifier: Programming Language :: Python :: Implementation :: CPython
|
|
12
12
|
Classifier: Intended Audience :: Developers
|
|
13
|
-
Requires-Python:
|
|
13
|
+
Requires-Python: >=3.9
|
|
14
14
|
Description-Content-Type: text/markdown
|
|
15
|
-
Requires-Dist: winrt-runtime==
|
|
15
|
+
Requires-Dist: winrt-runtime==3.1.0
|
|
16
16
|
Provides-Extra: all
|
|
17
|
-
Requires-Dist: winrt-Windows.Foundation[all]==
|
|
18
|
-
Requires-Dist: winrt-Windows.Storage.Streams[all]==
|
|
17
|
+
Requires-Dist: winrt-Windows.Foundation[all]==3.1.0; extra == "all"
|
|
18
|
+
Requires-Dist: winrt-Windows.Storage.Streams[all]==3.1.0; extra == "all"
|
|
19
19
|
|
|
20
20
|
<!-- warning: Please don't edit this file. It was automatically generated. -->
|
|
21
21
|
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
2.3.0
|
|
@@ -1,74 +0,0 @@
|
|
|
1
|
-
# WARNING: Please don't edit this file. It was generated by Python/WinRT v2.3.0
|
|
2
|
-
|
|
3
|
-
import datetime
|
|
4
|
-
import sys
|
|
5
|
-
import types
|
|
6
|
-
import typing
|
|
7
|
-
import uuid as _uuid
|
|
8
|
-
from builtins import property as _property
|
|
9
|
-
|
|
10
|
-
import winrt._winrt
|
|
11
|
-
import winrt.system
|
|
12
|
-
import winrt.windows.foundation as windows_foundation
|
|
13
|
-
import winrt.windows.storage.streams as windows_storage_streams
|
|
14
|
-
|
|
15
|
-
from winrt.windows.devices.custom import DeviceAccessMode, DeviceSharingMode, IOControlAccessMode, IOControlBufferingMethod
|
|
16
|
-
|
|
17
|
-
Self = typing.TypeVar('Self')
|
|
18
|
-
|
|
19
|
-
@typing.final
|
|
20
|
-
class CustomDevice_Static(type):
|
|
21
|
-
def from_id_async(cls, device_id: str, desired_access: DeviceAccessMode, sharing_mode: DeviceSharingMode, /) -> windows_foundation.IAsyncOperation[CustomDevice]: ...
|
|
22
|
-
def get_device_selector(cls, class_guid: _uuid.UUID, /) -> str: ...
|
|
23
|
-
|
|
24
|
-
@typing.final
|
|
25
|
-
class CustomDevice(winrt.system.Object, metaclass=CustomDevice_Static):
|
|
26
|
-
@staticmethod
|
|
27
|
-
def _from(obj: winrt.system.Object, /) -> CustomDevice: ...
|
|
28
|
-
def send_i_o_control_async(self, io_control_code: typing.Optional[IIOControlCode], input_buffer: typing.Optional[windows_storage_streams.IBuffer], output_buffer: typing.Optional[windows_storage_streams.IBuffer], /) -> windows_foundation.IAsyncOperation[winrt.system.UInt32]: ...
|
|
29
|
-
def try_send_i_o_control_async(self, io_control_code: typing.Optional[IIOControlCode], input_buffer: typing.Optional[windows_storage_streams.IBuffer], output_buffer: typing.Optional[windows_storage_streams.IBuffer], /) -> windows_foundation.IAsyncOperation[bool]: ...
|
|
30
|
-
@_property
|
|
31
|
-
def input_stream(self) -> typing.Optional[windows_storage_streams.IInputStream]: ...
|
|
32
|
-
@_property
|
|
33
|
-
def output_stream(self) -> typing.Optional[windows_storage_streams.IOutputStream]: ...
|
|
34
|
-
|
|
35
|
-
@typing.final
|
|
36
|
-
class IOControlCode(winrt.system.Object):
|
|
37
|
-
@staticmethod
|
|
38
|
-
def _from(obj: winrt.system.Object, /) -> IOControlCode: ...
|
|
39
|
-
def __new__(cls: typing.Type[IOControlCode], device_type: winrt.system.UInt16, function: winrt.system.UInt16, access_mode: IOControlAccessMode, buffering_method: IOControlBufferingMethod) -> IOControlCode: ...
|
|
40
|
-
@_property
|
|
41
|
-
def access_mode(self) -> IOControlAccessMode: ...
|
|
42
|
-
@_property
|
|
43
|
-
def buffering_method(self) -> IOControlBufferingMethod: ...
|
|
44
|
-
@_property
|
|
45
|
-
def control_code(self) -> winrt.system.UInt32: ...
|
|
46
|
-
@_property
|
|
47
|
-
def device_type(self) -> winrt.system.UInt16: ...
|
|
48
|
-
@_property
|
|
49
|
-
def function(self) -> winrt.system.UInt16: ...
|
|
50
|
-
|
|
51
|
-
@typing.final
|
|
52
|
-
class KnownDeviceTypes_Static(type):
|
|
53
|
-
@_property
|
|
54
|
-
def unknown(cls) -> winrt.system.UInt16: ...
|
|
55
|
-
|
|
56
|
-
@typing.final
|
|
57
|
-
class KnownDeviceTypes(winrt.system.Object, metaclass=KnownDeviceTypes_Static):
|
|
58
|
-
pass
|
|
59
|
-
|
|
60
|
-
@typing.final
|
|
61
|
-
class IIOControlCode(winrt.system.Object):
|
|
62
|
-
@staticmethod
|
|
63
|
-
def _from(obj: winrt.system.Object, /) -> IIOControlCode: ...
|
|
64
|
-
@_property
|
|
65
|
-
def access_mode(self) -> IOControlAccessMode: ...
|
|
66
|
-
@_property
|
|
67
|
-
def buffering_method(self) -> IOControlBufferingMethod: ...
|
|
68
|
-
@_property
|
|
69
|
-
def control_code(self) -> winrt.system.UInt32: ...
|
|
70
|
-
@_property
|
|
71
|
-
def device_type(self) -> winrt.system.UInt16: ...
|
|
72
|
-
@_property
|
|
73
|
-
def function(self) -> winrt.system.UInt16: ...
|
|
74
|
-
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|