winrt-Windows.System.Power 3.2.1__tar.gz → 4!10.0.28000.2705__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.
Files changed (24) hide show
  1. winrt_windows_system_power-4!10.0.28000.2705/.gitignore +5 -0
  2. winrt_windows_system_power-4!10.0.28000.2705/LICENSE +22 -0
  3. winrt_windows_system_power-4!10.0.28000.2705/PKG-INFO +44 -0
  4. winrt_windows_system_power-4!10.0.28000.2705/README.md +17 -0
  5. winrt_windows_system_power-4!10.0.28000.2705/pyproject.toml +56 -0
  6. winrt_windows_system_power-4!10.0.28000.2705/winrt/windows/system/power/__init__.py +17 -0
  7. winrt_windows_system_power-3.2.1/winrt/_winrt_windows_system_power.pyi → winrt_windows_system_power-4!10.0.28000.2705/winrt/windows/system/power/__init__.pyi +85 -30
  8. winrt_windows_system_power-4!10.0.28000.2705/winrt/windows/system/power/_table.pywinrt.txt +202 -0
  9. winrt_windows_system_power-3.2.1/PKG-INFO +0 -25
  10. winrt_windows_system_power-3.2.1/README.md +0 -7
  11. winrt_windows_system_power-3.2.1/all-requirements.txt +0 -3
  12. winrt_windows_system_power-3.2.1/py.Windows.System.Power.cpp +0 -1453
  13. winrt_windows_system_power-3.2.1/pyproject.toml +0 -47
  14. winrt_windows_system_power-3.2.1/pywinrt-version.txt +0 -1
  15. winrt_windows_system_power-3.2.1/requirements.txt +0 -3
  16. winrt_windows_system_power-3.2.1/setup.cfg +0 -4
  17. winrt_windows_system_power-3.2.1/setup.py +0 -33
  18. winrt_windows_system_power-3.2.1/winrt/windows/system/power/__init__.py +0 -36
  19. winrt_windows_system_power-3.2.1/winrt_Windows.System.Power.egg-info/PKG-INFO +0 -25
  20. winrt_windows_system_power-3.2.1/winrt_Windows.System.Power.egg-info/SOURCES.txt +0 -15
  21. winrt_windows_system_power-3.2.1/winrt_Windows.System.Power.egg-info/dependency_links.txt +0 -1
  22. winrt_windows_system_power-3.2.1/winrt_Windows.System.Power.egg-info/requires.txt +0 -4
  23. winrt_windows_system_power-3.2.1/winrt_Windows.System.Power.egg-info/top_level.txt +0 -1
  24. {winrt_windows_system_power-3.2.1 → winrt_windows_system_power-4!10.0.28000.2705}/winrt/windows/system/power/py.typed +0 -0
@@ -0,0 +1,5 @@
1
+ *.egg-info
2
+ *.tar.gz
3
+ *.whl
4
+ build/
5
+ dist/
@@ -0,0 +1,22 @@
1
+ MIT License
2
+
3
+ Copyright (c) Microsoft Corporation. All rights reserved.
4
+ Copyright (c) 2021-2026 David Lechner <david@pybricks.com>
5
+
6
+ Permission is hereby granted, free of charge, to any person obtaining a copy
7
+ of this software and associated documentation files (the "Software"), to deal
8
+ in the Software without restriction, including without limitation the rights
9
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10
+ copies of the Software, and to permit persons to whom the Software is
11
+ furnished to do so, subject to the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be included in all
14
+ copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
+ SOFTWARE
@@ -0,0 +1,44 @@
1
+ Metadata-Version: 2.5
2
+ Name: winrt-Windows.System.Power
3
+ Version: 4!10.0.28000.2705
4
+ Summary: PyWinRT projection of the Windows.System.Power namespace
5
+ Project-URL: Documentation, https://pywinrt.readthedocs.io
6
+ Project-URL: Repository, https://github.com/pywinrt/pywinrt
7
+ Project-URL: Changelog, https://github.com/pywinrt/pywinrt/blob/main/projection/winrt/CHANGELOG.md
8
+ License-Expression: MIT
9
+ License-File: LICENSE
10
+ Classifier: Intended Audience :: Developers
11
+ Classifier: Operating System :: Microsoft :: Windows
12
+ Classifier: Programming Language :: Python :: 3
13
+ Classifier: Programming Language :: Python :: 3.11
14
+ Classifier: Programming Language :: Python :: 3.12
15
+ Classifier: Programming Language :: Python :: 3.13
16
+ Classifier: Programming Language :: Python :: 3.14
17
+ Classifier: Programming Language :: Python :: 3.15
18
+ Classifier: Programming Language :: Python :: Free Threading :: 2 - Beta
19
+ Classifier: Programming Language :: Python :: Implementation :: CPython
20
+ Classifier: Typing :: Typed
21
+ Requires-Python: >=3.11
22
+ Requires-Dist: winrt-runtime<5,>=4.0.0
23
+ Requires-Dist: winrt-windows-foundation>=4!10.0.28000.2705
24
+ Provides-Extra: all
25
+ Requires-Dist: winrt-windows-foundation[all]>=4!10.0.28000.2705; extra == 'all'
26
+ Description-Content-Type: text/markdown
27
+
28
+ <!-- warning: Please don't edit this file. It was automatically generated. -->
29
+
30
+ # winrt-Windows.System.Power
31
+
32
+ Windows Runtime (WinRT) APIs for the `Windows.System.Power` namespace.
33
+
34
+ This package provides the `winrt.windows.system.power` module.
35
+
36
+ The WinRT APIs in it are those of version 10.0.28000.2705 of the
37
+ `Microsoft.Windows.SDK.CPP` NuGet package.
38
+
39
+ ```
40
+ pip install winrt-Windows.System.Power
41
+ ```
42
+
43
+ Other WinRT namespaces are packages of their own, so install the package of
44
+ each namespace your code imports from.
@@ -0,0 +1,17 @@
1
+ <!-- warning: Please don't edit this file. It was automatically generated. -->
2
+
3
+ # winrt-Windows.System.Power
4
+
5
+ Windows Runtime (WinRT) APIs for the `Windows.System.Power` namespace.
6
+
7
+ This package provides the `winrt.windows.system.power` module.
8
+
9
+ The WinRT APIs in it are those of version 10.0.28000.2705 of the
10
+ `Microsoft.Windows.SDK.CPP` NuGet package.
11
+
12
+ ```
13
+ pip install winrt-Windows.System.Power
14
+ ```
15
+
16
+ Other WinRT namespaces are packages of their own, so install the package of
17
+ each namespace your code imports from.
@@ -0,0 +1,56 @@
1
+ # WARNING: Please don't edit this file. It was automatically generated.
2
+
3
+ [build-system]
4
+ requires = ["hatchling", "winrt-table-compiler>=4.0.0,<5"]
5
+ build-backend = "hatchling.build"
6
+
7
+ [project]
8
+ name = "winrt-Windows.System.Power"
9
+ version = "4!10.0.28000.2705"
10
+ description = "PyWinRT projection of the Windows.System.Power namespace"
11
+ readme = "README.md"
12
+ license = "MIT"
13
+ license-files = ["LICENSE"]
14
+ classifiers = [
15
+ "Operating System :: Microsoft :: Windows",
16
+ "Programming Language :: Python :: 3",
17
+ "Programming Language :: Python :: 3.11",
18
+ "Programming Language :: Python :: 3.12",
19
+ "Programming Language :: Python :: 3.13",
20
+ "Programming Language :: Python :: 3.14",
21
+ "Programming Language :: Python :: 3.15",
22
+ "Programming Language :: Python :: Implementation :: CPython",
23
+ "Intended Audience :: Developers",
24
+ "Programming Language :: Python :: Free Threading :: 2 - Beta",
25
+ "Typing :: Typed",
26
+ ]
27
+ requires-python = ">=3.11"
28
+ dependencies = [
29
+ "winrt-runtime>=4.0.0,<5",
30
+ "winrt-Windows.Foundation>=4!10.0.28000.2705",
31
+ ]
32
+
33
+ [project.optional-dependencies]
34
+ all = [
35
+ "winrt-Windows.Foundation[all]>=4!10.0.28000.2705",
36
+ ]
37
+
38
+ [project.urls]
39
+ Documentation = "https://pywinrt.readthedocs.io"
40
+ Repository = "https://github.com/pywinrt/pywinrt"
41
+ Changelog = "https://github.com/pywinrt/pywinrt/blob/main/projection/winrt/CHANGELOG.md"
42
+
43
+ [tool.hatch.build.targets.sdist]
44
+ # The text form of the table is what the source distribution carries, and the
45
+ # compiled form is build output wherever it turns up. Hatchling reads no
46
+ # .gitignore above the package, so it has to be told about the latter.
47
+ only-include = ["winrt", "LICENSE", "README.md"]
48
+ exclude = ["**/_table.pywinrt"]
49
+
50
+ [tool.hatch.build.targets.wheel]
51
+ packages = ["winrt"]
52
+ exclude = ["**/_table.pywinrt.txt"]
53
+
54
+ # winrt.table.build_hooks in winrt-table-compiler, which compiles each table
55
+ # the package carries and puts the result beside the __init__.py that loads it.
56
+ [tool.hatch.build.targets.wheel.hooks.winrt-table-compiler]
@@ -0,0 +1,17 @@
1
+ # WARNING: Please don't edit this file. It was generated by Python/WinRT
2
+
3
+ import winrt.runtime._internals
4
+ import winrt.system
5
+
6
+ winrt.runtime._internals.load_projection(__spec__)
7
+
8
+ __all__ = [
9
+ "BatteryStatus",
10
+ "EnergySaverStatus",
11
+ "EnergySaverStatus2",
12
+ "PowerSupplyStatus",
13
+ "BackgroundEnergyManager",
14
+ "ForegroundEnergyManager",
15
+ "PowerManager",
16
+ ]
17
+
@@ -1,122 +1,170 @@
1
- # WARNING: Please don't edit this file. It was generated by Python/WinRT v3.2.1
1
+ # WARNING: Please don't edit this file. It was generated by Python/WinRT
2
2
 
3
3
  import datetime
4
- import sys
5
- import types
4
+ import enum
6
5
  import typing
7
- import uuid as _uuid
8
6
  from builtins import property as _property
7
+ from typing_extensions import deprecated
9
8
 
10
- import winrt._winrt
11
9
  import winrt.system
12
10
  import winrt.windows.foundation as windows_foundation
13
11
 
14
- from winrt.windows.system.power import BatteryStatus, EnergySaverStatus, PowerSupplyStatus
12
+ __all__ = [
13
+ "BatteryStatus",
14
+ "EnergySaverStatus",
15
+ "EnergySaverStatus2",
16
+ "PowerSupplyStatus",
17
+ "BackgroundEnergyManager",
18
+ "ForegroundEnergyManager",
19
+ "PowerManager",
20
+ ]
15
21
 
16
- Self = typing.TypeVar('Self')
22
+ class BatteryStatus(enum.IntEnum):
23
+ NOT_PRESENT = 0
24
+ DISCHARGING = 1
25
+ IDLE = 2
26
+ CHARGING = 3
27
+
28
+ class EnergySaverStatus(enum.IntEnum):
29
+ DISABLED = 0
30
+ OFF = 1
31
+ ON = 2
32
+
33
+ class EnergySaverStatus2(enum.IntEnum):
34
+ UNKNOWN = 0
35
+ OFF = 1
36
+ STANDARD = 2
37
+ HIGH_SAVINGS = 3
38
+
39
+ class PowerSupplyStatus(enum.IntEnum):
40
+ NOT_PRESENT = 0
41
+ INADEQUATE = 1
42
+ ADEQUATE = 2
17
43
 
18
44
  @typing.final
19
- class BackgroundEnergyManager_Static(winrt._winrt.IInspectable_Static):
45
+ class BackgroundEnergyManager_Static(winrt.system.Object_Static):
20
46
  # Windows.Foundation.EventRegistrationToken Windows.System.Power.BackgroundEnergyManager::add_RecentEnergyUsageIncreased(Windows.Foundation.EventHandler`1<System.Object>)
21
- # @deprecated("Background Energy Manager has been deprecated. For more info, see MSDN.")
47
+ @deprecated("Background Energy Manager has been deprecated. For more info, see MSDN.")
22
48
  def add_recent_energy_usage_increased(cls, handler: windows_foundation.EventHandler[winrt.system.Object], /) -> windows_foundation.EventRegistrationToken: ...
23
49
  # System.Void Windows.System.Power.BackgroundEnergyManager::remove_RecentEnergyUsageIncreased(Windows.Foundation.EventRegistrationToken)
24
- # @deprecated("Background Energy Manager has been deprecated. For more info, see MSDN.")
25
- def remove_recent_energy_usage_increased(cls, token: typing.Union[windows_foundation.EventRegistrationToken, typing.Tuple[winrt.system.Int64]], /) -> None: ...
50
+ @deprecated("Background Energy Manager has been deprecated. For more info, see MSDN.")
51
+ def remove_recent_energy_usage_increased(cls, token: windows_foundation.EventRegistrationToken, /) -> None: ...
26
52
  # Windows.Foundation.EventRegistrationToken Windows.System.Power.BackgroundEnergyManager::add_RecentEnergyUsageReturnedToLow(Windows.Foundation.EventHandler`1<System.Object>)
27
- # @deprecated("Background Energy Manager has been deprecated. For more info, see MSDN.")
53
+ @deprecated("Background Energy Manager has been deprecated. For more info, see MSDN.")
28
54
  def add_recent_energy_usage_returned_to_low(cls, handler: windows_foundation.EventHandler[winrt.system.Object], /) -> windows_foundation.EventRegistrationToken: ...
29
55
  # System.Void Windows.System.Power.BackgroundEnergyManager::remove_RecentEnergyUsageReturnedToLow(Windows.Foundation.EventRegistrationToken)
30
- # @deprecated("Background Energy Manager has been deprecated. For more info, see MSDN.")
31
- def remove_recent_energy_usage_returned_to_low(cls, token: typing.Union[windows_foundation.EventRegistrationToken, typing.Tuple[winrt.system.Int64]], /) -> None: ...
56
+ @deprecated("Background Energy Manager has been deprecated. For more info, see MSDN.")
57
+ def remove_recent_energy_usage_returned_to_low(cls, token: windows_foundation.EventRegistrationToken, /) -> None: ...
32
58
  # System.UInt32 Windows.System.Power.BackgroundEnergyManager::get_ExcessiveUsageLevel()
33
59
  @_property
60
+ @deprecated("Background Energy Manager has been deprecated. For more info, see MSDN.")
34
61
  def excessive_usage_level(cls) -> winrt.system.UInt32: ...
35
62
  # System.UInt32 Windows.System.Power.BackgroundEnergyManager::get_LowUsageLevel()
36
63
  @_property
64
+ @deprecated("Background Energy Manager has been deprecated. For more info, see MSDN.")
37
65
  def low_usage_level(cls) -> winrt.system.UInt32: ...
38
66
  # System.UInt32 Windows.System.Power.BackgroundEnergyManager::get_MaxAcceptableUsageLevel()
39
67
  @_property
68
+ @deprecated("Background Energy Manager has been deprecated. For more info, see MSDN.")
40
69
  def max_acceptable_usage_level(cls) -> winrt.system.UInt32: ...
41
70
  # System.UInt32 Windows.System.Power.BackgroundEnergyManager::get_NearMaxAcceptableUsageLevel()
42
71
  @_property
72
+ @deprecated("Background Energy Manager has been deprecated. For more info, see MSDN.")
43
73
  def near_max_acceptable_usage_level(cls) -> winrt.system.UInt32: ...
44
74
  # System.UInt32 Windows.System.Power.BackgroundEnergyManager::get_NearTerminationUsageLevel()
45
75
  @_property
76
+ @deprecated("Background Energy Manager has been deprecated. For more info, see MSDN.")
46
77
  def near_termination_usage_level(cls) -> winrt.system.UInt32: ...
47
78
  # System.UInt32 Windows.System.Power.BackgroundEnergyManager::get_RecentEnergyUsage()
48
79
  @_property
80
+ @deprecated("Background Energy Manager has been deprecated. For more info, see MSDN.")
49
81
  def recent_energy_usage(cls) -> winrt.system.UInt32: ...
50
82
  # System.UInt32 Windows.System.Power.BackgroundEnergyManager::get_RecentEnergyUsageLevel()
51
83
  @_property
84
+ @deprecated("Background Energy Manager has been deprecated. For more info, see MSDN.")
52
85
  def recent_energy_usage_level(cls) -> winrt.system.UInt32: ...
53
86
  # System.UInt32 Windows.System.Power.BackgroundEnergyManager::get_TerminationUsageLevel()
54
87
  @_property
88
+ @deprecated("Background Energy Manager has been deprecated. For more info, see MSDN.")
55
89
  def termination_usage_level(cls) -> winrt.system.UInt32: ...
56
90
 
57
91
  @typing.final
92
+ @deprecated("Background Energy Manager has been deprecated. For more info, see MSDN.")
58
93
  class BackgroundEnergyManager(winrt.system.Object, metaclass=BackgroundEnergyManager_Static):
59
- pass
94
+ def __new__(cls, _: typing.Never, /) -> typing.Self:
95
+ """A class of static members only, so there is nothing to create."""
60
96
 
61
97
  @typing.final
62
- class ForegroundEnergyManager_Static(winrt._winrt.IInspectable_Static):
98
+ class ForegroundEnergyManager_Static(winrt.system.Object_Static):
63
99
  # Windows.Foundation.EventRegistrationToken Windows.System.Power.ForegroundEnergyManager::add_RecentEnergyUsageIncreased(Windows.Foundation.EventHandler`1<System.Object>)
64
- # @deprecated("Foreground Energy Manager has been deprecated. For more info, see MSDN.")
100
+ @deprecated("Foreground Energy Manager has been deprecated. For more info, see MSDN.")
65
101
  def add_recent_energy_usage_increased(cls, handler: windows_foundation.EventHandler[winrt.system.Object], /) -> windows_foundation.EventRegistrationToken: ...
66
102
  # System.Void Windows.System.Power.ForegroundEnergyManager::remove_RecentEnergyUsageIncreased(Windows.Foundation.EventRegistrationToken)
67
- # @deprecated("Foreground Energy Manager has been deprecated. For more info, see MSDN.")
68
- def remove_recent_energy_usage_increased(cls, token: typing.Union[windows_foundation.EventRegistrationToken, typing.Tuple[winrt.system.Int64]], /) -> None: ...
103
+ @deprecated("Foreground Energy Manager has been deprecated. For more info, see MSDN.")
104
+ def remove_recent_energy_usage_increased(cls, token: windows_foundation.EventRegistrationToken, /) -> None: ...
69
105
  # Windows.Foundation.EventRegistrationToken Windows.System.Power.ForegroundEnergyManager::add_RecentEnergyUsageReturnedToLow(Windows.Foundation.EventHandler`1<System.Object>)
70
- # @deprecated("Foreground Energy Manager has been deprecated. For more info, see MSDN.")
106
+ @deprecated("Foreground Energy Manager has been deprecated. For more info, see MSDN.")
71
107
  def add_recent_energy_usage_returned_to_low(cls, handler: windows_foundation.EventHandler[winrt.system.Object], /) -> windows_foundation.EventRegistrationToken: ...
72
108
  # System.Void Windows.System.Power.ForegroundEnergyManager::remove_RecentEnergyUsageReturnedToLow(Windows.Foundation.EventRegistrationToken)
73
- # @deprecated("Foreground Energy Manager has been deprecated. For more info, see MSDN.")
74
- def remove_recent_energy_usage_returned_to_low(cls, token: typing.Union[windows_foundation.EventRegistrationToken, typing.Tuple[winrt.system.Int64]], /) -> None: ...
109
+ @deprecated("Foreground Energy Manager has been deprecated. For more info, see MSDN.")
110
+ def remove_recent_energy_usage_returned_to_low(cls, token: windows_foundation.EventRegistrationToken, /) -> None: ...
75
111
  # System.UInt32 Windows.System.Power.ForegroundEnergyManager::get_ExcessiveUsageLevel()
76
112
  @_property
113
+ @deprecated("Foreground Energy Manager has been deprecated. For more info, see MSDN.")
77
114
  def excessive_usage_level(cls) -> winrt.system.UInt32: ...
78
115
  # System.UInt32 Windows.System.Power.ForegroundEnergyManager::get_LowUsageLevel()
79
116
  @_property
117
+ @deprecated("Foreground Energy Manager has been deprecated. For more info, see MSDN.")
80
118
  def low_usage_level(cls) -> winrt.system.UInt32: ...
81
119
  # System.UInt32 Windows.System.Power.ForegroundEnergyManager::get_MaxAcceptableUsageLevel()
82
120
  @_property
121
+ @deprecated("Foreground Energy Manager has been deprecated. For more info, see MSDN.")
83
122
  def max_acceptable_usage_level(cls) -> winrt.system.UInt32: ...
84
123
  # System.UInt32 Windows.System.Power.ForegroundEnergyManager::get_NearMaxAcceptableUsageLevel()
85
124
  @_property
125
+ @deprecated("Foreground Energy Manager has been deprecated. For more info, see MSDN.")
86
126
  def near_max_acceptable_usage_level(cls) -> winrt.system.UInt32: ...
87
127
  # System.UInt32 Windows.System.Power.ForegroundEnergyManager::get_RecentEnergyUsage()
88
128
  @_property
129
+ @deprecated("Foreground Energy Manager has been deprecated. For more info, see MSDN.")
89
130
  def recent_energy_usage(cls) -> winrt.system.UInt32: ...
90
131
  # System.UInt32 Windows.System.Power.ForegroundEnergyManager::get_RecentEnergyUsageLevel()
91
132
  @_property
133
+ @deprecated("Foreground Energy Manager has been deprecated. For more info, see MSDN.")
92
134
  def recent_energy_usage_level(cls) -> winrt.system.UInt32: ...
93
135
 
94
136
  @typing.final
137
+ @deprecated("Foreground Energy Manager has been deprecated. For more info, see MSDN.")
95
138
  class ForegroundEnergyManager(winrt.system.Object, metaclass=ForegroundEnergyManager_Static):
96
- pass
139
+ def __new__(cls, _: typing.Never, /) -> typing.Self:
140
+ """A class of static members only, so there is nothing to create."""
97
141
 
98
142
  @typing.final
99
- class PowerManager_Static(winrt._winrt.IInspectable_Static):
143
+ class PowerManager_Static(winrt.system.Object_Static):
144
+ # Windows.Foundation.EventRegistrationToken Windows.System.Power.PowerManager::add_EnergySaverStatus2Changed(Windows.Foundation.EventHandler`1<System.Object>)
145
+ def add_energy_saver_status2_changed(cls, handler: windows_foundation.EventHandler[winrt.system.Object], /) -> windows_foundation.EventRegistrationToken: ...
146
+ # System.Void Windows.System.Power.PowerManager::remove_EnergySaverStatus2Changed(Windows.Foundation.EventRegistrationToken)
147
+ def remove_energy_saver_status2_changed(cls, token: windows_foundation.EventRegistrationToken, /) -> None: ...
100
148
  # Windows.Foundation.EventRegistrationToken Windows.System.Power.PowerManager::add_BatteryStatusChanged(Windows.Foundation.EventHandler`1<System.Object>)
101
149
  def add_battery_status_changed(cls, handler: windows_foundation.EventHandler[winrt.system.Object], /) -> windows_foundation.EventRegistrationToken: ...
102
150
  # System.Void Windows.System.Power.PowerManager::remove_BatteryStatusChanged(Windows.Foundation.EventRegistrationToken)
103
- def remove_battery_status_changed(cls, token: typing.Union[windows_foundation.EventRegistrationToken, typing.Tuple[winrt.system.Int64]], /) -> None: ...
151
+ def remove_battery_status_changed(cls, token: windows_foundation.EventRegistrationToken, /) -> None: ...
104
152
  # Windows.Foundation.EventRegistrationToken Windows.System.Power.PowerManager::add_EnergySaverStatusChanged(Windows.Foundation.EventHandler`1<System.Object>)
105
153
  def add_energy_saver_status_changed(cls, handler: windows_foundation.EventHandler[winrt.system.Object], /) -> windows_foundation.EventRegistrationToken: ...
106
154
  # System.Void Windows.System.Power.PowerManager::remove_EnergySaverStatusChanged(Windows.Foundation.EventRegistrationToken)
107
- def remove_energy_saver_status_changed(cls, token: typing.Union[windows_foundation.EventRegistrationToken, typing.Tuple[winrt.system.Int64]], /) -> None: ...
155
+ def remove_energy_saver_status_changed(cls, token: windows_foundation.EventRegistrationToken, /) -> None: ...
108
156
  # Windows.Foundation.EventRegistrationToken Windows.System.Power.PowerManager::add_PowerSupplyStatusChanged(Windows.Foundation.EventHandler`1<System.Object>)
109
157
  def add_power_supply_status_changed(cls, handler: windows_foundation.EventHandler[winrt.system.Object], /) -> windows_foundation.EventRegistrationToken: ...
110
158
  # System.Void Windows.System.Power.PowerManager::remove_PowerSupplyStatusChanged(Windows.Foundation.EventRegistrationToken)
111
- def remove_power_supply_status_changed(cls, token: typing.Union[windows_foundation.EventRegistrationToken, typing.Tuple[winrt.system.Int64]], /) -> None: ...
159
+ def remove_power_supply_status_changed(cls, token: windows_foundation.EventRegistrationToken, /) -> None: ...
112
160
  # Windows.Foundation.EventRegistrationToken Windows.System.Power.PowerManager::add_RemainingChargePercentChanged(Windows.Foundation.EventHandler`1<System.Object>)
113
161
  def add_remaining_charge_percent_changed(cls, handler: windows_foundation.EventHandler[winrt.system.Object], /) -> windows_foundation.EventRegistrationToken: ...
114
162
  # System.Void Windows.System.Power.PowerManager::remove_RemainingChargePercentChanged(Windows.Foundation.EventRegistrationToken)
115
- def remove_remaining_charge_percent_changed(cls, token: typing.Union[windows_foundation.EventRegistrationToken, typing.Tuple[winrt.system.Int64]], /) -> None: ...
163
+ def remove_remaining_charge_percent_changed(cls, token: windows_foundation.EventRegistrationToken, /) -> None: ...
116
164
  # Windows.Foundation.EventRegistrationToken Windows.System.Power.PowerManager::add_RemainingDischargeTimeChanged(Windows.Foundation.EventHandler`1<System.Object>)
117
165
  def add_remaining_discharge_time_changed(cls, handler: windows_foundation.EventHandler[winrt.system.Object], /) -> windows_foundation.EventRegistrationToken: ...
118
166
  # System.Void Windows.System.Power.PowerManager::remove_RemainingDischargeTimeChanged(Windows.Foundation.EventRegistrationToken)
119
- def remove_remaining_discharge_time_changed(cls, token: typing.Union[windows_foundation.EventRegistrationToken, typing.Tuple[winrt.system.Int64]], /) -> None: ...
167
+ def remove_remaining_discharge_time_changed(cls, token: windows_foundation.EventRegistrationToken, /) -> None: ...
120
168
  # Windows.System.Power.BatteryStatus Windows.System.Power.PowerManager::get_BatteryStatus()
121
169
  @_property
122
170
  def battery_status(cls) -> BatteryStatus: ...
@@ -132,8 +180,15 @@ class PowerManager_Static(winrt._winrt.IInspectable_Static):
132
180
  # Windows.Foundation.TimeSpan Windows.System.Power.PowerManager::get_RemainingDischargeTime()
133
181
  @_property
134
182
  def remaining_discharge_time(cls) -> datetime.timedelta: ...
183
+ # Windows.System.Power.EnergySaverStatus2 Windows.System.Power.PowerManager::get_EnergySaverStatus2()
184
+ @_property
185
+ def energy_saver_status2(cls) -> EnergySaverStatus2: ...
186
+ # System.Boolean Windows.System.Power.PowerManager::get_IsEnergySaverStatus2Supported()
187
+ @_property
188
+ def is_energy_saver_status2_supported(cls) -> bool: ...
135
189
 
136
190
  @typing.final
137
191
  class PowerManager(winrt.system.Object, metaclass=PowerManager_Static):
138
- pass
192
+ def __new__(cls, _: typing.Never, /) -> typing.Self:
193
+ """A class of static members only, so there is nothing to create."""
139
194
 
@@ -0,0 +1,202 @@
1
+ format 4.0
2
+ census 2e30db26-66c8-4551-85b9-a537376d8f99 1
3
+ namespace Windows.System.Power
4
+
5
+ class Windows.System.Power.BackgroundEnergyManager static python_type
6
+ py BackgroundEnergyManager
7
+ factory Windows.System.Power.IBackgroundEnergyManagerStatics
8
+ property excessive_usage_level static
9
+ get get_ExcessiveUsageLevel slot=9 inputs=0 outputs=1 declaring=Windows.System.Power.IBackgroundEnergyManagerStatics shape=4 static deprecated
10
+ out uint32 return
11
+ property low_usage_level static
12
+ get get_LowUsageLevel slot=6 inputs=0 outputs=1 declaring=Windows.System.Power.IBackgroundEnergyManagerStatics shape=4 static deprecated
13
+ out uint32 return
14
+ property max_acceptable_usage_level static
15
+ get get_MaxAcceptableUsageLevel slot=8 inputs=0 outputs=1 declaring=Windows.System.Power.IBackgroundEnergyManagerStatics shape=4 static deprecated
16
+ out uint32 return
17
+ property near_max_acceptable_usage_level static
18
+ get get_NearMaxAcceptableUsageLevel slot=7 inputs=0 outputs=1 declaring=Windows.System.Power.IBackgroundEnergyManagerStatics shape=4 static deprecated
19
+ out uint32 return
20
+ property near_termination_usage_level static
21
+ get get_NearTerminationUsageLevel slot=10 inputs=0 outputs=1 declaring=Windows.System.Power.IBackgroundEnergyManagerStatics shape=4 static deprecated
22
+ out uint32 return
23
+ property recent_energy_usage static
24
+ get get_RecentEnergyUsage slot=12 inputs=0 outputs=1 declaring=Windows.System.Power.IBackgroundEnergyManagerStatics shape=4 static deprecated
25
+ out uint32 return
26
+ property recent_energy_usage_level static
27
+ get get_RecentEnergyUsageLevel slot=13 inputs=0 outputs=1 declaring=Windows.System.Power.IBackgroundEnergyManagerStatics shape=4 static deprecated
28
+ out uint32 return
29
+ property termination_usage_level static
30
+ get get_TerminationUsageLevel slot=11 inputs=0 outputs=1 declaring=Windows.System.Power.IBackgroundEnergyManagerStatics shape=4 static deprecated
31
+ out uint32 return
32
+ event recent_energy_usage_increased static
33
+ add add_RecentEnergyUsageIncreased slot=14 inputs=1 outputs=1 declaring=Windows.System.Power.IBackgroundEnergyManagerStatics shape=51 static deprecated
34
+ in delegate type=Windows.Foundation.EventHandler<System.Object> name=handler
35
+ out event_token type=Windows.Foundation.EventRegistrationToken return
36
+ remove remove_RecentEnergyUsageIncreased slot=15 inputs=1 outputs=0 declaring=Windows.System.Power.IBackgroundEnergyManagerStatics shape=26 static deprecated
37
+ in event_token type=Windows.Foundation.EventRegistrationToken name=token
38
+ event recent_energy_usage_returned_to_low static
39
+ add add_RecentEnergyUsageReturnedToLow slot=16 inputs=1 outputs=1 declaring=Windows.System.Power.IBackgroundEnergyManagerStatics shape=51 static deprecated
40
+ in delegate type=Windows.Foundation.EventHandler<System.Object> name=handler
41
+ out event_token type=Windows.Foundation.EventRegistrationToken return
42
+ remove remove_RecentEnergyUsageReturnedToLow slot=17 inputs=1 outputs=0 declaring=Windows.System.Power.IBackgroundEnergyManagerStatics shape=26 static deprecated
43
+ in event_token type=Windows.Foundation.EventRegistrationToken name=token
44
+
45
+ enum Windows.System.Power.BatteryStatus python_type
46
+ py BatteryStatus
47
+ signature enum(Windows.System.Power.BatteryStatus;i4)
48
+ constant NOT_PRESENT 0
49
+ constant DISCHARGING 1
50
+ constant IDLE 2
51
+ constant CHARGING 3
52
+
53
+ enum Windows.System.Power.EnergySaverStatus python_type
54
+ py EnergySaverStatus
55
+ signature enum(Windows.System.Power.EnergySaverStatus;i4)
56
+ constant DISABLED 0
57
+ constant OFF 1
58
+ constant ON 2
59
+
60
+ enum Windows.System.Power.EnergySaverStatus2 python_type
61
+ py EnergySaverStatus2
62
+ signature enum(Windows.System.Power.EnergySaverStatus2;i4)
63
+ constant UNKNOWN 0
64
+ constant OFF 1
65
+ constant STANDARD 2
66
+ constant HIGH_SAVINGS 3
67
+
68
+ delegate Windows.Foundation.EventHandler<System.Object> concrete
69
+ py winrt.windows.foundation.EventHandler[Object]
70
+ guid c50898f6-c536-5f47-8583-8b2c2438a13b
71
+ signature pinterface({9de1c535-6ae1-11e0-84e1-18a905bcc53f};cinterface(IInspectable))
72
+ base Windows.Foundation.EventHandler
73
+ argument System.Object
74
+ method -
75
+ method Invoke slot=3 inputs=2 outputs=0 shape=51 reverse=4
76
+ in object name=sender
77
+ in object name=args
78
+
79
+ class Windows.System.Power.ForegroundEnergyManager static python_type
80
+ py ForegroundEnergyManager
81
+ factory Windows.System.Power.IForegroundEnergyManagerStatics
82
+ property excessive_usage_level static
83
+ get get_ExcessiveUsageLevel slot=9 inputs=0 outputs=1 declaring=Windows.System.Power.IForegroundEnergyManagerStatics shape=4 static deprecated
84
+ out uint32 return
85
+ property low_usage_level static
86
+ get get_LowUsageLevel slot=6 inputs=0 outputs=1 declaring=Windows.System.Power.IForegroundEnergyManagerStatics shape=4 static deprecated
87
+ out uint32 return
88
+ property max_acceptable_usage_level static
89
+ get get_MaxAcceptableUsageLevel slot=8 inputs=0 outputs=1 declaring=Windows.System.Power.IForegroundEnergyManagerStatics shape=4 static deprecated
90
+ out uint32 return
91
+ property near_max_acceptable_usage_level static
92
+ get get_NearMaxAcceptableUsageLevel slot=7 inputs=0 outputs=1 declaring=Windows.System.Power.IForegroundEnergyManagerStatics shape=4 static deprecated
93
+ out uint32 return
94
+ property recent_energy_usage static
95
+ get get_RecentEnergyUsage slot=10 inputs=0 outputs=1 declaring=Windows.System.Power.IForegroundEnergyManagerStatics shape=4 static deprecated
96
+ out uint32 return
97
+ property recent_energy_usage_level static
98
+ get get_RecentEnergyUsageLevel slot=11 inputs=0 outputs=1 declaring=Windows.System.Power.IForegroundEnergyManagerStatics shape=4 static deprecated
99
+ out uint32 return
100
+ event recent_energy_usage_increased static
101
+ add add_RecentEnergyUsageIncreased slot=12 inputs=1 outputs=1 declaring=Windows.System.Power.IForegroundEnergyManagerStatics shape=51 static deprecated
102
+ in delegate type=Windows.Foundation.EventHandler<System.Object> name=handler
103
+ out event_token type=Windows.Foundation.EventRegistrationToken return
104
+ remove remove_RecentEnergyUsageIncreased slot=13 inputs=1 outputs=0 declaring=Windows.System.Power.IForegroundEnergyManagerStatics shape=26 static deprecated
105
+ in event_token type=Windows.Foundation.EventRegistrationToken name=token
106
+ event recent_energy_usage_returned_to_low static
107
+ add add_RecentEnergyUsageReturnedToLow slot=14 inputs=1 outputs=1 declaring=Windows.System.Power.IForegroundEnergyManagerStatics shape=51 static deprecated
108
+ in delegate type=Windows.Foundation.EventHandler<System.Object> name=handler
109
+ out event_token type=Windows.Foundation.EventRegistrationToken return
110
+ remove remove_RecentEnergyUsageReturnedToLow slot=15 inputs=1 outputs=0 declaring=Windows.System.Power.IForegroundEnergyManagerStatics shape=26 static deprecated
111
+ in event_token type=Windows.Foundation.EventRegistrationToken name=token
112
+
113
+ interface Windows.System.Power.IBackgroundEnergyManagerStatics
114
+ guid b3161d95-1180-4376-96e1-4095568147ce
115
+
116
+ interface Windows.System.Power.IForegroundEnergyManagerStatics
117
+ guid 9ff86872-e677-4814-9a20-5337ca732b98
118
+
119
+ interface Windows.System.Power.IPowerManagerStatics
120
+ guid 1394825d-62ce-4364-98d5-aa28c7fbd15b
121
+
122
+ interface Windows.System.Power.IPowerManagerStatics2
123
+ guid 67a446c3-4f2e-5d56-b2e8-7707c264745b
124
+
125
+ class Windows.System.Power.PowerManager static python_type
126
+ py PowerManager
127
+ factory Windows.System.Power.IPowerManagerStatics
128
+ factory Windows.System.Power.IPowerManagerStatics2
129
+ property battery_status static
130
+ get get_BatteryStatus slot=9 inputs=0 outputs=1 declaring=Windows.System.Power.IPowerManagerStatics shape=4 static
131
+ out enum32 type=Windows.System.Power.BatteryStatus return
132
+ property energy_saver_status static
133
+ get get_EnergySaverStatus slot=6 inputs=0 outputs=1 declaring=Windows.System.Power.IPowerManagerStatics shape=4 static
134
+ out enum32 type=Windows.System.Power.EnergySaverStatus return
135
+ property power_supply_status static
136
+ get get_PowerSupplyStatus slot=12 inputs=0 outputs=1 declaring=Windows.System.Power.IPowerManagerStatics shape=4 static
137
+ out enum32 type=Windows.System.Power.PowerSupplyStatus return
138
+ property remaining_charge_percent static
139
+ get get_RemainingChargePercent slot=15 inputs=0 outputs=1 declaring=Windows.System.Power.IPowerManagerStatics shape=4 static
140
+ out int32 return
141
+ property remaining_discharge_time static
142
+ get get_RemainingDischargeTime slot=18 inputs=0 outputs=1 declaring=Windows.System.Power.IPowerManagerStatics shape=4 static
143
+ out timespan return
144
+ property energy_saver_status2 static
145
+ get get_EnergySaverStatus2 slot=6 inputs=0 outputs=1 declaring=Windows.System.Power.IPowerManagerStatics2 shape=4 static
146
+ out enum32 type=Windows.System.Power.EnergySaverStatus2 return
147
+ property is_energy_saver_status2_supported static
148
+ get get_IsEnergySaverStatus2Supported slot=7 inputs=0 outputs=1 declaring=Windows.System.Power.IPowerManagerStatics2 shape=4 static
149
+ out boolean return
150
+ event energy_saver_status2_changed static
151
+ add add_EnergySaverStatus2Changed slot=8 inputs=1 outputs=1 declaring=Windows.System.Power.IPowerManagerStatics2 shape=51 static
152
+ in delegate type=Windows.Foundation.EventHandler<System.Object> name=handler
153
+ out event_token type=Windows.Foundation.EventRegistrationToken return
154
+ remove remove_EnergySaverStatus2Changed slot=9 inputs=1 outputs=0 declaring=Windows.System.Power.IPowerManagerStatics2 shape=26 static
155
+ in event_token type=Windows.Foundation.EventRegistrationToken name=token
156
+ event battery_status_changed static
157
+ add add_BatteryStatusChanged slot=10 inputs=1 outputs=1 declaring=Windows.System.Power.IPowerManagerStatics shape=51 static
158
+ in delegate type=Windows.Foundation.EventHandler<System.Object> name=handler
159
+ out event_token type=Windows.Foundation.EventRegistrationToken return
160
+ remove remove_BatteryStatusChanged slot=11 inputs=1 outputs=0 declaring=Windows.System.Power.IPowerManagerStatics shape=26 static
161
+ in event_token type=Windows.Foundation.EventRegistrationToken name=token
162
+ event energy_saver_status_changed static
163
+ add add_EnergySaverStatusChanged slot=7 inputs=1 outputs=1 declaring=Windows.System.Power.IPowerManagerStatics shape=51 static
164
+ in delegate type=Windows.Foundation.EventHandler<System.Object> name=handler
165
+ out event_token type=Windows.Foundation.EventRegistrationToken return
166
+ remove remove_EnergySaverStatusChanged slot=8 inputs=1 outputs=0 declaring=Windows.System.Power.IPowerManagerStatics shape=26 static
167
+ in event_token type=Windows.Foundation.EventRegistrationToken name=token
168
+ event power_supply_status_changed static
169
+ add add_PowerSupplyStatusChanged slot=13 inputs=1 outputs=1 declaring=Windows.System.Power.IPowerManagerStatics shape=51 static
170
+ in delegate type=Windows.Foundation.EventHandler<System.Object> name=handler
171
+ out event_token type=Windows.Foundation.EventRegistrationToken return
172
+ remove remove_PowerSupplyStatusChanged slot=14 inputs=1 outputs=0 declaring=Windows.System.Power.IPowerManagerStatics shape=26 static
173
+ in event_token type=Windows.Foundation.EventRegistrationToken name=token
174
+ event remaining_charge_percent_changed static
175
+ add add_RemainingChargePercentChanged slot=16 inputs=1 outputs=1 declaring=Windows.System.Power.IPowerManagerStatics shape=51 static
176
+ in delegate type=Windows.Foundation.EventHandler<System.Object> name=handler
177
+ out event_token type=Windows.Foundation.EventRegistrationToken return
178
+ remove remove_RemainingChargePercentChanged slot=17 inputs=1 outputs=0 declaring=Windows.System.Power.IPowerManagerStatics shape=26 static
179
+ in event_token type=Windows.Foundation.EventRegistrationToken name=token
180
+ event remaining_discharge_time_changed static
181
+ add add_RemainingDischargeTimeChanged slot=19 inputs=1 outputs=1 declaring=Windows.System.Power.IPowerManagerStatics shape=51 static
182
+ in delegate type=Windows.Foundation.EventHandler<System.Object> name=handler
183
+ out event_token type=Windows.Foundation.EventRegistrationToken return
184
+ remove remove_RemainingDischargeTimeChanged slot=20 inputs=1 outputs=0 declaring=Windows.System.Power.IPowerManagerStatics shape=26 static
185
+ in event_token type=Windows.Foundation.EventRegistrationToken name=token
186
+
187
+ enum Windows.System.Power.PowerSupplyStatus python_type
188
+ py PowerSupplyStatus
189
+ signature enum(Windows.System.Power.PowerSupplyStatus;i4)
190
+ constant NOT_PRESENT 0
191
+ constant INADEQUATE 1
192
+ constant ADEQUATE 2
193
+
194
+ class System.Object external
195
+ py winrt.system.Object
196
+
197
+ delegate Windows.Foundation.EventHandler external parameterized
198
+ py winrt.windows.foundation.EventHandler
199
+ guid 9de1c535-6ae1-11e0-84e1-18a905bcc53f
200
+
201
+ struct Windows.Foundation.EventRegistrationToken external
202
+ py winrt.windows.foundation.EventRegistrationToken
@@ -1,25 +0,0 @@
1
- Metadata-Version: 2.4
2
- Name: winrt-Windows.System.Power
3
- Version: 3.2.1
4
- Summary: Python projection of Windows Runtime (WinRT) APIs
5
- License-Expression: MIT
6
- Project-URL: Documentation, https://pywinrt.readthedocs.io
7
- Project-URL: Repository, https://github.com/pywinrt/pywinrt
8
- Project-URL: Changelog, https://github.com/pywinrt/pywinrt/blob/main/CHANGELOG.md
9
- Classifier: Operating System :: Microsoft :: Windows
10
- Classifier: Programming Language :: Python :: 3
11
- Classifier: Programming Language :: Python :: Implementation :: CPython
12
- Classifier: Intended Audience :: Developers
13
- Requires-Python: >=3.9
14
- Description-Content-Type: text/markdown
15
- Requires-Dist: winrt-runtime~=3.2.1.0
16
- Provides-Extra: all
17
- Requires-Dist: winrt-Windows.Foundation[all]~=3.2.1.0; extra == "all"
18
-
19
- <!-- warning: Please don't edit this file. It was automatically generated. -->
20
-
21
- # winrt-Windows.System.Power
22
-
23
- Windows Runtime (WinRT) APIs for for the `Windows.System.Power` namespace.
24
-
25
- This package provides the `winrt.windows.system.power` module.
@@ -1,7 +0,0 @@
1
- <!-- warning: Please don't edit this file. It was automatically generated. -->
2
-
3
- # winrt-Windows.System.Power
4
-
5
- Windows Runtime (WinRT) APIs for for the `Windows.System.Power` namespace.
6
-
7
- This package provides the `winrt.windows.system.power` module.
@@ -1,3 +0,0 @@
1
- # WARNING: Please don't edit this file. It was generated by Python/WinRT v3.2.1
2
-
3
- winrt-Windows.Foundation[all]~=3.2.1.0