UtilPower Class

Contains system powering related utilities.

Definition

Namespace: DevCase.Core.IO.Devices.Power
Assembly: DevCase.net48 (in DevCase.net48.dll) Version: 6.0.0.0 (6.0)
XMLNS for XAML: Not mapped to an xmlns.
public sealed class UtilPower
Inheritance
Object    UtilPower

Properties

ActivePowerPlan Gets or sets the active power plan on the current system.
PowerPlans Gets all the power plans available on the current system.

Methods

AbortShutdown Aborts a system shutdown operation that has been initiated (unless a LogOff).
Equals Determines whether the specified object is equal to the current object.
(Inherited from Object)
GetHashCode Serves as the default hash function.
(Inherited from Object)
GetType Gets the Type of the current instance.
(Inherited from Object)
Hibernate Sets the system in Hibernate state.
HybridShutdown Shutdowns the specified computer and prepares the system for a faster startup.

Use this function only for Windows 8/8.1

LogOff Shuts down all processes running in the logon session and then logs off the interactive user.
PowerOff Shutdowns the specified computer and begins powered down.
RemoveAwakeSignal Removes any previously sent Awake signal.

Call this function to return to previous state when the caller thread has finished.

Restart Restarts the specified computer.
RestartApps Restarts the specified computer, also restarts any applications that have been registered for restart in the system.
SendAwakeSignal Sends an Awake signal to prevent the system from turning off the display and entering into Sleep or Hibernation modes.
SetMonitorState(MonitorState) Sets the state of the monitor.
SetMonitorState(IntPtr, MonitorState) Sets the state of the monitor.
Shutdown Shutdowns the specified computer.
Suspend Sets the system in Suspend state.
ToString Returns a string that represents the current object.
(Inherited from Object)

Fields

MaxShutdownTimeout The maximum number of seconds to wait before shutting down the computer.
PowerPlanBalanced Gets the Balanced PowerPlan.
PowerPlanMaximumPerformance Gets the Maximum Performance PowerPlan.
PowerPlanMinimumPerformance Gets the Minimum Performance PowerPlan.

Extension Methods

CanConvertTo Determines whether the source object can be converted to the specified target type.
(Defined by ObjectExtensions)
CanConvertToT Determines whether the source object can be converted to the specified target type.
(Defined by ObjectExtensions)
ConvertToT Converts an object to the specified target type.

If the conversion fails, an exception is thrown.
(Defined by ObjectExtensions)

ConvertToT Converts an object to the specified target type.

If the conversion fails, returns the specified default value.
(Defined by ObjectExtensions)

IsDisposable Determines whether the specified object is a disposable type (i.e., it implements IDisposable interface).
(Defined by ObjectExtensions)
Speak Speaks the string representation of the source object by using the operating system integrated text-to-speech synthesizer.
(Defined by ObjectExtensions)
Speak Speaks the string representation of the source object by using the operating system integrated text-to-speech synthesizer.
(Defined by ObjectExtensions)
ThrowIfNullTException Throws the specified exception if the source object is null.
(Defined by ObjectExtensions)

See Also