sharee.bike-App/ShareeSharedGuiLib/ViewModel/Bar.cs
Anja Müller-Meißner 573fe77e12 Version 3.0.337
2022-08-30 15:42:25 +02:00

38 lines
761 B
C#

using System;
using System.Collections.Generic;
using System.Text;
namespace ShareeSharedGuiLib.ViewModel
{
public enum ChargingState
{
Loaded,
Empty
}
public class Bar
{
public Bar(ChargingState? state = null)
{
State = state;
}
/// <summary>
/// Gets a value indicating whether bar is charged or not. Null if state is unknown.
/// </summary>
public ChargingState? State { get; private set; } = null;
public string Text
{
get
{
if (State == null)
return string.Empty;
return State == ChargingState.Loaded ? " + " : " - ";
}
}
}
}