Files

30 lines
1.9 KiB
Markdown
Raw Permalink Normal View History

2026-04-17 14:55:32 -04:00
---
source_files:
- DataPRO/Modules/SystemSettings/RealtimeSettings/ViewModel/RealtimeSettingsViewModel.cs
generated_at: "2026-04-17T16:15:27.065009+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "45601297f81ff1b3"
---
# ViewModel
### Purpose
This module provides the ViewModel for the Realtime Settings view, managing UI state and coordinating between the view and the broader application infrastructure. It handles user notification display, busy indicator state, and exposes properties for configuring realtime sample rates and delays. The ViewModel follows the MVVM pattern using Prism and Unity for dependency injection and event aggregation.
### Public Interface
**`RealtimeSettingsViewModel` (class)**
- Signature: `public class RealtimeSettingsViewModel : BasePropertyChanged, IRealtimeSettingsViewModel`
- Attributes: `[Export(typeof(IRealtimeSettingsView))]`, `[PartCreationPolicy(CreationPolicy.Shared)]`
**Constructor:**
- `public RealtimeSettingsViewModel(IRealtimeSettingsView view, IRegionManager regionManager, IEventAggregator eventAggregator, IUnityContainer unityContainer)`
- Initializes the ViewModel, sets the View's DataContext to itself, creates `NotificationRequest` and `ConfirmationRequest` interaction requests, subscribes to `RaiseNotification` and `BusyIndicatorChangeNotification` events.
**Properties:**
- `IRealtimeSettingsView View { get; private set; }` - The associated view instance.
- `InteractionRequest<Notification> NotificationRequest { get; private set; }` - Used to raise notification dialogs.
- `InteractionRequest<Confirmation> ConfirmationRequest { get; private set; }` - Used to raise confirmation dialogs.
- `string RealtimeSampleRate { get; set; }` - Backing field: `_realtimeSampleRate`. Raises property changed for "RealtimeSampleRate".
- `string RealtimeSampleRates { get; set; }` - Backing field: `_realtimeSampleRates`. Raises property changed for both "Real