FindMyFiles

FindMyFiles.Services

Notifier Class

Process-wide notification funnel. Anything (global handlers, background tasks, the engine callback) can post from any thread; the ViewModel subscribes and marshals to the UI InfoBar stack. Posts are also mirrored to the file log so nothing the user saw is missing from a bug report.

public static class Notifier

Inheritance System.Object → Notifier

Methods

Notifier.Attach(Action<AppNotification>) Method

Drain posts that arrived before the UI was ready.

public static void Attach(System.Action<FindMyFiles.Services.AppNotification> handler);

Parameters

handler System.Action<AppNotification>

Subscriber invoked for each notification, including the replayed pre-subscription backlog.

Notifier.Post(NotifySeverity, string, string, string, Action) Method

Post a notification from any thread. Mirrors it to the file log at the level matching severity (so nothing the user saw is missing from a bug report), then hands it to the subscriber — or queues it until one attaches.

public static void Post(FindMyFiles.Services.NotifySeverity severity, string message, string? detail=null, string? actionLabel=null, System.Action? action=null);

Parameters

severity NotifySeverity

Style/level and auto-dismiss policy.

message System.String

Headline text.

detail System.String

Optional secondary line (e.g. exception message).

actionLabel System.String

Caption for an optional action button.

action System.Action

Callback for the action button, if any.

Events

Notifier.Posted Event

Raised on the posting thread for each notification once a subscriber exists. Subscribe via Attach(Action<AppNotification>) (which also replays the pre-subscription backlog) rather than touching this directly; the ViewModel handler marshals to the UI thread.

public static event Action<AppNotification>? Posted;

Event Type

System.Action<AppNotification>