Table of Contents

Interface IOperatingModeManager

Namespace
Loehnert.Lisrt.OperatingMode
Assembly
Loehnert.Lisrt.dll

Interface for a operating mode manager.

public interface IOperatingModeManager
Extension Methods

Properties

CurrentMode

Gets the current operating mode.

IOperatingMode CurrentMode { get; }

Property Value

IOperatingMode

ModeIsChanging

Gets a value indicating whether the current mode is changing.

bool ModeIsChanging { get; }

Property Value

bool

Modes

Gets all operating modes.

KeyItemCollection<IOperatingMode> Modes { get; }

Property Value

KeyItemCollection<IOperatingMode>

Methods

TrySetMode(IOperatingMode)

Sets a new operating mode by object with key.

bool TrySetMode(IOperatingMode newMode)

Parameters

newMode IOperatingMode

The new mode.

Returns

bool

true if the mode has set successfully, otherwise false.

TrySetMode(string)

Sets a new operating mode by key.

bool TrySetMode(string modeKey)

Parameters

modeKey string

The key of the new mode.

Returns

bool

true if the mode has set successfully, otherwise false.

Events

OperatingModeChanged

Occurs when the current operating mode has changed.

event EventHandler<OperatingModeChangedEventArgs> OperatingModeChanged

Event Type

EventHandler<OperatingModeChangedEventArgs>

OperatingModeChanging

Occurs before the operating mode changes.

event EventHandler<OperatingModeChangingEventArgs> OperatingModeChanging

Event Type

EventHandler<OperatingModeChangingEventArgs>