1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-16 14:57:25 +08:00
osu-lazer/osu.Game/Utils/BatteryInfo.cs
2022-07-30 14:26:19 +02:00

25 lines
821 B
C#

// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
namespace osu.Game.Utils
{
/// <summary>
/// Provides access to the system's power status.
/// </summary>
public abstract class BatteryInfo
{
/// <summary>
/// The charge level of the battery, from <c>0</c> to <c>1</c>, or <c>null</c> if a battery isn't present.
/// </summary>
public abstract double? ChargeLevel { get; }
/// <summary>
/// Whether the current power source is the battery.
/// </summary>
/// <remarks>
/// This is <c>false</c> when the device is charging or doesn't have a battery.
/// </remarks>
public abstract bool OnBattery { get; }
}
}