C# 클래스 CyrusBuilt.MonoPi.Components.Lights.DimmableLightBase

Base class for dimmable light component abstractions.
상속: ComponentBase, IDimmableLight
파일 보기 프로젝트 열기: cyrusbuilt/MonoPi

공개 메소드들

메소드 설명
GetLevelPercentage ( ) : float

Gets the current brightness level percentage.

GetLevelPercentage ( Int32 level ) : float

Gets the current brightness level percentage.

Off ( ) : void

Switches the light off.

On ( ) : void

Switches the light on.

보호된 메소드들

메소드 설명
DimmableLightBase ( ) : System

Initializes a new instance of the CyrusBuilt.MonoPi.Components.Lights.DimmableLightBase class. This is the default constructor.

OnLevelChanged ( LightLevelChangeEventArgs e ) : void

Raises the level changed event.

OnStateChanged ( LightStateChangeEventArgs e ) : void

Raises the state changed event.

메소드 상세

DimmableLightBase() 보호된 메소드

Initializes a new instance of the CyrusBuilt.MonoPi.Components.Lights.DimmableLightBase class. This is the default constructor.
protected DimmableLightBase ( ) : System
리턴 System

GetLevelPercentage() 공개 메소드

Gets the current brightness level percentage.
public GetLevelPercentage ( ) : float
리턴 float

GetLevelPercentage() 공개 메소드

Gets the current brightness level percentage.
public GetLevelPercentage ( Int32 level ) : float
level System.Int32 /// The brightness level. ///
리턴 float

Off() 공개 메소드

Switches the light off.
public Off ( ) : void
리턴 void

On() 공개 메소드

Switches the light on.
public On ( ) : void
리턴 void

OnLevelChanged() 보호된 메소드

Raises the level changed event.
protected OnLevelChanged ( LightLevelChangeEventArgs e ) : void
e LightLevelChangeEventArgs /// The event arguments. ///
리턴 void

OnStateChanged() 보호된 메소드

Raises the state changed event.
protected OnStateChanged ( LightStateChangeEventArgs e ) : void
e LightStateChangeEventArgs /// The event arguments. ///
리턴 void