PowerState Enum

Namespace
Shiny
Interfaces
  • IComparable
  • IFormattable
  • IConvertible
Base Types
  • object
  • ValueType
  • Enum
graph BT Type-->Base0["Enum"] Base0-->Base1["ValueType"] Base1-->Base2["object"] Type-.->Interface0["IComparable"] Type-.->Interface1["IFormattable"] Type-.->Interface2["IConvertible"] Type["PowerState"] class Type type-node

Syntax

public enum PowerState

Fields

Name Constant Value Summary
Charged 2
Device is fully charged and plugged in
static
Charging 1
Device is plugged in and charging
static
Discharging 4
Device is running on battery
static
NoBattery 3
No battery has been detected so device is plugged in
static
Unknown 0
Power state hasn't been checked yet or it is in an unknown state
static

Extension Methods

Name Value Summary
GetPropertyInfo<PowerState, TRet>(Expression<Func<PowerState, TRet>>) PropertyInfo
Reflects out property information based on the expression value
ReflectGet(string) object
Gets an objects property dynamically through reflection - will throw an exception if proper has no getter or property does not exists
ReflectGet<PowerState, TReturn>(Expression<Func<PowerState, TReturn>>) TReturn
Gets an objects property dynamically through reflection - will throw an exception if proper has no getter or property does not exists
ReflectSet(string, object) void
Sets an objects property dynamically through reflection - will throw an exception if proper has no setter, wrong type, or property does not exists
GitHub