Sensor state changed event arguments class.
Inheritance: System.EventArgs
Beispiel #1
0
 /// <summary>
 /// Raises the state changed event.
 /// </summary>
 /// <param name="e">
 /// The event arguments.
 /// </param>
 protected virtual void OnStateChanged(SensorStateChangedEventArgs e)
 {
     if (this.StateChanged != null)
     {
         this.StateChanged(this, e);
     }
 }
Beispiel #2
0
		/// <summary>
		/// Internal handler for the pilot light sensor state changed event.
		/// This fires pilot light state changed event when the pilot light's
		/// state changes.
		/// </summary>
		/// <param name="sender">
		/// The object raising the event (a reference to the sensor object).
		/// </param>
		/// <param name="e">
		/// The event arguments.
		/// </param>
		private void InternalHandleSensorStateChange(Object sender, SensorStateChangedEventArgs e) {
			if (e.NewState != this._pilotLightOnSensorState) {
				this.Off();
			}

			base.OnPilotLightStateChanged(new FireplacePilotLightEventArgs(this.IsPilotLightOn));
		}
Beispiel #3
0
		/// <summary>
		/// Handles the sensor state changed event.
		/// </summary>
		/// <param name="sender">
		/// The object firing the event. Should be a reference to
		/// the sensor insance that triggered the event.
		/// </param>
		/// <param name="e">
		/// The event arguments.
		/// </param>
		private void OnSensorStateChanged(Object sender, SensorStateChangedEventArgs e) {
			OpenerState oldState = this.GetOpenerState(e.OldState);
			OpenerState newState = this.GetOpenerState(e.NewState);
			base.OnStateChanged(new OpenerStateChangeEventArgs(oldState, newState));
		}
Beispiel #4
0
		/// <summary>
		/// Raises the state changed event.
		/// </summary>
		/// <param name="e">
		/// The event arguments.
		/// </param>
		protected virtual void OnStateChanged(SensorStateChangedEventArgs e) {
			if (this.StateChanged != null) {
				this.StateChanged(this, e);
			}
		}