C# Class CyrusBuilt.MonoPi.Components.Switches.SwitchBase

Base class for switch component abstractions.
Inheritance: ComponentBase, ISwitch
ファイルを表示 Open project: cyrusbuilt/MonoPi

Public Methods

Method Description
IsState ( SwitchState state ) : System.Boolean

Determines whether the state of this instance is the specified state.

Protected Methods

Method Description
OnSwitchStateChanged ( SwitchStateChangeEventArgs e ) : void

Raises the switch state changed event.

SwitchBase ( ) : System

Initializes a new instance of the CyrusBuilt.MonoPi.Components.Switches.SwitchBase class. This is the default constructor.

Method Details

IsState() public method

Determines whether the state of this instance is the specified state.
public IsState ( SwitchState state ) : System.Boolean
state SwitchState /// The state to compare to. ///
return System.Boolean

OnSwitchStateChanged() protected method

Raises the switch state changed event.
protected OnSwitchStateChanged ( SwitchStateChangeEventArgs e ) : void
e SwitchStateChangeEventArgs /// The event arguments. ///
return void

SwitchBase() protected method

Initializes a new instance of the CyrusBuilt.MonoPi.Components.Switches.SwitchBase class. This is the default constructor.
protected SwitchBase ( ) : System
return System