Neuron®
The Neuron® is the basis for the creation of open and secure federated networks for smart societies.
Loading...
Searching...
No Matches
StateMachineNewStateNotificationEvent.cs
2using NeuroFeatures;
4using System.Text;
5
7{
12 {
17 : base()
18 {
19 }
20
26 : base(e)
27 {
28 this.NewState = e.NewState;
29 }
30
34 public string? NewState { get; set; }
35
39 public override async Task<string> GetDescription()
40 {
41 StringBuilder sb = new();
42
43 sb.Append(ServiceRef.Localizer[nameof(AppResources.StateChangedTo), this.NewState ?? string.Empty]);
44 sb.Append(": ");
45 sb.Append(await base.GetDescription());
46
47 return sb.ToString();
48 }
49 }
50}
A strongly-typed resource class, for looking up localized strings, etc.
static string StateChangedTo
Looks up a localized string similar to State changed to {0}.
Contains information about a change in a state-machine associated with a token.
StateMachineNewStateNotificationEvent()
Contains information about a change in a state-machine associated with a token.
override async Task< string > GetDescription()
Gets a descriptive text for the event.
StateMachineNewStateNotificationEvent(NewStateEventArgs e)
Contains information about a change in a state-machine associated with a token.
Base class that references services in the app.
Definition: ServiceRef.cs:43
static IReportingStringLocalizer Localizer
Localization service
Definition: ServiceRef.cs:370
Event arguments events when the current state of a state-machine has changed.