This commit is contained in:
2026-04-17 14:55:32 -04:00
commit bc3ac1d4c9
18017 changed files with 4371742 additions and 0 deletions

View File

@@ -0,0 +1,26 @@
---
source_files:
- Common/DTS.CommonCore/Attributes/VersionAttribute.cs
generated_at: "2026-04-17T16:38:27.969703+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "3c822eef83b93a70"
---
# Documentation: VersionAttribute.cs
## 1. Purpose
This module defines a custom attribute named `VersionAttribute` within the `DTS.Common.Attributes` namespace. It allows developers to annotate classes, methods, or other code elements with an immutable integer version number, facilitating metadata-driven version tracking within the system.
## 2. Public Interface
* **`public class VersionAttribute : Attribute`**
* The primary class definition inheriting from `System.Attribute`.
* **`public VersionAttribute(int version)`**
* **Signature:** Constructor accepting an integer.
* **Behavior:** Initializes a new instance of the attribute and sets the `Version` property to the provided integer value.
* **`public int Version { get; private set; }`**
* **Type:** `int`
*

View File

@@ -0,0 +1,103 @@
---
source_files:
- Common/DTS.CommonCore/Base/Classes/BasePropertyChanged.cs
- Common/DTS.CommonCore/Base/Classes/DisplayResourceAttribute.cs
- Common/DTS.CommonCore/Base/Classes/DescriptionResourceAttribute.cs
- Common/DTS.CommonCore/Base/Classes/DynamicTypeDescriptor.cs
generated_at: "2026-04-17T15:37:43.148987+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "3c060c718b0c2281"
---
# Documentation: DTS.Common.Base Classes
## 1. Purpose
This module provides foundational infrastructure for the DTS common core library, offering three distinct capabilities: (1) a base implementation of the `INotifyPropertyChanged` pattern via `BasePropertyChanged` for MVVM-style data binding; (2) localization-aware attributes (`DisplayResourceAttribute` and `DescriptionResourceAttribute`) that resolve display names and descriptions from a centralized string resource manager at runtime; and (3) a sophisticated `DynamicTypeDescriptor` class that enables runtime modification of type metadata for scenarios requiring dynamic property grids or flexible property systems, such as Entity Framework scenarios where design-time properties need runtime adjustment.
---
## 2. Public Interface
### BasePropertyChanged (Abstract Class)
**Implements:** `IBasePropertyChanged`
| Member | Signature | Description |
|--------|-----------|-------------|
| `PropertyChanged` | `event PropertyChangedEventHandler PropertyChanged` | Event raised when a property value changes. Marked `virtual`. |
| `SetProperty<T>` | `bool SetProperty<T>(ref T storage, T value, String propertyName = null)` | Sets the property value if different from current; returns `true` if changed, `false` otherwise. Raises `PropertyChanged` on change. |
| `OnPropertyChanged` | `void OnPropertyChanged(string propertyName = null)` | Raises the `PropertyChanged` event. Marked `virtual`. |
---
### DisplayResourceAttribute (Class)
**Inherits:** `DisplayNameAttribute`
| Member | Signature | Description |
|--------|-----------|-------------|
| Constructor | `DisplayResourceAttribute(string resourceId)` | Initializes with a resource identifier to look up. |
| `DisplayName` | `override string DisplayName` | Looks up the display name via `Strings.Strings.ResourceManager.GetString(_resourceId)`. Returns `"##ResourceNotFound##" + _resourceId` if lookup fails. |
---
### DescriptionResourceAttribute (Class)
**Inherits:** `DescriptionAttribute`
| Member | Signature | Description |
|--------|-----------|-------------|
| Constructor | `DescriptionResourceAttribute(string resourceId)` | Initializes with a resource identifier to look up. |
| `Description` | `override string Description` | Looks up the description via `Strings.Strings.ResourceManager.GetString(_resourceId)`. Returns `"##DescriptionNotFound##" + _resourceId` if lookup fails. |
---
### DynamicTypeDescriptor (Sealed Class)
**Implements:** `ICustomTypeDescriptor`, `INotifyPropertyChanged`
| Member | Signature | Description |
|--------|-----------|-------------|
| `PropertyChanged` | `event PropertyChangedEventHandler PropertyChanged` | Event raised when a property value changes. |
| Constructor | `DynamicTypeDescriptor(Type type)` | Initializes from a `Type`. Throws `ArgumentNullException` if `type` is null. Filters to only browsable properties. |
| `GetPropertyValue<T>` | `T GetPropertyValue<T>(string name, T defaultValue)` | Gets a property value by name, returning `defaultValue` if not found or on conversion failure. Throws `ArgumentNullException` if `name` is null. |
| `SetPropertyValue` | `void SetPropertyValue(string name, object value)` | Sets a property value by name. Throws `ArgumentNullException` if `name` is null. |
| `AddProperty` (overload 1) | `PropertyDescriptor AddProperty(Type type, string name, object value, string displayName, string description, string category, bool hasDefaultValue, object defaultValue, bool readOnly)` | Adds a dynamically defined property. |
| `AddProperty` (overload 2) | `PropertyDescriptor AddProperty(Type type, string name, object value, string displayName, string description, string category, bool hasDefaultValue, object defaultValue, bool readOnly, Type uiTypeEditor)` | Adds a dynamically defined property with a UI type editor. Throws `ArgumentNullException` if `type` or `name` is null. |
| `AddProperty` (overload 3) | `void AddProperty(PropertyDescriptor property)` | Adds an existing `PropertyDescriptor`. Throws `ArgumentNullException` if `property` is null. |
| `RemoveProperty` | `void RemoveProperty(string name)` | Removes all properties matching the given name. Throws `ArgumentNullException` if `name` is null. |
| `FromComponent` | `DynamicTypeDescriptor FromComponent(object component)` | Creates a new `DynamicTypeDescriptor` bound to a specific component instance. Throws `ArgumentNullException` if `component` is null; throws `ArgumentException` if component type is not assignable to `_type`. |
| `OriginalProperties` | `PropertyDescriptorCollection OriginalProperties { get; }` | The original properties from `TypeDescriptor.GetProperties(type)`. |
| `Properties` | `PropertyDescriptorCollection Properties { get; }` | The current (potentially modified) property collection. |
| `Component` | `object Component { get; }` | The bound component instance. |
| `ClassName` | `string ClassName { get; set; }` | Optional override for class name. |
| `ComponentName` | `string ComponentName { get; set; }` | Optional override for component name. |
#### DynamicTypeDescriptor.DynamicProperty (Nested Sealed Class)
**Inherits:** `PropertyDescriptor`, **Implements:** `INotifyPropertyChanged`
| Member | Signature | Description |
|--------|-----------|-------------|
| `PropertyChanged` | `event PropertyChangedEventHandler PropertyChanged` | Event raised when the property value changes. |
| `Value` | `object Value { get; set; }` | The current value (used when no existing property descriptor). |
| `AttributesList` | `IList<Attribute> AttributesList { get; }` | Mutable list of attributes. |
| `Attributes` | `override AttributeCollection Attributes { get; }` | Returns attributes as a collection. |
| `SetBrowsable` | `void SetBrowsable(bool browsable)` | Overrides the `IsBrowsable` behavior. |
| `SetIsReadOnly` | `void SetIsReadOnly(bool readOnly)` | Overrides the `IsReadOnly` behavior. |
| `SetDisplayName` | `void SetDisplayName(string displayName)` | Overrides the `DisplayName`. |
| `SetDescription` | `void SetDescription(string description)` | Overrides the `Description`. |
| `SetCategory` | `void SetCategory(string category)` | Overrides the `Category`. |
| `SetEditor` | `void SetEditor(Type editorBaseType, object obj)` | Sets or removes an editor for a given editor base type. |
| `RemoveAttributesOfType<T>` | `void RemoveAttributesOfType<T>() where T : Attribute` | Removes all attributes of the specified type from the property. |
| Standard `PropertyDescriptor` overrides | `CanResetValue`, `GetValue`, `SetValue`, `ResetValue`, `ShouldSerializeValue`, `GetEditor`, etc. | Standard property descriptor behavior, delegating to existing property when available. |
---
## 3. Invariants
### BasePropertyChanged
- `SetProperty<T>` will **not** raise `PropertyChanged` if `storage` equals `value` (returns `false` early).
- `SetProperty<T>` will **always** raise `

View File

@@ -0,0 +1,88 @@
---
source_files:
- Common/DTS.CommonCore/Base/Interface/IBaseClass.cs
- Common/DTS.CommonCore/Base/Interface/IViewModel.cs
- Common/DTS.CommonCore/Base/Interface/IBaseView.cs
- Common/DTS.CommonCore/Base/Interface/IBaseWindow.cs
- Common/DTS.CommonCore/Base/Interface/IBaseModel.cs
- Common/DTS.CommonCore/Base/Interface/IBasePropertyChanged.cs
- Common/DTS.CommonCore/Base/Interface/IHeaderInfoProvider.cs
- Common/DTS.CommonCore/Base/Interface/IBaseWindowModel.cs
- Common/DTS.CommonCore/Base/Interface/IBaseViewModel.cs
generated_at: "2026-04-17T16:04:27.057929+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "c772b146b8c7aa51"
---
# Interface
### Purpose
This module defines the fundamental contracts for the MVVM (Model-View-ViewModel) architecture used within the `DTS.CommonCore` library. It establishes the base interfaces for property change notification, data models, views, and view models, ensuring a consistent approach to data binding and lifecycle management across the system.
### Public Interface
* **`interface IBasePropertyChanged : INotifyPropertyChanged`**
* Extends `INotifyPropertyChanged` to add a manual notification method.
* `void OnPropertyChanged(string propertyName)`: Raises the `PropertyChanged` event for the specified property name.
* **`interface IBaseClass : IBasePropertyChanged`**
* A marker interface for base classes that support property change notification. It defines no additional members.
* **`interface IBaseModel : IBasePropertyChanged`**
* Represents a data model with a persistent state tracking capability.
* `bool IsSaved { get; }`: Gets a value indicating whether the model is saved.
* **`interface IViewModel`**
* Defines a basic view model wrapper around a model object.
* `object Model { get; set; }`: Gets or sets the underlying data model object.
* **`interface IBaseView`**
* Defines a view element capable of data binding.
* `object DataContext { get; set; }`: Gets or sets the data context for the view.
* **`interface IBaseWindow`**
* Defines a window element capable of data binding.
* `object DataContext { get; set; }`: Gets or sets the data context for the window.
* **`interface IHeaderInfoProvider<T>`**
* Provides a mechanism for classes to expose header information for XAML binding.
* `T HeaderInfo { get; }`: Gets the header information.
* **`interface IBaseViewModel : IBasePropertyChanged`**
* Defines the lifecycle and state properties for a standard view model.
* `bool IsMenuIncluded { get; set; }`: Gets or sets whether a menu is included.
* `bool IsNavigationIncluded { get; set; }`: Gets or sets whether navigation is included.
* `bool IsBusy { get; set; }`: Gets or sets the busy state.
* `bool IsDirty { get; }`: Gets whether the view model has unsaved changes.
* `void Activated()`: Called when the view model is activated.
* `void Cleanup()`: Synchronously cleans up resources.
* `Task CleanupAsync()`: Asynchronously cleans up resources.
* `void Initialize()`: Initializes the view model.
* `void Initialize(object parameter)`: Initializes the view model with a parameter.
* `void Initialize(object parameter, object model)`: Initializes the view model with a parameter and a model.
* `Task InitializeAsync()`: Asynchronously initializes the view model.
* `Task InitializeAsync(object parameter)`: Asynchronously initializes the view model with a parameter.
* **`interface IBaseWindowModel : INotifyPropertyChanged`**
* Defines the lifecycle and state properties for a window-level model.
* `bool IsMenuIncluded { get; set; }`
* `bool IsNavigationIncluded { get; set; }`
* `bool IsBusy { get; set; }`
* `bool IsDirty { get; }`
* `void Activated()`
* `void Cleanup()`
* `Task CleanupAsync()`
* `void Initialize()`
* `void Initialize(object parameter)`
* `Task InitializeAsync()`
* `Task InitializeAsync(object parameter)`
### Invariants
* `IBaseView.DataContext` and `IBaseWindow.DataContext` must accept an object that is typically an implementation of `IBaseViewModel` or `IBaseWindowModel`.
* `IBaseViewModel.Initialize` overloads suggest that initialization logic must handle cases with zero, one, or two parameters.
* `IBaseWindowModel` inherits from `INotifyPropertyChanged` directly, whereas `IBaseViewModel` inherits from `IBasePropertyChanged`.
### Dependencies
* **Dependencies:** `System.ComponentModel`, `System.Threading.Tasks`.
* **Dep

View File

@@ -0,0 +1,76 @@
---
source_files:
- Common/DTS.CommonCore/Base/Model/BaseModel.cs
generated_at: "2026-04-17T16:40:06.536199+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "4cc2728963c0ba1e"
---
# Documentation: BaseModel.cs
## 1. Purpose
This module provides `BaseModel<TModel>`, an abstract generic base class designed to wrap domain model objects. It serves as a foundation for creating model wrapper classes that require property change notification capabilities and persistence state tracking. The class acts as a bridge between raw data models and UI/view-layer components in the DTS system.
## 2. Public Interface
### `BaseModel<TModel>` (Class)
**Signature:**
```csharp
public abstract class BaseModel<TModel> : BasePropertyChanged, IBaseModel
where TModel : class
```
**Description:** Abstract generic base class for model wrappers. Inherits from `BasePropertyChanged` and implements `IBaseModel`. The generic type parameter `TModel` is constrained to reference types only.
---
### `Model` (Property)
**Signature:**
```csharp
public TModel Model { get; set; }
```
**Description:** Gets or sets the wrapped model object. No validation or null-checking is performed in the setter.
---
### `BaseModel()` (Constructor)
**Signature:**
```csharp
public BaseModel()
```
**Description:** Public parameterless constructor. Creates a new instance with default property values.
---
### `IsSaved` (Property)
**Signature:**
```csharp
public bool IsSaved { get; private set; }
```
**Description:** Gets a boolean indicating whether the model has been saved. The setter is private.
## 3. Invariants
- **Generic Type Constraint:** `TModel` must be a reference type (`class` constraint).
- **Inheritance Chain:** All `BaseModel<TModel>` instances are also `BasePropertyChanged` instances and implement `IBaseModel`.
- **Constructor Accessibility:** Despite being abstract, the class exposes a public constructor.
## 4. Dependencies
### This module depends on:
- `BasePropertyChanged` — Base class providing property change notification (likely implements `INotifyPropertyChanged`).
- `IBaseModel` — Interface contract for model objects.
### Dependents:
- Cannot be determined from this source file alone. Any class that wraps a model object and needs property change notification would inherit from this base class.
## 5. Gotchas
- **Namespace Mismatch:** The file is located at `Common/DTS.CommonCore/Base/Model/BaseModel.cs` but the namespace is declared as `DTS.Common.Base`. The `// ReSharper disable CheckNamespace` directive suppresses the IDE warning for this mismatch.
- **Public Constructor in Abstract Class:** The class is abstract yet declares a public constructor. While legal

View File

@@ -0,0 +1,44 @@
---
source_files:
- Common/DTS.CommonCore/Base/View/BaseWindow.cs
- Common/DTS.CommonCore/Base/View/BaseView.cs
generated_at: "2026-04-17T16:07:35.691560+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "552d84b401685097"
---
# View
### Purpose
This module provides base classes for WPF view components within the DTS framework. It establishes a consistent pattern for views to expose dirty-state tracking and header information by delegating to their DataContext ViewModels. Both `BaseWindow` and `BaseView` serve as abstracted base types that bridge the gap between standard WPF controls (`Window`, `UserControl`) and the application's ViewModel contracts (`IBaseWindowModel`, `IBaseViewModel`, `IHeaderInfoProvider<string>`).
### Public Interface
**BaseWindow : Window, IBaseWindow**
- `bool IsDirty { get; }` — Returns `true` if the `DataContext` implements `IBaseWindowModel` and its `IsDirty` property is `true`. Returns `false` if `DataContext` is null or does not implement the interface.
- `string HeaderInfo { get; }` — Returns the `HeaderInfo` from `DataContext` if it implements `IHeaderInfoProvider<string>`. Returns `string.Empty` if `DataContext` is null or does not implement the interface.
**BaseView : UserControl, IBaseView**
- `bool IsDirty { get; }` — Returns `true` if the `DataContext` implements `IBaseViewModel` and its `IsDirty` property is `true`. Returns `false` if `DataContext` is null or does not implement the interface.
- `string HeaderInfo { get; }` — Returns the `HeaderInfo` from `DataContext` if it implements `IHeaderInfoProvider<string>`. Returns `string.Empty` if `DataContext` is null or does not implement the interface.
### Invariants
- `IsDirty` will never throw; it safely returns `false` when `DataContext` is null or incompatible.
- `HeaderInfo` will never throw; it safely returns `string.Empty` when `DataContext` is null or incompatible.
- Both properties are read-only getters with no setters.
### Dependencies
**Depends on:**
- `System.Windows` (Window class)
- `System.Windows.Controls` (UserControl class)
- `IBaseWindow`, `IBaseWindowModel`, `IBaseViewModel`, `IHeaderInfoProvider<string>` (interfaces not shown in source; assumed defined elsewhere in DTS.CommonCore or related assemblies)
**Depended on by:**
- Unclear from source alone; likely all Window and UserControl derivatives in the DTS application.
### Gotchas
- **Interface mismatch between BaseWindow and BaseView:** `BaseWindow.IsDirty` checks for `IBaseWindowModel`, while `BaseView.IsDirty` checks for `IBaseViewModel`. These are different interfaces. A ViewModel intended for use with both must implement both interfaces, or dirty state will report incorrectly in one context.
- The namespace is declared as `DTS.Common.Base` but the file path suggests `DTS.CommonCore`. This may indicate a historical namespace rename or intentional divergence.
---

View File

@@ -0,0 +1,45 @@
---
source_files:
- Common/DTS.CommonCore/Base/ViewModel/ViewModelBase.cs
- Common/DTS.CommonCore/Base/ViewModel/BaseViewModel.cs
generated_at: "2026-04-17T15:40:45.497045+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "72dbfa917d46895e"
---
# Documentation: DTS.Common.Base ViewModel Classes
## 1. Purpose
This module provides two abstract base classes for the Model-View-ViewModel (MVVM) pattern within the DTS application framework. `ViewModelBase<T>` offers a foundational implementation for ViewModels that need property change notification, error handling, and asynchronous model initialization while inheriting from WPF's `DependencyObject`. `BaseViewModel<TModel>` provides a more feature-rich base class with Prism framework integration, including command management, region navigation, event aggregation, and dependency injection support. Both classes establish a consistent contract for ViewModel lifecycle management across the codebase.
---
## 2. Public Interface
### ViewModelBase\<T\>
**Type:** `abstract class`
**Inheritance:** `DependencyObject`, `INotifyPropertyChanged`, `IViewModel`
#### Properties
| Name | Type | Access | Description |
|------|------|--------|-------------|
| `Model` | `object` | get/set | The Model object instance. Note: typed as `object` despite generic parameter `T`. |
| `IsBusy` | `bool` | get/protected set | Indicates whether an asynchronous process is currently executing. |
| `IsDirty` | `bool` | get/protected set | Indicates whether the Model has been changed. Virtual. |
#### Events
| Name | Type | Description |
|------|------|-------------|
| `ErrorOccurred` | `EventHandler<ErrorEventArgs>` | Raised when an error occurs during processing. Virtual. |
| `PropertyChanged` | `PropertyChangedEventHandler` | Raised when a property value changes. Virtual. |
#### Abstract Methods (must be implemented by derived classes)
| Signature | Description |
|-----------|-------------|
| `protected abstract Task<T> InitializeAsync()` | Async initialization that returns the model object. Result is intended to set

View File

@@ -0,0 +1,47 @@
---
source_files:
- Common/DTS.CommonCore/Behaviors/StringMetaDataAttr.cs
- Common/DTS.CommonCore/Behaviors/TrimTextBoxBehavior.cs
- Common/DTS.CommonCore/Behaviors/InteractivityTemplate.cs
- Common/DTS.CommonCore/Behaviors/TextBoxPasteBehavior.cs
- Common/DTS.CommonCore/Behaviors/MultiSelectionBehavior.cs
generated_at: "2026-04-17T15:35:45.848177+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "96d4dc839b72e47c"
---
# Documentation: DTS.Common.Behaviors Namespace
## 1. Purpose
This module provides a collection of WPF behaviors and utilities for the DTS CommonCore framework. It enables declarative UI interactions through attached properties and `Behavior<T>` implementations, including text trimming on focus loss, multi-selection synchronization for `ListBox` controls, custom paste command handling, and a mechanism for attaching behaviors/triggers via data templates. It also provides a reflection-based attribute system for storing string metadata on enum values and objects.
---
## 2. Public Interface
### StringMetaDataAttr
**Signature:** `public class StringMetaDataAttr : Attribute`
A custom attribute for storing string metadata on objects or enum members.
| Member | Signature | Description |
|--------|-----------|-------------|
| `MetaData` | `public string MetaData { get; }` | Read-only property returning the stored metadata string. |
| `GetStringMetaData` | `public static string GetStringMetaData(object o)` | Retrieves the `MetaData` value from a `StringMetaDataAttr` applied to the object's member (typically an enum value). Returns `null` if no attribute is found or if the object is null. |
**Constructor:** `internal StringMetaDataAttr(string attr)` — Internal constructor; attributes must be applied at compile time.
---
### TrimTextBoxBehavior
**Signature:** `public class TrimTextBoxBehavior : Behavior<TextBox>`
A behavior that trims whitespace from a `TextBox` when it loses focus and updates the binding source.
| Member | Signature | Description |
|--------|-----------|-------------|
| `OnAttached` | `protected override void OnAttached()` | Subscribes to `AssociatedObject

View File

@@ -0,0 +1,49 @@
---
source_files:
- Common/DTS.CommonCore/BusyIndicatorManager/xBusyIndicator.xaml.cs
- Common/DTS.CommonCore/BusyIndicatorManager/BusyIndicatorManager.cs
generated_at: "2026-04-17T16:36:20.045107+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "1f7158417293cad9"
---
# BusyIndicatorManager Module Documentation
## 1. Purpose
This module provides a thread-safe, singleton-based manager for coordinating busy indicator states across an application. It allows multiple callers to register unique busy states (identified by integer IDs) with associated messages, ensuring the UI reflects the appropriate busy state when one or more operations are in progress. The `xBusyIndicator` class serves as a WPF UserControl component, likely intended for visual representation of the busy state, though its implementation is minimal in the provided source.
---
## 2. Public Interface
### `BusyIndicatorManager` (class)
**Inherits from:** `NotificationObject` (Microsoft.Practices.Prism.ViewModel)
**Singleton Access:**
```csharp
public static BusyIndicatorManager Instance { get; }
```
Returns the singleton instance of `BusyIndicatorManager`, creating it lazily with thread synchronization via a lock on `SyncRoot`.
**Properties:**
```csharp
public bool IsBusy { get; private set; }
```
Indicates whether any busy operation is currently registered. Returns `true` when `busyParameters` dictionary contains one or more entries; `false` when empty.
```csharp
public string Message { get; private set; }
```
The current busy message to display. Updated to the most recently added or last remaining message in `busyParameters`.
**Methods:**
```csharp
public void ShowBusy(int id, string busyMessage)
```
Registers a busy state with the given `id` and `busyMessage`. If the ID already exists, the message is updated. Sets `IsBusy` to `true` and updates `Message` to `busyMessage`.
```csharp
public

View File

@@ -0,0 +1,288 @@
---
source_files:
- Common/DTS.CommonCore/Classes/StatusAndProgressBarEventArgs.cs
- Common/DTS.CommonCore/Classes/Singleton.cs
- Common/DTS.CommonCore/Classes/ImportData.cs
- Common/DTS.CommonCore/Classes/RegionNames.cs
- Common/DTS.CommonCore/Classes/ServiceCall.cs
- Common/DTS.CommonCore/Classes/TagAwareBase.cs
- Common/DTS.CommonCore/Classes/Utility.cs
- Common/DTS.CommonCore/Classes/Tags.cs
generated_at: "2026-04-17T15:33:44.713375+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "27a98b73bf260db5"
---
# DTS.Common.Classes Module Documentation
## Purpose
This module provides core infrastructure classes for the DTS application, including a thread-safe singleton pattern implementation, a serialized service call queue, region name constants for UI navigation, tag management with database persistence, data transfer objects for import operations, and utility helpers for safe data reader access and error handling. These classes form foundational building blocks used across the application for state management, UI coordination, and data operations.
---
## Public Interface
### StatusAndProgressBarEventArgs
**Namespace:** `DTS.Common.Classes`
A data transfer object for passing status and progress information in event arguments.
| Property | Type | Description |
|----------|------|-------------|
| `StatusColor` | `System.Windows.Media.Color` | The color to display for the status text |
| `StatusText` | `string` | The text to display in the status area |
| `ProgressValue` | `double` | The current progress bar value |
| `ProgressBarVisibility` | `System.Windows.Visibility` | Controls visibility of the progress bar |
| `Requester` | `IBaseViewModel` | Reference to the view model requesting the status update |
| `ErrorText` | `string` | Error message text, if any |
---
### Singleton\<T\>
**Namespace:** `DTS.Common.Classes`
A generic base class implementing the singleton pattern. Derived classes must have a public parameterless constructor.
```csharp
public class Singleton<T> where T : new()
```
| Member | Signature | Description |
|--------|-----------|-------------|
| `Instance` | `public static T Instance { get; }` | Returns the singleton instance of type T. Throws `InvalidOperationException` if creation previously failed or if accessed during failed initialization. |
**Constructor Behavior:** The protected constructor throws `InvalidOperationException` if `Instance` is not null, preventing manual instantiation via `new` when an instance already exists.
---
### ServiceCall
**Namespace:** `DTS.Common.Classes`
Represents a unit of work to be executed by the service framework.
| Member | Signature | Description |
|--------|-----------|-------------|
| `Started` | `public bool Started { get; set; }` | Indicates whether the call has begun execution |
| `WorkAction` | `public Action WorkAction { get; set; }` | The delegate containing work to execute |
| `Name` | `public string Name { get; set; }` | Identifier for the service call |
| `MarkDone` | `public void MarkDone()` | Notifies the queue that this call is complete |
| Constructor | `public ServiceCall(string name)` | Creates a new service call with the given name |
---
### ServiceQueue
**Namespace:** `DTS.Common.Classes`
Manages serialized execution of service calls via an internal queue.
| Member | Signature | Description |
|--------|-----------|-------------|
| `Enqueue` | `public static void Enqueue(ServiceCall call)` | Adds a service call to the queue. Starts execution immediately if queue is empty. |
| `MarkFinished` | `public static void MarkFinished(ServiceCall call)` | Removes a completed call from the queue and starts the next item if available. |
---
### RegionNames
**Namespace:** `DTS.Common.Classes`
Static class containing string constants for UI region identifiers used in navigation.
**Constants:**
- `FrontRegion`, `MainRegion`
- `ViewerEuRegion`, `ViewerMvRegion`, `ViewerEdcRegion`, `ViewerTestsRegion`
- `ViewerGraphRegion`, `ViewerGraphsRegion`, `ViewerGraphMainRegion`, `ViewerGraphListRegion`, `ViewerGraphChannelRegion`
- `ViewerTestModificationRegion`, `ViewerLegendRegion`, `ViewerSearchRegion`, `ViewerSettingsRegion`
- `ViewerDiagRegion`, `ViewerDisplayRegion`, `ViewerChartOptionsRegion`, `ViewerStatsRegion`, `ViewerCursorRegion`
- `ViewerFiterRegion` (note: typo preserved from source)
- `MenuRegion`, `NavigationRegion`, `BottomRegion`, `RightRegion`, `TopRegion`
- `VerticalTabRegion`, `HorizontalTabRegion`, `RibbonRegion`
- `PropertyDisplayRegion`, `PropertyModifyRegion`, `PropertyAddRegion`
- `PSDDataSelectRegion`, `PSDGraphRegion`
- `ReportChartOptionsRegion`, `ReportResultsRegion`
---
### TagAwareBase
**Namespace:** `DTS.Common.Classes`
Abstract base class providing tag management functionality for entities that support tagging.
```csharp
public abstract class TagAwareBase : Base.BasePropertyChanged
```
**Nested Enum:**
```csharp
public enum TagTypes
{
User,
Group,
Template,
TestSetup,
Sensors,
SensorModels
}
```
| Member | Signature | Description |
|--------|-----------|-------------|
| `TagType` | `public abstract TagTypes TagType { get; }` | Must be implemented to specify the entity type |
| `TagsBlobBytes` | `public byte[] TagsBlobBytes { get; set; }` | Gets/sets tags as a byte array (int array serialized) |
| `TagIDs` | `public int[] TagIDs { get; set; }` | Array of tag IDs associated with this entity |
| `SetTagsFromCommaSeparatedString` | `public void SetTagsFromCommaSeparatedString(string tagText, Tags.GetSqlCommandDelegate getSqlCommand)` | Parses comma-separated tags and assigns them |
| `SetTags` | `public virtual void SetTags(string[] tagsText, Tags.GetSqlCommandDelegate getSqlCommand)` | Assigns tags from string array |
| `GetTagsAsCommaSeparatedString` | `public string GetTagsAsCommaSeparatedString(Tags.GetSqlCommandDelegate getSqlCommand)` | Returns tags as comma-separated string |
| `GetTagsArray` | `public virtual string[] GetTagsArray(Tags.GetSqlCommandDelegate getSqlCommand)` | Returns tags as string array |
| `GetTagIDs` | `public virtual int[] GetTagIDs()` | Returns the TagIDs array |
| `RemoveTags` | `public virtual void RemoveTags(string[] tagsText)` | Stub method (no implementation in source) |
| `TagCompatible` | `public bool TagCompatible(string tags, Tags.GetSqlCommandDelegate getSqlCommand)` | Checks if any comma-separated tag matches this entity's tags |
| `TagCompatible` | `public virtual bool TagCompatible(int[] tags)` | Checks if any tag ID in the array intersects with this entity's tags |
| `HasIntersectingTag` | `public virtual bool HasIntersectingTag(int[] tags)` | Returns true if any tag ID intersects |
| `InsertTagsFromCommaSeparatedString` | `public void InsertTagsFromCommaSeparatedString(int id, TagTypes tagType, string tags, Tags.GetSqlCommandDelegate getSqlCommand)` | Sets tags and commits to database |
| `Commit` | `public void Commit(int id, TagTypes tagType, Tags.GetSqlCommandDelegate getSqlCommand)` | Persists tag assignments to database via stored procedures |
| `GetTagIdList` | `public List<int> GetTagIdList(int objectId, TagTypes tagType, Tags.GetSqlCommandDelegate getSqlCommand)` | Retrieves tag IDs for an object from database |
---
### Tags
**Namespace:** `DTS.Common.Classes`
Manages tag entities with in-memory caching and database persistence.
**Nested Class: Tag**
```csharp
public class Tag : ICloneable
{
public const int INVALID_ID = -1;
public int ID { get; set; }
public string Text { get; set; }
public bool IsObsolete { get; set; }
}
```
| Member | Signature | Description |
|--------|-----------|-------------|
| `GetTagsInstance` | `public static Tags GetTagsInstance(GetSqlCommandDelegate getSqlCommand)` | Returns the singleton instance, creating it if necessary |
| `AddTag` | `public static bool AddTag(string tagText, GetSqlCommandDelegate getSqlCommand)` | Adds a tag if not already cached; returns false if already exists |
| `MigrateTag` | `public static bool MigrateTag(string tagText, GetSqlCommandDelegate getSqlCommand)` | Used during database migration to add/update tags |
| `AddRange` | `public static bool[] AddRange(string[] tagText, GetSqlCommandDelegate getSqlCommand)` | Adds multiple tags; returns array of success flags |
| `GetIDFromTagText` | `public static int GetIDFromTagText(string tagText, GetSqlCommandDelegate getSqlCommand)` | Gets tag ID from database by text |
| `GetIDsFromTagText` | `public static int[] GetIDsFromTagText(string[] tagText, GetSqlCommandDelegate getSqlCommand)` | Converts array of tag texts to IDs |
| `GetTagTextFromID` | `public static string GetTagTextFromID(int tagID, GetSqlCommandDelegate getSqlCommand)` | Gets tag text from cached lookup by ID |
| `GetTagTextFromIDs` | `public static string[] GetTagTextFromIDs(int[] tagId, GetSqlCommandDelegate getSqlCommand)` | Converts array of tag IDs to texts |
| `ContainsTag` | `public bool ContainsTag(string text)` | Checks if tag text exists in cache |
| `UpdateList` | `public void UpdateList(GetSqlCommandDelegate getSqlCommand)` | Refreshes the in-memory tag cache from database |
**Delegate:**
```csharp
public delegate SqlCommand GetSqlCommandDelegate(bool bNewConnection);
```
---
### Utility
**Namespace:** `DTS.Common.Classes`
Static utility class providing helper methods for data access and error handling.
| Member | Signature | Description |
|--------|-----------|-------------|
| `GetBytesFromStringArray` | `public static byte[] GetBytesFromStringArray(string[] array, string separator)` | Converts string array to UTF8 bytes with separator |
| `GetAllErrorMessages` | `public static string GetAllErrorMessages(Exception ex)` | Concatenates exception message with all inner exception messages |
| `PingNetwork` | `public static bool PingNetwork(string hostNameOrAddress)` | Tests network connectivity with 4-second timeout |
| `GetUShort` | `public static ushort GetUInt(IDataReader reader, string column, ushort defaultValue = 0)` | Safe ushort extraction from IDataReader |
| `GetUInt` | `public static uint GetUInt(IDataReader reader, string column, uint defaultValue = 0)` | Safe uint extraction from IDataReader |
| `GetString` | `public static string GetString(IDataReader reader, string column, string defaultValue = "")` | Safe string extraction from IDataReader |
| `GetStringArray` | `public static string[] GetStringArray(IDataReader reader, string column, string[] defaultValue, string separator)` | Extracts string array from byte column |
| `GetInt` | `public static int GetInt(IDataReader reader, string column, int defaultValue = 0)` | Safe int extraction from IDataReader |
| `GetDouble` | `public static double GetDouble(IDataReader reader, string column, double defaultValue = 0D)` | Safe double extraction from IDataReader |
| `GetShort` | `public static short GetShort(IDataReader reader, string column, short defaultValue = 0)` | Safe short extraction from IDataReader |
| `GetNullableDateTime` | `public static DateTime? GetNullableDateTime(IDataReader reader, string column)` | Returns nullable DateTime from IDataReader |
| `GetUlong` | `public static ulong GetUlong(IDataReader reader, string column, ulong defaultValue = 0)` | Safe ulong extraction from IDataReader |
| `GetNullableInt` | `public static int? GetNullableInt(IDataReader reader, string column)` | Returns nullable int from IDataReader |
| `GetByteArray` | `public static byte[] GetByteArray(IDataReader reader, string column)` | Returns byte array or empty array if null/DBNull |
| `GetBool` | `public static bool GetBool(IDataReader reader, string column, bool defaultValue = false)` | Safe bool extraction from IDataReader |
| `GetDateTime` | `public static DateTime GetDateTime(IDataReader reader, string column, DateTime defaultValue)` | Safe DateTime extraction from IDataReader |
| `GetLong` | `public static long GetLong(IDataReader reader, string column, long defaultValue = 0)` | Safe long extraction from IDataReader |
---
### SensorImportData
**Namespace:** `DTS.Common.Classes`
Data transfer object for sensor import operations.
| Property | Type |
|----------|------|
| `GroupNameSensorListLookup` | `Dictionary<string, List<string>>` |
| `SensorGroupNameLookup` | `Dictionary<string, string>` |
| `SensorGroupTypeLookup` | `Dictionary<string, string>` |
| `GroupNameTestObjectLookup` | `Dictionary<string, string>` |
| `Errors` | `List<string>` (initialized to empty list) |
| `SensorISOCode` | `Dictionary<string, string>` |
| `SensorISOChannelName` | `Dictionary<string, string>` |
| `SensorUserCode` | `Dictionary<string, string>` |
| `SensorUserChannelName` | `Dictionary<string, string>` |
| `SensorDASSerialNumber` | `Dictionary<string, string>` |
| `SensorChannelIndex` | `Dictionary<string, int>` |
---
### TestSetupImportData
**Namespace:** `DTS.Common.Classes`
Data transfer object for test setup import operations.
| Property | Type | Default |
|----------|------|---------|
| `Name` | `string` | - |
| `Description` | `string` | - |
| `SamplesPerSecond` | `double` | - |
| `PosttriggerSeconds` | `double` | - |
| `PretriggerSeconds` | `double` | - |
| `RecordingMode` | `RecordingModes` | - |
| `CalibrationBehavior` | `CalibrationBehaviors` | - |
| `Version` | `int` | - |
| `TestChannelOrders` | `List<string>` | - |
| `Tags` | `List<string>` | - |
| `ClockMasterInput` | `InputClockSource` | `InputClockSource.None` |
| `ClockMasterOutput` | `OutputClockSource` | `OutputClockSource.None` |
| `ManageClocksOutsideOfDataPROMaster` | `bool` | `false` |
| `ManageClocksOutsideOfDataPROSlave` | `bool` | `false` |
| `ClockSlaveInput` | `OutputClockSource` | `OutputClockSource.None` |
| `ClockSlaveOutput` | `OutputClockSource` | `OutputClockSource.None` |
| `SampleRateForDAS` | `Dictionary<string, int>` | empty dictionary (readonly) |
| `DomainIdForDAS` | `Dictionary<string, uint>` | empty dictionary (readonly) |
| `IsClockMaster` | `Dictionary<string, bool>` | empty dictionary (readonly) |
---
### ImportPageType
**Namespace:** `DTS.Common.Classes`
Enum defining import page types.
| Value |
|-------|
| `ImportSensor` |
| `ImportTestSetup` |
---
## Invariants
1. **Singleton\<T\>**: Only one instance of type T can exist. The protected constructor enforces this by throwing `InvalidOperationException` if `Instance` is already non-null when the constructor is called.
2. **ServiceQueue**: Service calls execute one at a time in FIFO order. A new call does not start until the previous call invokes `MarkDone()`.
3. **ServiceQueue**: The `Started` flag prevents the same `ServiceCall` from being launched multiple times by concurrent `StartWork()` invocations.
4. **Tags**: The `_tagsLookup` dictionary is cached in memory and only refreshed via `UpdateList()` or when new tags are added via `Commit()`.
5. **TagAwareBase.TagIDs**: Never null; always initialized to an empty array if null is assigned.
6. **Tags.Tag.INVALID_ID**: Constant value of `-1` represents an invalid/unassigned tag ID.
7. **Utility IDataReader methods**: All methods handle `DBNull.Value` and

View File

@@ -0,0 +1,21 @@
---
source_files:
- Common/DTS.CommonCore/Classes/ChannelCodes/TextPastedArgs.cs
- Common/DTS.CommonCore/Classes/ChannelCodes/ChannelCode.cs
generated_at: "2026-04-17T16:24:31.004584+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "c71458d3400b2fd5"
---
# ChannelCodes
### Purpose
This module provides the core domain model and event handling infrastructure for channel codes used throughout the system. It includes the `ChannelCode` entity class that represents channel code records with support for ISO and User code types, a `TextPastedArgs` event argument class for paste operations, a `PasteCommandClass` for handling clipboard paste logic with multi-field parsing, and a delegate type for ISO code coercion.
### Public Interface
**TextPastedArgs**
- `class TextPastedArgs : ITextPastedEventArgs`
- Constructor: `TextPastedArgs(string text, IChannelCode channelCode, string id, object tag)`
- `string Text { get; }`

View File

@@ -0,0 +1,13 @@
---
source_files:
- Common/DTS.CommonCore/Classes/Connection/NotConnectedException.cs
generated_at: "2026-04-17T16:09:20.276633+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "0dc15237410ea215"
---
# Connection
### 1. Purpose
This module provides a specific exception type for handling connection

View File

@@ -0,0 +1,148 @@
---
source_files:
- Common/DTS.CommonCore/Classes/DASFactory/TemperatureConfig.cs
- Common/DTS.CommonCore/Classes/DASFactory/TMSNConfig.cs
- Common/DTS.CommonCore/Classes/DASFactory/ATDStagger.cs
generated_at: "2026-04-17T15:39:37.663601+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "e9a2b8493c76b444"
---
# DASFactory Classes Documentation
## 1. Purpose
This module provides configuration and utility classes for the DAS (Data Acquisition System) Factory subsystem. `TemperatureConfig` manages temperature and humidity logging channel settings with serialization to/from ushort arrays for firmware communication. `TMNSConfig` encapsulates TMNS (Telemetry) configuration as a fixed-length uint array with named property accessors and profile type detection. `ATDStagger` is a commented-out class that was designed to sequence device communications to prevent processing delays.
---
## 2. Public Interface
### TemperatureConfig
**Properties:**
- `ushort LogEnable { get; set; }` - Enable/disable logging flag
- `ushort LogIntervalSec { get; set; }` - Logging interval in seconds
- `ushort Channels { get; set; }` - Bitfield representing enabled channels (backed by internal `BitArray`)
- `bool MCUTemp { get; set; }` - On-board temperature channel enable
- `bool OnBoardHumidity { get; set; }` - On-board humidity channel enable
- `bool EnvironmentalCh1 { get; set; }` - Environmental channel 1 enable
- `bool EnvironmentalCh2 { get; set; }` - Environmental channel 2 enable
- `bool EnvironmentalCh3 { get; set; }` - Environmental channel 3 enable
- `bool EnvironmentalCh4 { get; set; }` - Environmental channel 4 enable
- `const ushort Reserved = 0` - Reserved field constant
**Methods:**
- `ushort[] ToUShortArray()` - Returns a 4-element array: `[LogEnable, LogIntervalSec, Channels, Reserved]`
- `TemperatureConfig()` - Default constructor
- `TemperatureConfig(ushort[] ushortArray)` - Constructs from array; silently ignores null and handles short arrays by defaulting to 0
- `int[] GetChannelsArray()` - Returns indices of all enabled channels
- `S6DBDiagnosticChannelList[] GetMeasurementChannels()` - Maps enabled channels to diagnostic channel list values
- `TempLogChannelBits GetChannelBitForDiagChannel(S6DBDiagnosticChannelList ch)` - Returns the bit mapping for a diagnostic channel; throws `NullReferenceException` if not found
---
### TMNSConfig
**Properties (all backed by internal uint array):**
- `uint TMNS_PCMSubFrameId { get; set; }`
- `uint TMNS_MsgId { get; set; }`
- `uint TMNS_PCMMinorPerMajor { get; set; }`
- `uint TMNS_TMATSPortNumber { get; set; }`
- `uint IENAUDP_PortNumber { get; set; }`
- `uint TMNS5 { get; set; }` - Reserved field 5
- `uint TMNS6 { get; set; }` - Reserved field 6
- `uint TMNS7 { get; set; }` - Reserved field 7
**Nested Enum:**
- `enum Fields` - Values: `TMNS_PCMSubFrameID, TMNS_MsgId, TMNS_PCMMinorPerMajor, TMNS_TMATSPortNumber, IENAUDP_PortNumber, TMNS5, TMNS6, TMNS7`
**Constructors:**
- `TMNSConfig()` - Initializes with zero-filled array
- `TMNSConfig(uint[] parameters)` - Copies values from input array (truncates if longer, fills remaining with zeros if shorter)
- `TMNSConfig(string parameters)` - Parses comma-separated values; strips parentheses; silently skips unparseable tokens
**Methods:**
- `void SetValue(Fields field, uint value)` - Sets value at field index
- `uint GetValue(Fields field)` - Gets value at field index
- `uint[] ToUintArray()` - Returns a copy of the internal array
- `string ToCSVString()` - Returns format `(value0,value1,...,value7)`
- `static bool IsCh10(UDPStreamProfile profile)` - Returns true for CH10 streaming profiles
- `static bool IsIENA(UDPStreamProfile profile)` - Returns true for IENA profile
- `static bool IsTMNS(UDPStreamProfile profile)` - Returns true for TMNS profiles
- `static bool IsUART(UDPStreamProfile profile)` - Returns true for UART profile
---
### ATDStagger
**Status: Entire class is commented out.** No public interface is active.
---
## 3. Invariants
### TemperatureConfig
- `Channels` property always returns a 2-byte value derived from a 16-bit `BitArray`
- `ToUShortArray()` always returns exactly 4 elements
- The `Reserved` constant is always `0` and is included as the 4th element in serialization
- Channel bit indices are defined by `TempLogChannelBits` enum (external dependency)
- `GetChannelBitForDiagChannel` will always throw for unmapped `S6DBDiagnosticChannelList` values
### TMNSConfig
- Internal `_values` array length is always exactly 8 elements (determined by `Fields` enum cardinality)
- Array indices correspond directly to `Fields` enum integer values
- `ToUintArray()` always returns a copy, not the internal array reference
- `ToCSVString()` always returns parenthesized output format
- String constructor silently ignores malformed tokens (no exceptions thrown)
### ATDStagger
- N/A (class is commented out)
---
## 4. Dependencies
### TemperatureConfig
**Depends on:**
- `DTS.Common.Enums.DASFactory.TempLogChannelBits` - Enum defining channel bit positions
- `DTS.Common.Enums.DASFactory.DFConstantsAndEnums.S6DBDiagnosticChannelList` - Enum for diagnostic channels
- `System.Collections.BitArray`
- `System`
**Depended on by:** Not determinable from source alone
### TMNSConfig
**Depends on:**
- `DTS.Common.Enums.UDPStreamProfile` - Enum for streaming profile types
- `System`
- `System.Linq`
- `System.Text`
**Depended on by:** Not determinable from source alone
### ATDStagger
**Depends on (if uncommented):**
- `DTS.Common.Interface.DASFactory.IDASCommunication`
- `DTS.Common.Interface.DASFactory.ICommunication`
- `DTS.Common.Utilities.Logging.APILogger`
- `System.Data.IDbCommand`
- `System.Data.CommandType`
---
## 5. Gotchas
### TemperatureConfig
- **BitArray endianness:** The `Channels` getter uses `BitConverter.ToUInt16` after `BitArray.CopyTo`. The bit-to-byte mapping depends on `BitArray`'s internal ordering, which may not match intuitive expectations.
- **Constructor silently handles null:** `TemperatureConfig(ushort[] ushortArray)` returns early if null is passed, leaving `LogEnable`, `LogIntervalSec`, and `Channels` at their default values (0).
- **GetChannelBitForDiagChannel throws NullReferenceException:** Despite the name, this throws `NullReferenceException` (not `KeyNotFoundException` or `ArgumentException`) when the key is not found. The exception message is `"Not found: {ch}"`.
### TMNSConfig
- **String constructor is permissive:** It strips all `(` and `)` characters anywhere in the string, not just at boundaries. Malformed tokens that fail `uint.TryParse` are silently skipped.
- **Array truncation in constructor:** If the input array is longer than 8 elements, excess elements are ignored without warning.
- **No validation on property setters:** Any `uint` value is accepted; range validation is not performed.
### ATDStagger
- **Entire class is commented out:** This class is non-functional. The comment references ticket "16237" and describes sequencing/staggering for services, but the implementation is entirely disabled. Reason for commenting out is not documented in source.

View File

@@ -0,0 +1,64 @@
---
source_files:
- Common/DTS.CommonCore/Classes/DTS.Viewer/Commands/RelayCommand.cs
generated_at: "2026-04-17T16:38:38.055405+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "9f35643384379d28"
---
# Documentation: RelayCommand
## 1. Purpose
`RelayCommand` is an implementation of `System.Windows.Input.ICommand` that delegates execution logic to callbacks provided at construction time. It enables MVVM (Model-View-ViewModel) data binding in WPF applications by allowing view models to expose commands that can be bound to UI elements (buttons, menu items, etc.) without requiring the view model to implement full command classes for each action. This is a standard pattern for decoupling UI from business logic.
---
## 2. Public Interface
### Constructors
| Signature | Description |
|-----------|-------------|
| `RelayCommand(Action<object> execute)` | Creates a command that always reports as executable. Internally delegates to the two-parameter constructor with `canExecute` set to `null`. |
| `RelayCommand(Action<object> execute, Predicate<object> canExecute)` | Creates a command with both execute and canExecute logic. Throws `ArgumentNullException` if `execute` is `null`. The `canExecute` parameter may be `null`, in which case `CanExecute` will always return `true`. |
### Methods
| Signature | Description |
|-----------|-------------|
| `bool CanExecute(object parameter)` | Returns the result of invoking the `_canExecute` predicate with the provided `parameter`. If `_canExecute` is `null`, returns `true`. |
| `void Execute(object parameter)` | Invokes the `_execute` action delegate with the provided `parameter`. |
### Events
| Event | Description |
|-------|-------------|
| `EventHandler CanExecuteChanged` | Forwards subscriptions to `CommandManager.RequerySuggested`. Adding/removing handlers directly adds/removes them from the WPF `CommandManager`. |
---
## 3. Invariants
- **`_execute` is never null after construction.** The constructor enforces this by throwing `ArgumentNullException` if a null value is passed.
- **`_canExecute` may be null.** When null, `CanExecute` must return `true` for all parameters.
- **`CanExecuteChanged` is always routed through `CommandManager.RequerySuggested`.** There is no manual invocation mechanism for this event within the class itself.
- **The command does not retain or manage the parameter.** The `parameter` argument flows through without validation or storage.
---
## 4. Dependencies
### This module depends on:
- `System` — Provides `Action<T>`, `Predicate<T>`, `ArgumentNullException`, and `EventHandler`.
- `System.Windows.Input` — Provides `ICommand` interface and `CommandManager` static class.
### What depends on this module:
- **Not determinable from source alone.** As a utility class, it is expected to be consumed by ViewModels and other UI-related components throughout the codebase, but specific consumers are not visible in this file.
---
## 5. Gotchas
1. **No manual `RaiseCanExecuteChanged` method.** Unlike some `RelayCommand` implementations, this class provides no way to manually raise `CanExecuteChanged`. Consumers are entirely dependent on `CommandManager

View File

@@ -0,0 +1,61 @@
---
source_files:
- Common/DTS.CommonCore/Classes/DTS.Viewer/Reports/ChannelGRMSSummary.cs
generated_at: "2026-04-17T16:38:38.176911+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "022bbb862d4376ac"
---
# Documentation: ChannelGRMSSummary
## 1. Purpose
`ChannelGRMSSummary` is a data model class representing a summary report entry for a single channel's GRMS (likely "G RMS" - Root Mean Square acceleration measured in G-forces) value. It implements `IChannelGRMSSummary` and supports property change notification via the `INotifyPropertyChanged` pattern, enabling data binding scenarios in viewer/reporting contexts.
## 2. Public Interface
### Class: `ChannelGRMSSummary`
**Namespace:** `DTS.Common.Classes.Viewer.Reports`
**Implements:** `IChannelGRMSSummary`
#### Properties
| Name | Type | Access | Description |
|------|------|--------|-------------|
| `ChannelName` | `string` | get/set | Name identifier for the channel being summarized. |
| `SampleRate` | `int` | get/set | Sample rate value for the channel (units unspecified in source). |
| `GRMS` | `double` | get/set | GRMS (G-force Root Mean Square) value for the channel. |
#### Events
| Name | Type | Description |
|------|------|-------------|
| `PropertyChanged` | `PropertyChangedEventHandler` | Standard property change notification event. |
#### Methods
| Signature | Description |
|-----------|-------------|
| `void OnPropertyChanged(string propertyName)` | Invokes the `PropertyChanged` event with the specified property name, if any handlers are attached. |
## 3. Invariants
- The class uses auto-implemented properties with no validation logic; `ChannelName` may be `null`, and `SampleRate`/`GRMS` will default to `0` if not explicitly set.
- The `PropertyChanged` event will only fire when `OnPropertyChanged` is explicitly called; property setters do not automatically trigger notification.
- The relationship between `SampleRate` and `GRMS` (e.g., whether GRMS is calculated from samples at that rate) is not enforced by this class.
## 4. Dependencies
### This module depends on:
- `DTS.Common.Interface` — provides `IChannelGRMSSummary` interface
- `System.ComponentModel` — provides `PropertyChangedEventHandler` and `PropertyChangedEventArgs`
### What depends on this module:
- **Unknown from source alone.** Consumers of `IChannelGRMSSummary` or this concrete implementation are not visible in this file.
## 5. Gotchas
- **Manual notification required:** The property setters (`ChannelName`, `SampleRate`, `GRMS`) do not automatically call `OnPropertyChanged`. Callers must manually invoke `OnPropertyChanged` after setting properties if UI binding notification is required. This is a common source of bugs in MVVM scenarios.
- **Interface inheritance unclear:** Whether `IChannelGRMSSummary` inherits from `INotifyPropertyChanged` cannot be determined from this source alone. If it does not, consumers expecting standard `INotifyPropertyChanged` behavior may need to cast or check for the interface explicitly.
- **No constructor defined:** The class relies on the default parameterless constructor

View File

@@ -0,0 +1,273 @@
---
source_files:
- Common/DTS.CommonCore/Classes/DTS.Viewer/TestMetadata/TestMetadata.cs
- Common/DTS.CommonCore/Classes/DTS.Viewer/TestMetadata/TestGraphs.cs
- Common/DTS.CommonCore/Classes/DTS.Viewer/TestMetadata/TestSetupMetadata.cs
- Common/DTS.CommonCore/Classes/DTS.Viewer/TestMetadata/TestRunMetadata.cs
- Common/DTS.CommonCore/Classes/DTS.Viewer/TestMetadata/TestSummary.cs
- Common/DTS.CommonCore/Classes/DTS.Viewer/TestMetadata/TestModule.cs
- Common/DTS.CommonCore/Classes/DTS.Viewer/TestMetadata/TestChannel.cs
- Common/DTS.CommonCore/Classes/DTS.Viewer/TestMetadata/TestMetadataList.cs
generated_at: "2026-04-17T15:34:59.192943+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "edb878a345b676b6"
---
# Test Metadata Module Documentation
## 1. Purpose
This module provides the data model and parsing infrastructure for test metadata in the DTS (Data Test System) application. It defines POCO classes representing test runs, setups, modules, channels, and graphs, along with XML parsing logic to hydrate these objects from `.dts` files. The module serves as the bridge between persisted test data and the application's runtime representation, supporting both raw data channels and calculated channels with full calibration and statistical metadata.
---
## 2. Public Interface
### TestMetadata
Implements `ITestMetadata`. Root container for test information.
| Property | Type | Description |
|----------|------|-------------|
| `TestRun` | `ITestRunMetadata` | Metadata about the test run execution |
| `TestSetup` | `ITestSetupMetadata` | Metadata about the test setup configuration |
### TestGraphs
Implements `ITestGraphs`. Represents a graph configuration within a test setup.
| Property | Type | Description |
|----------|------|-------------|
| `Name` | `string` | Graph name |
| `HardwareChannelName` | `string` | Associated hardware channel name |
| `ChannelIds` | `List<string>` | List of channel IDs belonging to this graph |
| `Channels` | `List<ITestChannel>` | Resolved channel objects |
### TestSetupMetadata
Implements `ITestSetupMetadata`. Contains test setup configuration.
| Property | Type | Description |
|----------|------|-------------|
| `SetupName` | `string` | Name of the test setup |
| `TimeStamp` | `DateTime` | Timestamp of the setup |
| `TestGraphs` | `List<ITestGraphs>` | Graph configurations |
| `CalibrationBehavior` | `CalibrationBehaviors` | Calibration mode enum value |
### TestRunMetadata
Implements `ITestRunMetadata`. Contains test run execution details. Implements `INotifyPropertyChanged`.
| Property | Type | Description |
|----------|------|-------------|
| `Name` | `string` | Test name (ID from DTS file) |
| `Id` | `string` | File name without extension |
| `Description` | `string` | Test description |
| `InlineSerializedData` | `bool` | Whether data is inline serialized |
| `TestGuid` | `string` | Unique test identifier |
| `FaultFlags` | `int` | Fault flag bitmask |
| `Software` | `string` | Software name |
| `SoftwareVersion` | `string` | Software version |
| `DataType` | `string` | Data type identifier |
| `FileDate` | `DateTime` | File creation date |
| `FilePath` | `string` | Path to the test file |
| `Modules` | `List<ITestModule>` | List of test modules |
| `Channels` | `List<ITestChannel>` | All channels across modules |
| `CalculatedChannels` | `List<ITestChannel>` | Calculated/virtual channels |
| `IsSelected` | `bool` | Selection state |
**Events:**
- `event PropertyChangedEventHandler PropertyChanged`
**Methods:**
- `void OnPropertyChanged([CallerMemberName] string propertyName = null)` - Protected virtual
### TestSummary
Implements `ITestSummary`. Aggregated view of a test for UI display. Implements `INotifyPropertyChanged`.
| Property | Type | Description |
|----------|------|-------------|
| `ROI_SUFFIX` | `const string` | Constant value `@"_ROI Period"` |
| `Id` | `string` | Composite ID (TestRun.Id + event number) |
| `SetupName` | `string` | Test setup name |
| `Description` | `string` | Test description |
| `ChannelCount` | `int` | Number of channels |
| `FileDate` | `DateTime` | File date |
| `TimeStamp` | `DateTime` | Test timestamp |
| `DataType` | `string` | Data type |
| `IsSelected` | `bool` | Selection state with side effects |
| `Graphs` | `List<ITestGraphs>` | Graph configurations |
| `Channels` | `List<ITestChannel>` | Channel list |
| `CalculatedChannels` | `List<ITestChannel>` | Calculated channels |
| `Parent` | `IBaseViewModel` | Parent view model |
| `CalibrationBehavior` | `CalibrationBehaviors` | Calibration mode (defaults to `NonLinearIfAvailable`) |
| `TestMetadata` | `ITestMetadata` | Full metadata reference |
| `IsSelectedCommand` | `DelegateCommand` | Command for selection changes |
**Methods:**
- `void SelectionChanged()` - Updates parent's `SelectedTestSummaryList` and publishes selection event
- `void OnPropertyChanged(string propertyName)`
**Events:**
- `event PropertyChangedEventHandler PropertyChanged`
### TestModule
Implements `ITestModule`. Hardware module metadata. Implements `INotifyPropertyChanged`.
| Property | Type | Description |
|----------|------|-------------|
| `SerialNumber` | `string` | Module serial number |
| `BaseSerialNumber` | `string` | Base serial number |
| `AaFilterRateHz` | `int` | Anti-alias filter rate |
| `Number` | `int` | Module number |
| `NumberOfSamples` | `int` | Total samples recorded |
| `UnsubsampledNumberOfSamples` | `int` | Samples before subsampling |
| `RequestedPostTriggerSeconds` | `double` | Requested post-trigger duration |
| `RequestedPreTriggerSeconds` | `double` | Requested pre-trigger duration |
| `PostTriggerSeconds` | `double` | Actual post-trigger duration |
| `PreTriggerSeconds` | `double` | Actual pre-trigger duration |
| `RecordingMode` | `string` | Recording mode string |
| `SampleRateHz` | `int` | Sample rate in Hz |
| `StartRecordSampleNumber` | `int` | Starting sample number |
| `NumberOfChannels` | `int` | Channel count |
| `InlineSerializedData` | `bool` | Inline serialization flag |
| `StartRecordTimestampSec` | `int` | Start timestamp (seconds) |
| `StartRecordTimestampNanoSec` | `int` | Start timestamp (nanoseconds) |
| `TriggerTimestampSec` | `int` | Trigger timestamp (seconds) |
| `TriggerTimestampNanoSec` | `int` | Trigger timestamp (nanoseconds) |
| `TriggerSampleNumbers` | `List<ulong>` | Trigger sample indices |
| `PTPMasterSync` | `bool` | PTP master sync status |
| `TiltSensorAxisXDegreesPre/Post` | `int` | Tilt sensor readings |
| `TiltSensorAxisYDegreesPre/Post` | `int` | Tilt sensor readings |
| `TiltSensorAxisZDegreesPre/Post` | `int` | Tilt sensor readings |
| `TemperatureLocation1-4Pre/Post` | `int` | Temperature readings |
| `Channels` | `List<ITestChannel>` | Module's channels |
| `CalculatedChannels` | `List<ITestChannel>` | Module's calculated channels |
| `IsSelected` | `bool` | Selection state |
**Events:**
- `event PropertyChangedEventHandler PropertyChanged`
### TestChannel
Implements `ITestChannel`. Comprehensive channel metadata. Extends `BasePropertyChanged`. Marked `[Serializable]`.
**Identity Properties:**
| Property | Type |
|----------|------|
| `Group`, `SubGroup` | `string` |
| `ChannelId` | `string` |
| `ChannelDisplayName` | `string` |
| `ChannelName2` | `string` |
| `HardwareChannelName` | `string` |
| `SerialNumber` | `string` |
| `ModuleSerialNumber` | `string` |
| `Description` | `string` |
| `ChannelDescriptionString` | `string` |
| `ChannelType` | `string` |
| `ChannelGroupName` | `string` |
| `Number`, `ChannelNumber` | `int` |
| `TestId`, `TestSetupName` | `string` |
**Calibration Properties:**
| Property | Type |
|----------|------|
| `Sensitivity` | `double` |
| `SensitivityUnits` | `string` |
| `Bridge` | `string` |
| `BridgeResistanceOhms` | `double` |
| `ZeroPoint` | `double` |
| `DesiredRange` | `double` |
| `ActualMaxRangeEu`, `ActualMinRangeEu` | `double` |
| `ActualMaxRangeAdc` | `double` (returns `short.MaxValue`) |
| `ActualMinRangeAdc` | `double` (returns `short.MinValue`) |
| `ActualMaxRangeMv`, `ActualMinRangeMv` | `double` |
| `ExcitationVoltage` | `string` |
| `MeasuredExcitationVoltage`, `FactoryExcitationVoltage` | `double` |
| `MeasuredShuntDeflectionMv`, `TargetShuntDeflectionMv` | `double` |
| `LinearizationFormula` | `string` |
| `LastCalibrationDate` | `DateTime` |
| `SensorId` | `string` |
| `SensorCapacity` | `int` |
| `SensorPolarity` | `string` |
| `UseEUScaler` | `bool` |
| `ScaleFactorEU` | `double` |
**Statistical Properties (all default to `double.NaN`):**
| Property | Description |
|----------|-------------|
| `MinADC`, `MaxADC`, `AveADC`, `StdDevADC`, `T0ADC` | ADC domain statistics |
| `MinMV`, `MaxMV`, `AveMV`, `StdDevMV`, `T0MV` | Millivolt domain statistics |
| `MinEU`, `MaxEU`, `AveEU`, `StdDevEU`, `T0EU` | Engineering unit statistics |
| `MinY`, `MaxY`, `AveY`, `StdDevY`, `T0Value` | Current unit statistics |
**State Properties:**
| Property | Type | Description |
|----------|------|-------------|
| `IsSelected` | `bool` | Selection state with parent notification |
| `IsLocked` | `bool` | Lock state with parent notification |
| `IsGraphChannel` | `bool` | Whether channel is in a graph |
| `IsCalculatedChannel` | `bool` | Whether this is a calculated channel |
| `CanLock` | `bool` | Whether channel can be locked |
| `CanSelectChannel` | `bool` | Whether channel can be selected |
| `IsExpanded` | `bool` | UI expansion state |
| `IsError` | `bool` | Error state |
| `ErrorMessage` | `string` | Error message text |
| `ChannelColor` | `Color` | Display color |
| `ErrorColor` | `Color?` | Red if error, Black otherwise |
**Methods:**
- `ITestChannel Copy()` - Returns shallow copy via `MemberwiseClone()`
- `void SetChannelDescriptionAndDisplayName(string channelDescription)` - Sets description and updates display name
- `override string ToString()` - Returns "N/A" for test-specific embedded strings, otherwise `ChannelDescriptionString`
### TestMetadataList
Factory/parser class for creating test metadata from XML files.
**Methods:**
| Signature | Description |
|-----------|-------------|
| `Task<ObservableCollection<ITestSummary>> GetTestSummaryListAsync(IBaseViewModel parent, string path, string file, string pattern = "")` | Async wrapper (actually synchronous) |
| `ObservableCollection<ITestSummary> GetTestSummaryList(IBaseViewModel parent, string path, string file = "", string pattern = "")` | Builds test summary list with parent |
| `ObservableCollection<ITestSummary> GetTestSummaryList(string path, string file = "", string pattern = "")` | Builds test summary list without parent |
| `List<ITestMetadata> GetTestMetadataList(XDocument xDoc, string path, string file)` | Parses XDocument into metadata objects |
---
## 3. Invariants
- **TestSummary.CalibrationBehavior** defaults to `CalibrationBehaviors.NonLinearIfAvailable`
- **TestSummary.IsSelected** defaults to `false`
- **TestChannel.ActualMaxRangeAdc** always returns `short.MaxValue` (32767)
- **TestChannel.ActualMinRangeAdc** always returns `short.MinValue` (-32768)
- **TestChannel** statistical properties (`MinADC`, `MaxEU`, etc.) are initialized to `double.NaN`
- **TestChannel.ChannelColor** defaults to `Colors.Transparent`
- **TestChannel.ErrorColor** returns `Colors.Red` when `IsError` is `true`, `Colors.Black` otherwise
- **TestMetadataList.GetTestSummaryList** returns results ordered by `TimeStamp.Ticks` descending
- **TestMetadataList** uses file extension `.dts` as default pattern when none specified
- **TestMetadataList.GetTimestamp** falls back to `TestSetup.TimeStamp` if PTP timestamps are invalid or before 1/1/1990
---
## 4. Dependencies
### This module depends on:
- `DTS.Common.Interface` - Core interfaces (`ITestMetadata`, `ITestRunMetadata`, `ITestSetupMetadata`, `ITestGraphs`, `ITestModule`, `ITestChannel`, `ITestSummary`)
- `DTS.Common.Interface.TestDefinition` - Test definition interfaces
- `DTS.Common.Enums.Sensors` - `CalibrationBehaviors` enum
- `DTS.Common.Enums.Viewer` - Viewer-specific enums
- `DTS.Common.Base` - `BasePropertyChanged`, `IBaseViewModel`
- `DTS.Common.Utilities` - Utility classes
- `DTS.Common.Utils` - `PTP1588Timestamps`, `TestUtils`
- `DTS.Common.XMLUtils` - `TestMetadataXml` for XML parsing
- `DTS.Common.Constants` - Constants including `EventNumber`
- `Microsoft.Practices.Prism.Commands` - `DelegateCommand`
- `Microsoft.Practices.Prism.Events` - `IEventAggregator`
- `Microsoft.Practices.ServiceLocation` - `ServiceLocator`
- `System.Windows.Media` - `Color`, `Colors`
- `System.Xml.Linq` - `XDocument`, `XElement`
### What depends on this module:
- Not determinable from source alone; consumers would reference these classes via the `ITestMetadata` family of interfaces.
---
## 5. Gotchas
1. **Async

View File

@@ -0,0 +1,33 @@
---
source_files:
- Common/DTS.CommonCore/Classes/GroupTemplates/Constants.cs
generated_at: "2026-04-17T16:26:10.764880+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "6c2f4aa2a068d759"
---
# GroupTemplates
### Purpose
This module provides constant values used for identifying non-ISO test object types and names within the system. It exists to centralize magic string values that appear to be markers or placeholders for test objects that do not conform to ISO standards, ensuring consistent usage across the codebase.
### Public Interface
- **`Constants` (static class)**
- `public const string NON_ISO_TESTOBJECT_CHANNEL_TYPE = "x_NonISOTestObjectType_x"` - Constant identifying a non-ISO test object channel type.
- `public const string NON_ISO_TESTOBJECT_NAME = "x_NonISOTestObjectName_x"` - Constant identifying a non-ISO test object name.
- `public const string NON_ISO_TESTOBJECT_CHANNEL_TYPE2 = "NONISO_x_"` - Alternative prefix constant for non-ISO test object channel types.
### Invariants
- All members are `const string`, meaning they are compile-time constants and cannot be modified at runtime.
- The values appear to use `x_` prefix/suffix patterns as delimiters, suggesting they are placeholder or marker strings meant to be easily identifiable in data streams or configuration.
### Dependencies
- **Depends on:** None (standalone module with no imports).
- **Depended on by:** Cannot be determined from source alone; likely consumed by test object handling or channel processing components.
### Gotchas
- The naming convention `NON_ISO_TESTOBJECT_CHANNEL_TYPE` vs `NON_ISO_TESTOBJECT_CHANNEL_TYPE2` suggests two different formats may exist in the system. The relationship between these two constants and when to use each is unclear from the source alone.
- The `x_` wrapping pattern appears intentional for parsing/detection purposes but the exact protocol is not documented in source.
---

View File

@@ -0,0 +1,170 @@
---
source_files:
- Common/DTS.CommonCore/Classes/Groups/GroupGRPImportError.cs
- Common/DTS.CommonCore/Classes/Groups/GroupGRPImportGroup.cs
- Common/DTS.CommonCore/Classes/Groups/GroupHardwareDbRecord.cs
- Common/DTS.CommonCore/Classes/Groups/TestSetupGroupRecord.cs
- Common/DTS.CommonCore/Classes/Groups/GroupDbRecord.cs
- Common/DTS.CommonCore/Classes/Groups/GroupGRPImportChannel.cs
- Common/DTS.CommonCore/Classes/Groups/ChannelDbRecord.cs
- Common/DTS.CommonCore/Classes/Groups/GroupHelper.cs
generated_at: "2026-04-17T15:32:21.714066+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "b21188904e1c0fcd"
---
# Documentation: DTS.Common.Classes.Groups
## 1. Purpose
This module provides data structures for managing groups and channels within the DTS (Data Test System) application. It handles three primary concerns: (1) importing `.GRP` files containing channel configurations with associated validation error tracking, (2) representing database records for groups, channels, and hardware associations with `INotifyPropertyChanged` support for UI binding, and (3) maintaining static lookup caches via `GroupHelper` for cross-referencing groups, channels, DAS devices, and test setups. The module serves as the data layer between raw file imports, persistent storage, and the application's business logic.
---
## 2. Public Interface
### GroupGRPImportError
Encapsulates errors encountered during `.GRP` file import.
```csharp
public class GroupGRPImportError
{
public enum Errors
{
FileEmpty, InvalidISOCodeInput, InvalidFullScaleInput, InvalidSensorInput,
InvalidInvertInput, SensorNotFound, InvalidInputMode, InvalidDefaultValue,
InvalidActiveValue, InvalidFireMode, InvalidDelay, InvalidLimitDuration,
InvalidDuration, InvalidCurrent
}
public Errors ErrorCode { get; set; }
public string File { get; set; }
public int Line { get; set; }
public string ExtraInfo { get; set; }
public override string ToString() // Returns ExtraInfo
}
```
### GroupGRPImportGroup
Represents an entire group parsed from a `.GRP` file.
```csharp
public class GroupGRPImportGroup : BasePropertyChanged
{
public bool Included { get; set; } = true;
public bool Overwrite { get; set; } = true;
public string GroupName { get; set; }
public string GroupTags { get; set; }
public string ImportingUserTags { get; set; }
public string SourceFile { get; set; }
public GroupGRPImportChannel[] Channels { get; set; } = { };
public GroupGRPImportError[] GroupErrors { get; set; } = null;
public bool GroupNameHasError { get; set; } // Notifies property change
}
```
### GroupGRPImportChannel
Represents a single channel/row from a TDC GRP file.
```csharp
public class GroupGRPImportChannel : BasePropertyChanged
{
// Field position constants for parsing
public const uint SerialNumberField = 0;
public const uint DisplayNameField = 1;
public const uint ISOCodeField = 2;
public const uint InvertField = 3;
public const uint CapacityField = 4;
public const uint InputModeField = 5;
public const uint DefaultValueField = 6;
public const uint ActiveValueField = 7;
public const uint FireModeField = 8;
public const uint DelayField = 9;
public const uint LimitDurationField = 10;
public const uint DurationField = 11;
public const uint CurrentField = 12;
public enum InputModes { na, TLH, THL, CCNO, CCNC }
public enum FireModes { na, CD, CC }
// Default constants
public const InputModes DefaultInputMode = InputModes.CCNO;
public const double DefaultDefaultValue = 0.0;
public const double DefaultActiveValue = 1.0;
public const FireModes DefaultFireMode = FireModes.CD;
public const double DefaultDelay = 0.00;
public const bool DefaultLimitDuration = true;
public const double DefaultDuration = 10.0;
public const double DefaultCurrent = 1.5;
// Properties
public string SensorSerialNumber { get; set; }
public string DisplayName { get; set; }
public string ISOCode { get; set; }
public bool Invert { get; set; }
public double FullScale { get; set; }
public InputModes? InputMode { get; set; } = null;
public double? DefaultValue { get; set; } = null;
public double? ActiveValue { get; set; } = null;
public FireModes? FireMode { get; set; } = null;
public double? Delay { get; set; } = null;
public bool? LimitDuration { get; set; } = null;
public double? Duration { get; set; } = null;
public double? Current { get; set; } = null;
public GroupGRPImportError Error { get; set; } = null;
public GroupGRPImportGroup ParentGroup { get; set; }
public string GroupName { get; } // Returns ParentGroup.GroupName or "---"
public void GroupNameInvalidate(); // Raises PropertyChanged for GroupName
}
```
### GroupDbRecord
Database record for a group, implements `IGroupDbRecord`.
```csharp
public class GroupDbRecord : BasePropertyChanged, IGroupDbRecord
{
[Key] public int Id { get; set; }
public string SerialNumber { get; set; }
public string Picture { get; set; }
public string DisplayName { get; set; }
public string Description { get; set; }
public bool Embedded { get; set; }
public DateTime LastModified { get; set; }
public string LastModifiedBy { get; set; }
public int? StaticGroupId { get; set; }
public string ExtraProperties { get; set; }
public GroupDbRecord();
public GroupDbRecord(IGroupDbRecord copy);
public GroupDbRecord(IGroup copy, List<KeyValuePair<string,string>> extraProperties);
public GroupDbRecord(IDataReader reader);
}
```
### ChannelDbRecord
Database record for a channel, implements `IChannelDbRecord`.
```csharp
public class ChannelDbRecord : BasePropertyChanged, IChannelDbRecord
{
[Key] public long Id { get; set; }
public int GroupId { get; set; }
public string IsoCode { get; set; }
public string IsoChannelName { get; set; }
public string UserCode { get; set; }
public string UserChannelName { get; set; }
public int DASId { get; set; }
public int DASChannelIndex { get; set; }
public int GroupChannelOrder { get; set; }
public int TestSetupOrder { get; set; }
public int SensorId { get; set; }
public bool IsDisabled { get; set; } // Redirects to Disabled, raises PropertyChanged for "IsDisabled"
public bool Disabled { get; set; }
public DateTime LastModified { get; set; }
public string LastModifiedBy { get; set; }
public ChannelDbRecord();
public ChannelDbRecord(IChannelDbRecord copy

View File

@@ -0,0 +1,46 @@
---
source_files:
- Common/DTS.CommonCore/Classes/Groups/ChannelSettings/ChannelSettingRecord.cs
- Common/DTS.CommonCore/Classes/Groups/ChannelSettings/GroupChannelSettingRecord.cs
- Common/DTS.CommonCore/Classes/Groups/ChannelSettings/ChannelSettingBase.cs
generated_at: "2026-04-17T15:39:15.041041+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "e5d75cd5b9640621"
---
# Documentation: DTS.Common.Classes.Groups.ChannelSettings
## 1. Purpose
This module provides data structures for managing channel configuration settings within the DTS system. It defines three core classes: `ChannelSettingRecord` for storing setting metadata (ID, name, default value), `GroupChannelSettingRecord` for associating settings with specific channels, and `ChannelSettingBase` which serves as the primary working object for channel settings with typed accessors and a comprehensive set of string constants defining valid setting names across analog, squib, digital I/O, UART, and streaming configurations.
---
## 2. Public Interface
### ChannelSettingRecord
**Implements:** `IChannelSettingRecord`, extends `Common.Base.BasePropertyChanged`
| Member | Signature | Description |
|--------|-----------|-------------|
| `Id` | `int Id { get; set; }` | Numeric identifier for the setting. Raises property change notification via `SetProperty`. |
| `SettingName` | `string SettingName { get; set; }` | Name of the setting. Raises property change notification. |
| `DefaultValue` | `string DefaultValue { get; set; }` | Default value for the setting. Raises property change notification. |
| Constructor | `ChannelSettingRecord()` | Default parameterless constructor. |
| Constructor | `ChannelSettingRecord(IDataReader reader)` | Populates instance from a data reader using `Utility.GetInt` and `Utility.GetString`. Expects columns: "Id", "SettingName", "DefaultValue". |
---
### GroupChannelSettingRecord
**Implements:** `IGroupChannelSettingRecord`, extends `BasePropertyChanged`
| Member | Signature | Description |
|--------|-----------|-------------|
| `ChannelId` | `long ChannelId { get; set; }` | Identifier for the channel. Raises property change notification. |
| `SettingId` | `int SettingId { get; set; }` | Identifier for the setting. Raises property change notification. |
| `SettingValue` | `string SettingValue { get; set; }` | The value assigned to this setting. Raises property change notification. |
| Constructor | `GroupChannelSettingRecord()` | Default parameterless constructor. |
| Constructor | `GroupChannelSettingRecord(IDataReader reader, int storedProcedureVersionUsed)` | Populates instance from data

View File

@@ -0,0 +1,173 @@
---
source_files:
- Common/DTS.CommonCore/Classes/Hardware/ExternalTilt.cs
- Common/DTS.CommonCore/Classes/Hardware/DragAndDropPayload.cs
- Common/DTS.CommonCore/Classes/Hardware/SerializableAAF.cs
- Common/DTS.CommonCore/Classes/Hardware/DASDBRecord.cs
- Common/DTS.CommonCore/Classes/Hardware/DASChannelDBRecord.cs
- Common/DTS.CommonCore/Classes/Hardware/DASMonitorInfo.cs
generated_at: "2026-04-17T15:35:03.536570+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "15f5b1bfa66254ec"
---
# DTS.Common.Classes.Hardware Documentation
## Purpose
This module provides data structures and persistence support for Data Acquisition System (DAS) hardware within the DTS system. It contains entity classes for database records (`DASDBRecord`, `DASChannelDBRecord`), hardware configuration containers (`DASMonitorInfo`, `ExternalTilt`), serialization utilities (`SerializableAAF`), and UI interaction constants (`DragAndDropPayload`). These classes serve as the data layer for hardware inventory, channel configuration, and tilt sensor calibration management.
---
## Public Interface
### ExternalTilt
Simple POCO representing an external tilt sensor device.
**Constructor:**
- `ExternalTilt()` - Default parameterless constructor.
**Properties:**
- `string SerialNumber { get; set; }` - Serial number of the tilt device.
- `byte TiltID { get; set; }` - Numeric identifier for the tilt sensor.
- `string SystemID { get; set; }` - Identifier of the associated system.
- `string SystemLocation { get; set; }` - Physical location within the system.
---
### DragAndDropPayload
Container for drag-and-drop format string constants used in UI operations.
**Constants:**
- `const string FORMAT = "RESOLVECHANNELS_HARDWARETABLE"` - Primary drag-and-drop format.
- `const string ALT_FORMAT = "ALT_RESOLVECHANNELS_HARDWARETABLE"` - Alternate format (Alt-modified drag).
- `const string CTRL_FORMAT = "CTRL_RESOLVECHANNELS_HARDWARETABLE"` - Control-modified drag format.
---
### SerializableAAF
Container for DAS type enumeration. Note: All serialization logic is commented out in the source.
**Nested Enum:**
- `enum DAS_TYPE { TDAS = 0, SLICE = 1 }` - Identifies DAS hardware types.
---
### DASDBRecord
Entity class representing a DAS hardware record for database persistence. Implements `IDASDBRecord`.
**Static Property:**
- `static DateTime INVALID_DATE => new DateTime(1970, 1, 1)` - Sentinel value for unset date fields.
**Constructors:**
- `DASDBRecord()` - Default constructor.
- `DASDBRecord(IDASDBRecord copy)` - Copy constructor; performs deep copy of `ChannelTypes` array.
- `DASDBRecord(IDataReader reader)` - Constructs instance from database reader; parses comma-delimited `ChannelTypes` string.
**Properties (Key Database Fields):**
- `int DASId { get; set; }` - Primary key (`[Key]`).
- `string SerialNumber { get; set; }` - Required, max length 50.
- `int DASType { get; set; }` - DAS type identifier.
- `int MaxModules { get; set; }` - Maximum module count.
- `long MaxMemory { get; set; }` - Maximum memory in bytes.
- `double MaxSampleRate { get; set; }` - Maximum sample rate (`decimal(18,0)`).
- `double MinSampleRate { get; set; }` - Minimum sample rate (`decimal(18,0)`).
- `string FirmwareVersion { get; set; }` - Firmware version string.
- `DateTime CalDate { get; set; }` - Calibration date, defaults to `INVALID_DATE`.
- `int ProtocolVersion { get; set; }` - Protocol version number.
- `DateTime LastModified { get; set; }` - Last modification timestamp.
- `string LastModifiedBy { get; set; }` - User who last modified.
- `int Version { get; set; }` - Record version.
- `bool LocalOnly { get; set; }` - Whether record is local-only.
- `DateTime LastUsed { get; set; }` - Last usage timestamp.
- `string LastUsedBy { get; set; }` - User who last used.
- `string Connection { get; set; }` - Connection string/identifier.
- `int Channels { get; set; }` - Channel count.
- `string Position { get; set; }` - Physical position (required, max 50 chars).
- `int[] ChannelTypes { get; set; }` - Array of channel type identifiers.
- `bool IsProgrammable { get; set; }` - Reprogrammability flag.
- `bool IsReconfigurable { get; set; }` - Reconfigurability flag.
- `bool IsModule { get; set; }` - Whether this is a module.
- `int PositionOnDistributor { get; set; }` - Position on distributor.
- `int PositionOnChain { get; set; }` - Position on chain.
- `int Port { get; set; }` - Port number.
- `string ParentDAS { get; set; }` - Parent DAS serial number.
- `DateTime? FirstUseDate { get; set; }` - Nullable first use date.
- `int? TestId { get; set; }` - Nullable test ID.
- `int? GroupId { get; set; }` - Nullable group ID.
- `bool StandIn { get; set; }` - Stand-in flag.
- `double MaxAAFRate { get; set; }` - Maximum anti-aliasing filter rate.
- `bool IsFirstUseValid { get; set; }` - Whether first use date is valid.
---
### DASChannelDBRecord
Entity class representing a DAS channel record. Implements `IDASChannelDBRecord`.
**Constants:**
- `const int DEFAULT_SUPPORTED_BRIDGES = 12` - Default bridge bitmask (half + full bridge).
- `const int DEFAULT_SUPPORTED_EXCITATIONS = 16` - Default excitation bitmask (5V).
- `const int DEFAULT_SUPPORTED_DI_MODES = 16` - Default digital input mode bitmask.
- `const int DEFAULT_SQUIB_FIRE_MODES = 16` - Default squib fire mode bitmask.
- `const int DEFAULT_SUPPORTED_DO_MODES = 16` - Default digital output mode bitmask.
**Constructors:**
- `DASChannelDBRecord()` - Default constructor.
- `DASChannelDBRecord(IDataReader reader)` - Constructs from database reader.
- `DASChannelDBRecord(IDASChannelDBRecord copy)` - Copy constructor.
**Properties:**
- `string HardwareId { get; set; }` - Composite ID (serialnumber_dastype).
- `int DaschannelId { get; set; }` - Primary key.
- `int? Dasid { get; set; }` - Foreign key to parent DAS.
- `int ChannelIdx { get; set; }` - Physical channel index.
- `int SupportedBridges { get; set; }` - Bitmask: Bit 0=IEPE, 1=quarter bridge, 2=half bridge, 3=full bridge, 4=digital input, 5=squib fire, 6=digital output, 7=half bridge signal plus, 8=RTC, 9=UART.
- `int SupportedExcitations { get; set; }` - Bitmask: Bit 1=2V, 2=2.5V, 3=3V, 4=5V, 5=10V, 6=1V.
- `int DASDisplayOrder { get; set; }` - Display order (may differ from physical order).
- `bool LocalOnly { get; set; }` - Deprecated; local-only flag.
- `int SupportedDigitalInputModes { get; set; }` - Bitmask: Bit 1=TLH, 2=THL, 3=CCNO, 4=CCNC.
- `int SupportedSquibFireModes { get; set; }` - Bitmask: Bit 1=capacitor discharge, 2=constant current, 3=AC discharge.
- `int SupportedDigitalOutputModes { get; set; }` - Bitmask: Bit 0=FVLH, 1=FVHL, 2=CCNO, 3=CCNC.
- `string ModuleSerialNumber { get; set; }` - Parent module serial number.
- `int SettingId { get; set; }` - Setting identifier.
- `int ModuleArrayIndex { get; set; }` - Module array index.
---
### DASMonitorInfo
Configuration container for DAS monitor information with file persistence. Implements `IDASMonitorInfo`.
**Constructors:**
- `DASMonitorInfo(IDASCommunication das, IsoViewMode mode)` - Constructs from DAS communication interface.
- `DASMonitorInfo(string path)` - Constructs by reading from file.
**Properties:**
- `string SerialNumber { get; }` - DAS serial number.
- `double[] TiltSensorCals { get; }` - 18-element tilt sensor calibration array.
- `short[] TiltSensorDataPre { get; }` - 3-element pre-capture tilt data.
- `DFConstantsAndEnums.TiltAxes TiltAxes { get; }` - Tilt axis configuration.
- `int AxisIgnored { get; }` - Ignored axis flag.
- `double MountOffsetAxisOne { get; }` - Axis one mount offset.
- `double MountOffsetAxisTwo { get; }` - Axis two mount offset.
**Methods:**
- `string GetChannelName(int index)` - Returns channel name or default `"Ch#XX"` format if out of range.
- `double GetOffsetTolerancemVHigh(int index)` - Returns high offset tolerance in mV; returns 0 if out of range.
- `double GetOffsetTolerancemVLow(int index)` - Returns low offset tolerance in mV; returns 0 if out of range.
- `void ReadFromFile(string path)` - Reads configuration from file; silently returns if file doesn't exist.
- `void WriteToFile(string path)` - Writes configuration to file.
---
## Invariants
1. **DASDBRecord.INVALID_DATE** is always `1970-01-01` and serves as the sentinel for unset date fields.
2. **DASDBRecord.ChannelTypes** is parsed from comma-delimited string in `IDataReader` constructor; invalid tokens are silently skipped.
3. **

View File

@@ -0,0 +1,34 @@
---
source_files:
- Common/DTS.CommonCore/Classes/ISO/IsoCode.cs
generated_at: "2026-04-17T16:38:36.632422+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "2d494ff206708de3"
---
# Documentation: IsoCode Class
## 1. Purpose
The `IsoCode` class provides a structured representation of a 16-character ISO code, treating it as a composite identifier with distinct semantic segments. It exists to allow reading and modification of individual code components (such as location, dimension, and classification fields) without manual string manipulation. The class maintains a single internal character array and exposes each segment through typed string properties, handling padding and truncation automatically.
## 2. Public Interface
### Constructor
**`IsoCode(string isoCode)`**
- Initializes a new instance from a string input.
- If `null`, treats as empty string.
- If longer than 16 characters, truncates to first 16.
- If shorter than 16 characters, right-pads with `'?'`.
- Copies each character into the internal `_isoCodeFull` array.
### Properties
| Property | Type | Positions | Description |
|----------|------|-----------|-------------|
| `TestObject` | `string` | 0 | Single character. Getter returns 1-char string. Setter uses `'?'` if null/empty. |
| `Position` | `string` | 1 | Single character. Getter returns 1-char string. Setter uses `'?'` if null/empty. |
| `MainLocation` | `string` | 2-5 | Four characters. Pads with `'?'` if under 4 chars; truncates if over 4. |
| `FineLocation1` | `string` | 6-7 | Two characters. Pads with `'?'` if under 2 chars

View File

@@ -0,0 +1,20 @@
---
source_files:
- Common/DTS.CommonCore/Classes/ISO/ExtraProperties/TextPastedArgs.cs
generated_at: "2026-04-17T16:26:56.248977+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "ef070781994ad71a"
---
# ExtraProperties
### Purpose
This module provides event argument classes for clipboard operations within ISO extra property editors. The `TextPastedArgs` class encapsulates information about a text paste event, including the pasted text content, the source extra property, an identifier, and an arbitrary tag, implementing `ITextPastedEventArgs` for consumption by event handlers.
### Public Interface
**`TextPastedArgs`** (class, implements `ITextPastedEventArgs`)
- `TextPastedArgs(string text, IExtraProperty extraProperty, string id, object tag)` — Constructor that captures all event context. The `extraProperty` parameter is stored as `Sender`.
- `string Text { get; }` — The pasted text content.
- `object Sender { get; }` — The `IExtraProperty` that

View File

@@ -0,0 +1,24 @@
---
source_files:
- Common/DTS.CommonCore/Classes/Locking/LockRecord.cs
- Common/DTS.CommonCore/Classes/Locking/LockError.cs
generated_at: "2026-04-17T16:05:42.343101+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "fba1fa1b617963bb"
---
# Locking
### Purpose
This module provides data structures for representing record locks in a multi-user concurrent access system. It captures both the state of an active lock (who holds it, when it was created, what item is locked) and error conditions that can arise during lock operations (stolen locks, lost locks, network failures). This is used to prevent concurrent modifications to shared resources.
### Public Interface
**`LockRecord`** - Immutable record representing an active lock.
| Member | Signature | Description |
|--------|-----------|-------------|
| `LockingUserName` | `string` (get-only) | Username of the lock holder |
| `LockingMachineName` | `string` (get-only) | Machine name where lock was acquired |
| `CreationTime` | `DateTime` (get-only) | When the lock was created |

View File

@@ -0,0 +1,441 @@
---
source_files:
- Common/DTS.CommonCore/Classes/Sensors/DisplayedCalibrationBehavior.cs
- Common/DTS.CommonCore/Classes/Sensors/SensorDbRecord.cs
- Common/DTS.CommonCore/Classes/Sensors/ZeroRef.cs
- Common/DTS.CommonCore/Classes/Sensors/CalMode.cs
- Common/DTS.CommonCore/Classes/Sensors/StreamInputRecord.cs
- Common/DTS.CommonCore/Classes/Sensors/UARTRecord.cs
- Common/DTS.CommonCore/Classes/Sensors/ParseParameters.cs
- Common/DTS.CommonCore/Classes/Sensors/DigitalInputScaleMultiplier.cs
- Common/DTS.CommonCore/Classes/Sensors/DigitalOutDbRecord.cs
- Common/DTS.CommonCore/Classes/Sensors/SensorCalDbRecord.cs
- Common/DTS.CommonCore/Classes/Sensors/StreamOutputRecord.cs
- Common/DTS.CommonCore/Classes/Sensors/ZeroMethod.cs
generated_at: "2026-04-17T15:28:40.781086+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "6acbc1148f00fa7f"
---
# DTS.Common.Classes.Sensors Module Documentation
## 1. Purpose
This module provides data model classes for sensor configuration and calibration within the DTS system. It contains database record classes for persisting sensor metadata, calibration data, and streaming configurations (UDP input/output, UART), along with helper classes for parsing and serializing sensor-specific formats like calibration modes, zero reference methods, and digital input scaling. These classes serve as the data transfer objects between the database layer and business logic for sensor management operations.
---
## 2. Public Interface
### DisplayedCalibrationBehavior
Simple data container for UI display of calibration behaviors.
```csharp
public class DisplayedCalibrationBehavior
{
public DTS.Common.Enums.Sensors.CalibrationBehaviors CalibrationBehavior;
public string DisplayString;
public override string ToString(); // Returns DisplayString
}
```
### SensorDbRecord
Database record for sensor model definitions. Implements `ISensorDbRecord`.
```csharp
public class SensorDbRecord : TagAwareBase, ISensorDbRecord
{
public override TagTypes TagType => TagTypes.SensorModels;
public int id { get; set; }
public short SensorType { get; set; }
public string SerialNumber { get; set; }
public SensorDbRecord(IDataReader reader);
}
```
### ZeroRef
Helper class for zero reference configuration, serialized to string integers.
```csharp
public class ZeroRef
{
public enum ZeroType
{
AverageOverTime,
UsePreEventDiagnostics,
UseZeroMv
}
public ZeroType ZeroMethod { get; }
public ZeroRef(string zeroref); // Parses "0", "1", or "2"
public ZeroRef(ZeroType type);
public override string ToString(); // Returns "0", "1", or "2"
}
```
### CalMode
Helper class for calibration mode, represented as a 3-character sequence (Shunt/Bridge/Filter).
```csharp
public class CalMode
{
public bool ShuntCheck { get; set; }
public bool FullBridge { get; set; }
public bool Filter { get; set; }
public CalMode(string value); // Parses 3-character string
public CalMode();
public override string ToString(); // Returns 3-character string
}
```
### StreamInputRecord
Database record for UDP stream input configuration. Implements `IStreamInputRecord`.
```csharp
public class StreamInputRecord : TagAwareBase, IStreamInputRecord
{
public override TagTypes TagType => TagTypes.Sensors;
public const string DEFAULT_UDP_ADDRESS = "UDP://239.1.2.10:8400";
public int Id { get; set; }
public string SerialNumber { get; set; }
public DateTime LastModified { get; set; }
public string LastUpdatedBy { get; set; }
public bool DoNotUse { get; set; }
public bool Broken { get; set; }
public string StreamInUDPAddress { get; set; }
public StreamInputRecord(ISensorData sd);
public StreamInputRecord(IDataReader reader);
}
```
### UARTRecord
Database record for UART sensor configuration. Implements `IUARTRecord`.
```csharp
public class UARTRecord : TagAwareBase, IUARTRecord
{
public override TagTypes TagType => TagTypes.Sensors;
public const uint UART_BAUDRATE_DEFAULT = 57600;
public const uint UART_DATABITS_DEFAULT = 8;
public const StopBits UART_STOPBITS_DEFAULT = StopBits.None;
public const UartDataFormat UART_DATAFORMAT_DEFAULT = UartDataFormat.Binary;
public const Handshake UART_FLOWCONTROL_DEFAULT = Handshake.None;
public const Parity UART_PARITY_DEFAULT = Parity.None;
public int Id { get; set; }
public string SerialNumber { get; set; }
public uint UartBaudRate { get; set; }
public uint UartDataBits { get; set; }
public StopBits UartStopBits { get; set; }
public Handshake UartFlowControl { get; set; }
public UartDataFormat UartDataFormat { get; set; }
public DateTime LastModified { get; set; }
public string LastUpdatedBy { get; set; }
public bool DoNotUse { get; set; }
public bool Broken { get; set; }
public Parity UartParity { get; set; }
public UARTRecord(ISensorData sensor);
public UARTRecord(IDataReader reader);
}
```
### ParseParameters
Internal helper class to bundle parameters for CSV import operations.
```csharp
public class ParseParameters
{
public ISensorData SensorData { get; set; }
public IFormatProvider ImportCulture { get; set; }
public List<string> Errors { get; set; }
public double IrtraccExponent { get; set; }
public ISensorCalibration SensorCal { get; set; }
public double Sensitivity { get; set; }
public bool SavedIsProportional { get; set; }
public bool SavedRemoveOffset { get; set; }
public bool StripBackslash { get; set; }
public double OriginalOffset { get; set; }
public ZeroMethodType ZeroType { get; set; }
public double ZeroEnd { get; set; }
public double ZeroStart { get; set; }
public ISquibSettingDefaults SquibDefaults { get; set; }
public IDigitalOutDefaults DigitalOutDefaults { get; set; }
public Dictionary<string, string> SensorGroupNameLookup { get; set; }
public Dictionary<string, string> SensorGroupTypeLookup { get; set; }
public Dictionary<string, string> GroupNameToTestObjectLookup { get; set; }
public string SensorTestObject { get; set; }
public bool UseISOCodeFilterMapping { get; set; }
public bool UseZeroForUnfiltered { get; set; }
public Dictionary<string, string> SensorISOCode { get; set; }
public Dictionary<string, string> SensorISOChannelName { get; set; }
public Dictionary<string, string> SensorUserCode { get; set; }
public Dictionary<string, string> SensorUserChannelName { get; set; }
public Dictionary<string, string> SensorDASSerialNumber { get; set; }
public Dictionary<string, int> SensorDASChannelIndex { get; set; }
}
```
### DigitalInputScaleMultiplier
Scaler for digital input transformation. Implements `IDigitalInputScaleMultiplier`.
```csharp
public class DigitalInputScaleMultiplier : IDigitalInputScaleMultiplier
{
public Forms Form { get; set; } = Forms.ArbitraryLowAndHigh;
public double DefaultValue { get; set; } // Value for "OFF" (0)
public double ActiveValue { get; set; } = 1D; // Value for "ON" (1)
public DigitalInputScaleMultiplier();
public DigitalInputScaleMultiplier(DigitalInputScaleMultiplier copy);
public bool SimpleEquals(IDigitalInputScaleMultiplier rhs);
public override bool Equals(object obj);
public override int GetHashCode();
public string ToSerializeDbString();
public void FromDbSerializeString(string s);
}
```
### DigitalOutDbRecord
Database record for digital output configuration. Implements `IDigitalOutDbRecord`.
```csharp
public class DigitalOutDbRecord : BasePropertyChanged, IDigitalOutDbRecord
{
public string SerialNumber { get; set; }
public double DODelay { get; set; }
public double DODuration { get; set; }
public string ModifiedBy { get; set; }
public DateTime LastModified { get; set; }
public int DatabaseId { get; set; }
public string ISOCode { get; set; }
public string ISOChannelName { get; set; }
public string UserCode { get; set; }
public string UserChannelName { get; set; }
public bool Broken { get; set; }
public bool DoNotUse { get; set; }
public DigitalOutputModes DOMode { get; set; }
public bool LimitDuration { get; set; }
public int Version { get; set; }
public byte[] TagsBlobBytes { get; set; }
public DigitalOutDbRecord();
public DigitalOutDbRecord(ISensorData copy, byte[] tagsBlobBytes);
public DigitalOutDbRecord(IDigitalOutDbRecord copy);
public DigitalOutDbRecord(IDataReader reader);
}
```
### SensorCalDbRecord
Database record for sensor calibration data. Implements `ISensorCalDbRecord`.
```csharp
public class SensorCalDbRecord : BasePropertyChanged, ISensorCalDbRecord
{
public bool LinearAdded { get; }
[Key] public int? CalibrationId { get; set; }
public string SerialNumber { get; set; }
[Column(TypeName = "datetime")] public DateTime CalibrationDate { get; set; }
[Required, StringLength(50)] public string Username { get; set; }
public bool LocalOnly { get; set; }
public bool NonLinear { get; set; }
[Required, StringLength(255)] public ICalibrationRecords Records { get; set; }
[Column(TypeName = "datetime")] public DateTime ModifyDate { get; set; }
public bool IsProportional { get; set; }
public bool RemoveOffset { get; set; }
[Required, StringLength(255)] public ZeroMethods ZeroMethods { get; set; }
[Required, StringLength(2048)] public string[] CertificationDocuments { get; set; }
public InitialOffsets InitialOffsets { get; set; }
public SensorCalDbRecord();
public SensorCalDbRecord(ISensorCalDbRecord copy);
public SensorCalDbRecord(IDataReader reader);
}
```
### StreamOutputRecord
Database record for UDP stream output configuration. Implements `IStreamOutputRecord`.
```csharp
public class StreamOutputRecord : TagAwareBase, IStreamOutputRecord
{
public override TagTypes TagType => TagTypes.Sensors;
public const UDPStreamProfile DEFAULT_UDP_PROFILE = UDPStreamProfile.CH10_ANALOG_2HDR;
public const string DEFAULT_UDP_ADDRESS = "UDP://239.1.2.10:8400";
public const ushort MINIMUM_STREAMOUT_TIMECHANNELID = 10;
public const ushort MAXIMUM_STREAMOUT_TIMECHANNELID = 100;
public const ushort DEFAULT_UDP_TIME_CHANNEL_ID = 1;
public const ushort MINIMUM_STREAMOUT_DATACHANNELID = 10;
public const ushort MAXIMUM_STREAMOUT_DATACHANNELID = 100;
public const ushort DEFAULT_UDP_DATA_CHANNEL_ID = 3;
public const string DEFAULT_UDPTMNS_CONFIG = "(1,6,60,0,0,0,0,0)";
public const ushort MINIMUM_STREAMOUT_TDP_INTERVAL_MS = 10;
public const ushort MAXIMUM_STREAMOUT_TDP_INTERVAL_MS = 1000;
public const ushort DEFAULT_IRIG_TIME_DATA_PACKET_INTERVAL_MS = 500;
public const ushort DEFAULT_TMATS_INTERVAL_MS = 1000;
public int Id { get; set; }
public string SerialNumber { get; set; }
public DateTime LastModified { get; set; }
public string LastUpdatedBy { get; set; }
public bool DoNotUse { get; set; }
public bool Broken { get; set; }
public UDPStreamProfile StreamOutUDPProfile { get; set; }
public string StreamOutUDPAddress { get; set; }
public ushort StreamOutUDPTimeChannelId { get; set; }
public ushort StreamOutUDPDataChannelId { get; set; }
public string StreamOutUDPTmNSConfig { get; set; }
public ushort StreamOutIRIGTimeDataPacketIntervalMs { get; set; }
public ushort StreamOutTMATSIntervalMs { get; set; }
public StreamOutputRecord(ISensorData sd);
public StreamOutputRecord(IDataReader reader, int ClientDbVersion, int ConnectionDbVersion);
public static UDPStreamProfile[] AvailableUDPStreamProfiles(int ConnectionDbVersion, bool UseAdvancedStreamingProfiles);
}
```
### ZeroMethod
Configuration for zero reference method with XML serialization support.
```csharp
public class ZeroMethod : INotifyPropertyChanged
{
public event PropertyChangedEventHandler PropertyChanged;
public ZeroMethodType Method { get; set; }
public double Start { get; set; }
public double End { get; set; }
public ZeroMethod(ZeroMethodType zm, double start, double end);
public ZeroMethod(string zm, System.Globalization.CultureInfo culture);
public ZeroMethod(string zm);
public ZeroMethod(ZeroMethod copy);
public ZeroMethod(XElement elem, string prefix, string tblName, string id);
public string ToDbString();
public string ToSerializeString();
public string ToDisplayString(string averageOverTimeFormatString, string diagnosticLevelFormatString, string absoluteZeroFormatString);
internal XElement ToXElement(string prefix);
internal void Update(XElement elem, string prefix);
public override bool Equals(object obj);
public override int GetHashCode();
}
```
### ZeroMethods
Collection of `ZeroMethod` instances. Implements `IZeroMethods`.
```csharp
public class ZeroMethods : IZeroMethods
{
public ZeroMethod[] Methods { get; set; }
public ZeroMethods();
public ZeroMethods(ZeroMethods copy);
public ZeroMethods(ZeroMethod[] copyMethods);
public ZeroMethods(string methods);
public ZeroMethods(ZeroMethod startingMethod);
public void FromSerializedString(string s);
public string ToSerializedString();
public string ToDisplayString(string averageOverTimeFormatString, string diagnosticLevelFormatString, string absoluteZeroFormatString);
public override string ToString();
public override bool Equals(object obj);
}
```
---
## 3. Invariants
### CalMode String Format
- Input string must be exactly 3 characters
- Position 0: `'S'` (ShuntCheck=true) or `'I'` (ShuntCheck=false)
- Position 1: `'D'` (FullBridge=true) or `'S'` (FullBridge=false)
- Position 2: `'F'` (Filter=true) or `'B'` (Filter=false)
### ZeroRef String Format
- Input string must be `"0"`, `"1"`, or `"2"`
- `"0"` maps to `ZeroType.AverageOverTime`
- `"1"` maps to `ZeroType.UsePreEventDiagnostics`
- `"2"` maps to `ZeroType.UseZeroMv`
### DigitalInputScaleMultiplier Serialization
- Uses `CultureInfo.InvariantCulture` for all parsing/formatting
- Serialized format: `{Form}{ListSeparator}{DefaultValue}{ListSeparator}{ActiveValue}`
- Currently only `Forms.ArbitraryLowAndHigh` is supported for serialization
### ZeroMethods Serialization
- Uses separator `"__x__"` between individual `ZeroMethod` entries
- The separator itself is escaped as `"___xx___"` within individual entries
### StreamOutputRecord Channel ID Constraints
- `StreamOutUDPTimeChannelId`: Range `[10, 100]`, default `1`
- `StreamOutUDPDataChannelId`: Range `[10, 100]`, default `3`
- `StreamOutIRIGTimeDataPacketIntervalMs`: Range `[10, 1000]`, default `500`
- `StreamOutTMATSIntervalMs`: Range `[ushort.MinValue, ushort.MaxValue]`, default `1000`
### SensorCalDbRecord NonLinear Behavior
- Setting `NonLinear = true` automatically sets `Records.Records.First().Sensitivity = 1D` and `RemoveOffset = false`
---
## 4. Dependencies
### External Dependencies (Imports)
- `System.Data` - `IDataReader` for database record construction
- `System.IO.Ports` - `StopBits`, `Parity`, `Handshake` enums for UART configuration
- `System.Xml.Linq` - `XElement` for XML serialization in `ZeroMethod`
- `System.ComponentModel` - `INotifyPropertyChanged`, `PropertyChangedEventHandler`
- `System.ComponentModel.DataAnnotations` - `[Key]`, `[Required]`, `[StringLength]`, `[Column]` attributes
- `System.Globalization` - `CultureInfo`, `NumberStyles` for invariant culture parsing
### Internal Dependencies
- `DTS.Common.Base` - `BasePropertyChanged` base class
- `DTS.Common.Enums` - `TagTypes`, `Forms`, `UDPStreamProfile`, `UartDataFormat`, `DigitalOutputModes`
- `DTS.Common.Enums.Sensors` - `CalibrationBehaviors`, `ZeroMethodType`, `NonLinearStyles`
- `DTS.Common.Interface.Tags` - `TagAwareBase`, `TagTypes`
- `DTS.Common.Interface.Sensors` - `ISensorData`, `ISensorDbRecord`, `ISensorCalibration`, `IStreamInputRecord`, `IStreamOutputRecord`, `IUARTRecord`, `IDigitalOutDbRecord`, `ISensorCalDbRecord`, `ICalibrationRecords`, `IZeroMethods`, `IDigitalInputScaleMultiplier`, `ISquibSettingDefaults`, `IDigitalOutDefaults`
- `DTS.Common.Utilities.Logging` - `APILogger.Log()` for exception logging
- `DTS.Common.Classes.Sensors.Utility` - Static helper methods: `GetInt`, `GetShort`, `GetString`, `GetBool`, `GetDateTime`, `GetDouble`, `GetUInt`, `GetUShort`, `GetNullableInt`
- `DTS.Common.Classes.Sensors.SensorConstants` - Default values for zero method
- `DTS.Common.Classes.Sensors.CalibrationRecords` - Calibration record collection
- `DTS.Common.Classes.Sensors.InitialOffsets`, `DTS.Common.Classes.Sensors.InitialOffset` - Initial offset configuration
- `DTS.Common.Strings.Strings` - Localized display strings
---
## 5. Gotchas
### Exception Swallowing in Constructors
`StreamInputRecord(IDataReader)`, `UARTRecord(IDataReader)`, `StreamOutputRecord(IDataReader, int, int)`, and `SensorCalDbRecord(IDataReader)` catch all exceptions, log them via `APILogger.Log()`, and continue execution. This means partially initialized objects can be returned if database columns are missing or malformed.
### CalMode Index-Based Parsing
The `CalMode(string)` constructor accesses string indices directly (`value[0]`, `value[1]`, `value[2]`) without length validation. Passing a string shorter than 3 characters will throw `IndexOutOfRangeException`.
### ZeroMethod Legacy Compatibility
`ZeroMethod` maintains backward compatibility with older TDM format where `"UsePreCalZero"` was used instead of `ZeroMethodType.UsePreEventDiagnosticsZero`. The XML parsing handles both formats.
### DigitalInputScaleMultiplier GetHashCode Collision Handling
The `GetHashCode()` implementation uses different prime multipliers (31, 79, 127) depending on whether values match certain primes to avoid collisions. This is acknowledged as "not perfect but should work in general."
### ParseParameters Location
The XML doc states this class is "needed both in the Wizard CSV import code and in DataPRO CSV import code" and "can probably be moved to only be in Wizard CSV import code when DataPRO CSV import code is removed."
### UARTRecord UartBaudRate Missing Property Change Notification
Unlike most properties in `UARTRecord`, `UartBaudRate` and `UartStopBits` do not call `SetProperty()`—they directly set the backing field without property change notification.
### StreamOutputRecord Conditional Field Loading
`StreamOutputRecord(IDataReader, int, int)` only loads `StreamOutTMATSIntervalMs` if both `ClientDbVersion` and `ConnectionDbVersion` are >= `Constants.TMATS_INTERVAL_VERSION`. The constant `DEFAULT_TMATS_INTERVAL_MS` is defined twice (once as `ushort` literal `1000` and once as `public const ushort`).

View File

@@ -0,0 +1,36 @@
---
source_files:
- Common/DTS.CommonCore/Classes/Sensors/SensorsList/DragAndDropPayload.cs
generated_at: "2026-04-17T16:26:56.245599+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "c639cf0d3beb6c6b"
---
# SensorsList
### Purpose
This module provides a data transfer object for drag-and-drop operations within sensor list UI components. The `DragAndDropPayload` class encapsulates an array of draggable items and defines distinct clipboard format identifiers for different modifier key states (standard, Alt, and Ctrl), enabling the system to differentiate between various drag operation modes.
### Public Interface
**`DragAndDropPayload`** (class)
- `DragAndDropPayload(IDragAndDropItem[] items)` — Constructor that accepts an array of items implementing `IDragAndDropItem`. Stores the array in the read-only `Items` property.
- `IDragAndDropItem[] Items { get; }` — Read-only property containing the dragged items.
- `const string FORMAT` — Standard drag format identifier: `"DTS.Common.Classes.Sensors.SensorsList.DragAndDropPayload"`
- `const string ALT_FORMAT` — Alt-modified drag format identifier: `"ALT_DTS.Common.Classes.Sensors.SensorsList.DragAndDropPayload"`
- `const string CTRL_FORMAT` — Ctrl-modified drag format identifier: `"CTRL_DTS.Common.Classes.Sensors.SensorsList.DragAndDropPayload"`
### Invariants
- The `Items` array, once set via constructor, cannot be modified (property is read-only, though the array contents themselves are not immutable).
- All three format constants are distinct strings; they must not be used interchangeably.
### Dependencies
- **Depends on:** `DTS.Common.Interface.Sensors.SensorsList.IDragAndDropItem` (interface for items in the payload)
- **Depended on by:** Not determinable from source alone; likely consumed by UI components handling sensor list drag-and-drop operations.
### Gotchas
- The `Items` property exposes the internal array directly; callers could modify array contents if the array is mutable. Defensive copying is not performed.
- The format string naming convention suggests these are used with Windows clipboard/drag-drop data formats, but the actual registration and usage with `DataObject` is not shown in this source.
---

View File

@@ -0,0 +1,59 @@
---
source_files:
- Common/DTS.CommonCore/Classes/TMAT/TMTTemplate.cs
generated_at: "2026-04-17T16:26:10.767228+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "d946f7637f4d3229"
---
# TMAT
### Purpose
This module provides template processing functionality for TMT (likely Test Management Template) files. It enables reading template files and replacing placeholder patterns with actual values, supporting both global keys (program-level metadata) and channel-specific keys (per-channel configuration). The module uses an attribute-based enum pattern to associate string patterns with strongly-typed keys.
### Public Interface
- **`TMTGlobalKeys` (enum)**
- Enum values: `NameOfProgram`, `TestId`, `DASSerialNumber`, `DASIndex`, `DASSampleRate`, `TestTimeStamp`, `DASBitRate`, `StreamTimeFormat`, `UdpStreamTimeChannelId`, `UdpStreamDataChannelId`, `CreateDate`
- Each value is decorated with `[TMTKey("pattern")]` defining its placeholder pattern.
- **`TMTChannelKeys` (enum)**
- Enum values: `HardwareChannelNumber`, `ChannelName`, `CouplingMode`, `BridgeResistance`, `AAF`, `OffsetMV`, `InputRangeMV`, `MaxRangeEU`, `MinRangeEU`, `EU`, `ScaleFactorEU`, `OffsetEU`
- Patterns include a `{0}` format placeholder for channel number substitution.
- **`TMTKey` (Attribute class)**
- `public string Key { get; set; }` - The pattern string to look for during replacement.
- `public TMTKey(string key)` - Constructor accepting the pattern.
- `public static string GetKey(TMTGlobalKeys o)` - Returns the pattern string for a given global key.
- `public static string GetKey(TMTChannelKeys o, int channelNumber)` - Returns the formatted pattern string for a channel key, with channel number substituted.
- **`ITMTTemplate` (interface)**
- `void UpdateValue(TMTGlobalKeys key, string value)` - Updates all occurrences of the global key pattern with the provided value.
- `void UpdateValue(TMTChannelKeys key, string value, int channelNumber)` - Updates all occurrences of the channel key pattern with the provided value.
- `string[] GetAllLines()` - Returns all lines currently in the template.
- **`TMTTemplate` (class, implements `ITMTTemplate`)**
- `public TMTTemplate(string templateLocation)` - Constructor that reads all lines from the specified file path. Silently produces empty content if file does not exist.
- `public TMTTemplate(string[] lines)` - Constructor that initializes from an existing array of lines.
- `public void UpdateValue(TMTGlobalKeys key, string value)` - Replaces all occurrences of the key's pattern with value across all lines.
- `public void UpdateValue(TMTChannelKeys key, string value, int channelNumber)` - Replaces all occurrences of the channel key's pattern (formatted with channelNumber) with value across all lines.
- `public string[] GetAllLines()` - Returns the current state of all lines as an array.
### Invariants
- Pattern matching uses `string.Contains()` followed by `string.Replace()`, meaning patterns can match anywhere in a line, not just as whole tokens.
- If a file does not exist at `templateLocation`, the `_allLines` list remains empty (no exception is thrown).
- Channel key patterns use composite format strings with `{0}` as the channel number placeholder.
- All updates are performed in-place on the internal line list; the original file is never modified directly.
### Dependencies
- **Depends on:** `System.Collections.Generic` (for `List<string>`), `System.IO.File` (for reading files), `System.Reflection` (via `GetMember`, `GetCustomAttribute`).
- **Depended on by:** Cannot be determined from source alone; likely consumed by test configuration or data acquisition setup components.
### Gotchas
- **Silent failure on missing file:** The constructor `TMTTemplate(string templateLocation)` does not throw or indicate error if the file doesn't exist—it simply results in an empty template. Callers should verify file existence separately if this matters.
- **Multiple replacements per line:** If a pattern appears multiple times in a single line, `string.Replace()` will replace all occurrences. This may or may not be intended behavior.
- **No validation of channelNumber:** The `UpdateValue(TMTChannelKeys, string, int)` method does not validate that `channelNumber` is within any expected range.
- **Pattern collision risk:** Since matching uses `Contains()`, shorter patterns could inadvertently match within longer strings. For example, a pattern `{TEST ID}` could theoretically match inside `{TEST ID EXTRA}`.
- **No write-back to file:** The class only reads from files and returns modified lines via `GetAllLines()`. Persisting changes requires separate file writing logic.
---

View File

@@ -0,0 +1,74 @@
---
source_files:
- Common/DTS.CommonCore/Classes/Tags/TagAssignment.cs
- Common/DTS.CommonCore/Classes/Tags/Tag.cs
- Common/DTS.CommonCore/Classes/Tags/TagAwareBase.cs
- Common/DTS.CommonCore/Classes/Tags/TagsInstance.cs
generated_at: "2026-04-17T15:37:32.096920+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "7b4ffd11137500b0"
---
# Documentation: DTS.Common.Classes.Tags
## 1. Purpose
This module provides a tag management system for the DTS application, enabling objects to be associated with string-based tags. It implements a caching layer for tag lookups, supports database persistence through delegate injection, and provides an abstract base class (`TagAwareBase`) that any entity requiring tag functionality can extend. The system maintains a singleton `TagsInstance` for in-memory tag caching and uses `TagAssignment` records to persist many-to-many relationships between tags and tagged objects.
---
## 2. Public Interface
### TagAssignment Class
**Namespace:** `DTS.Common.Classes.Tags`
**Inherits:** `BasePropertyChanged`
**Implements:** `ITagAssignment`
| Member | Signature | Description |
|--------|-----------|-------------|
| `ObjectID` | `int` property (get/set) | The ID of the object being tagged. Raises property change notification via `SetProperty`. |
| `TagID` | `int` property (get/set) | The ID of the tag being assigned. Raises property change notification via `SetProperty`. |
| `ObjectType` | `TagTypes` property (get/set) | The type of object being tagged. Raises property change notification via `SetProperty`. |
| Constructor | `TagAssignment()` | Default parameterless constructor. |
| Constructor | `TagAssignment(IDataReader reader)` | Constructs from a data reader, mapping columns: `TagID`, `ObjectID`, `ObjectType` (cast from `short`). |
---
### Tag Class
**Namespace:** `DTS.Common.Classes.Tags`
**Inherits:** `BasePropertyChanged`
**Implements:** `ITag`
| Member | Signature | Description |
|--------|-----------|-------------|
| `INVALID_ID` | `const int = -1` | Constant representing an invalid/unset tag ID. |
| `ID` | `int` property (get/set) | The unique identifier for this tag. |
| `Text` | `string` property (get/set) | The display text of the tag. Defaults to empty string. |
| `IsObsolete` | `bool` property (get/set) | Whether the tag is obsolete. Defaults to `false`. |
| Constructor | `Tag(string tagText, int tagId)` | Creates a tag with specified text and ID; sets `IsObsolete` to `false`. |
| Constructor | `Tag(Tag copy)` | Copy constructor. |
| Constructor | `Tag(IDataReader reader)` | Constructs from a data reader, mapping columns: `TagId`, `Obsolete`, `TagText`. |
| Constructor | `Tag()` | Default parameterless constructor. |
| `Clone` | `object Clone()` | Returns a new `Tag` copied from this instance. |
---
### TagAwareBase Class
**Namespace:** `DTS.Common.Classes`
**Inherits:** `BasePropertyChanged`
**Modifiers:** `abstract`
| Member | Signature | Description |
|--------|-----------|-------------|
| `TagType` | `abstract TagTypes` property (get) | Must be implemented by derived classes to specify the entity type. |
| `TagsBlobBytes` | `byte[]` property (get/set) | Serializes `TagIDs` to/from a byte array using `Buffer.BlockCopy`. Setter silently ignores arrays smaller than `sizeof(int)`. |
| `TagIDs` | `int[]` property (get/set) | Array of tag IDs associated with this object. Never null; defaults to empty array. |
| `SetTagsFromCommaSeparatedString` | `void SetTagsFromCommaSeparatedString(string tagText, GetSqlCommandDelegate getSqlCommand, TagsGetDelegate tagsGet, TagsGetIdDelegate tagsGetId, TagsInsertDelegate tagsInsert)` | Splits comma-separated string and delegates to `SetTags`. |
| `SetTags` | `virtual void SetTags(string[] tagsText, ...)` | Adds tags via `TagsInstance.AddRange`, retrieves IDs, sets `TagIDs`, and raises `OnPropertyChanged("TagIDs")`. |
| `GetTagsAsCommaSeparatedString` | `string GetTagsAsCommaSeparatedString(TagsGetDelegate tagsGet)` | Returns tag texts joined by commas. |
| `GetTagsArray` | `virtual string[] GetTagsArray(TagsGetDelegate tagsGet)` | Returns tag texts via `TagsInstance.GetTagTextFromIDs`. |
| `GetTagIDs` | `virtual int[] GetTagIDs()` | Returns the `TagIDs` array. |
| `RemoveTags` | `virtual void RemoveTags(string[] tagsText)` | **Empty implementation** — does nothing. |
| `TagCompatible` | `bool TagCompatible(string tags, TagsGetDelegate tagsGet)` | Returns `true` if any tag in the comma-separated string matches this object's tags. Empty/whitespace strings return `true`. |
| `TagCompatible` | `virtual bool TagCompatible(int[] tags)` | Returns `true` if `tags` is empty or has intersection with `

View File

@@ -0,0 +1,45 @@
---
source_files:
- Common/DTS.CommonCore/Classes/TestMetaData/TestEngineerDetailsDbRecord.cs
- Common/DTS.CommonCore/Classes/TestMetaData/CustomerDetailsDbRecord.cs
- Common/DTS.CommonCore/Classes/TestMetaData/LabratoryDetailsDbRecord.cs
generated_at: "2026-04-17T15:39:20.382536+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "d3f85cf243663e33"
---
# Documentation: Test Metadata DbRecord Classes
## 1. Purpose
This module provides three entity classes—`TestEngineerDetailsDbRecord`, `CustomerDetailsDbRecord`, and `LabratoryDetailsDbRecord`—that model persistent test metadata records for test engineers, customers, and laboratories respectively. Each class serves as a data transfer object (DTO) that implements property change notification, supports instantiation from database readers via `IDataReader`, and provides copy construction for cloning. These records appear to be part of a larger test management system where metadata about test participants is stored and tracked with versioning and audit information.
---
## 2. Public Interface
### TestEngineerDetailsDbRecord
**Namespace:** `DTS.Common.Classes.TestEngineerDetails`
**Implements:** `ITestEngineerDetailsDbRecord`
**Inherits:** `Base.BasePropertyChanged`
#### Constructors
| Signature | Description |
|-----------|-------------|
| `TestEngineerDetailsDbRecord()` | Default parameterless constructor. |
| `TestEngineerDetailsDbRecord(ITestEngineerDetailsDbRecord testEngineerDetailsDbRecord)` | Copy constructor. Copies all properties except `TestEngineerId`. |
| `TestEngineerDetailsDbRecord(IDataReader reader)` | Constructs instance by reading column values from a data reader. |
#### Properties
| Property | Type | Default | Attributes | Description |
|----------|------|---------|------------|-------------|
| `TestEngineerId` | `int` | `-1` | `[Browsable(false)]`, `[ReadOnly(true)]` | Internal identifier. |
| `Name` | `string` | `""` | `[Browsable(false)]`, `[ReadOnly(true)]` | Internal name key. |
| `TestEngineerName` | `string` | `"NOVALUE"` | `[DisplayResource("TestEngineerName")]` | Display name of the test engineer. |
| `TestEngineerPhone` | `string` | `"NOVALUE"` | `[DisplayResource("TestEngineerPhone")]` | Phone number. |
| `TestEngineerFax` | `string` | `"NOVALUE"` | `[DisplayResource("TestEngineerFax")]` | Fax number. |
| `TestEngineerEmail` | `string` | `"NOVALUE"` | `[DisplayResource("TestEngineerEmail")]` | Email address. |
| `LocalOnly` | `bool` | `false` | `[Browsable(false)]`, `[ReadOnly(true)]` | Indicates if record is local-only. |
| `LastModified` | `DateTime` | `DateTime.MinValue` | `[Browsable(false)]`, `[ReadOnly(true)]` | Timestamp of last modification. |
| `LastModifiedBy` | `string` | `""` | `[Browsable(false)]`, `[ReadOnly(true

View File

@@ -0,0 +1,385 @@
---
source_files:
- Common/DTS.CommonCore/Classes/TestSetups/SimpleHardware.cs
- Common/DTS.CommonCore/Classes/TestSetups/TestSetupHelper.cs
- Common/DTS.CommonCore/Classes/TestSetups/ROIPeriodChannelRecord.cs
- Common/DTS.CommonCore/Classes/TestSetups/ExtraProperties.cs
- Common/DTS.CommonCore/Classes/TestSetups/TestSetupHardwareRecord.cs
- Common/DTS.CommonCore/Classes/TestSetups/TestSetupROIsRecord.cs
- Common/DTS.CommonCore/Classes/TestSetups/CalculatedChannelRecord.cs
- Common/DTS.CommonCore/Classes/TestSetups/ISFFile.cs
- Common/DTS.CommonCore/Classes/TestSetups/GraphRecord.cs
- Common/DTS.CommonCore/Classes/TestSetups/RegionOfInterest.cs
- Common/DTS.CommonCore/Classes/TestSetups/ISFSensorRecord.cs
generated_at: "2026-04-17T15:30:52.784383+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "ac650a057eb86250"
---
# DTS.Common.Classes.TestSetups Module Documentation
## 1. Purpose
This module provides data structures and utilities for managing test setup configurations in the DTS system. It defines entity classes for hardware records, Regions of Interest (ROI), calculated channels, graph configurations, and sensor records. The module supports both in-memory representation and database persistence through `IDataReader` constructors, and includes functionality for reading/writing ISF (Instrument Setup File) format files used for sensor configuration interchange.
---
## 2. Public Interface
### SimpleHardware
```csharp
public class SimpleHardware : Tuple<string, string, int, int>
```
A lightweight data container representing hardware association.
**Constructor:**
- `SimpleHardware(string serialNumber, string parentDAS, int dasId, int dasType)`
**Properties:**
- `string SerialNumber` — Returns `Item1` from the tuple
- `string ParentDAS` — Returns `Item2` from the tuple
- `int DASId` — Returns `Item3` from the tuple
- `int DASType` — Returns `Item4` from the tuple
---
### TestSetupHelper
```csharp
public abstract class TestSetupHelper
```
Static utility class for managing a process-wide cache of test setup names.
**Static Methods:**
- `void ClearTestSetupNames()` — Clears the internal dictionary
- `void SetTestSetupName(int id, string name)` — Associates a name with an ID (overwrites if exists)
- `string GetTestSetupName(int Id)` — Returns the name for the given ID, or `string.Empty` if not found
---
### ROIPeriodChannelRecord
```csharp
public class ROIPeriodChannelRecord : BasePropertyChanged, IROIPeriodChannelRecord
```
Represents a record from the ROIPeriodChannels table.
**Constructor:**
- `ROIPeriodChannelRecord(IDataReader reader)` — Populates from a stored procedure result (`sp_ROIPeriodChannelsGet`)
**Properties:**
- `int TestSetupROIId` — Foreign key to TestSetupROIs table
- `string ChannelName` — Name of a channel in an ROI period
---
### ExtraProperty
```csharp
public class ExtraProperty : IExtraProperty
```
Represents a key-value property with UI support.
**Constructors:**
- `ExtraProperty()`
- `ExtraProperty(string key, string value)`
- `ExtraProperty(IExtraProperty iep)` — Copy constructor
**Properties:**
- `string Key` — Property identifier
- `string Value` — Property value
- `ICommand PasteCommand` — WPF command binding for paste operations
- `UIItemStatus ItemStatus` — UI state tracking
**Events:**
- `PropertyChangedEventHandler PropertyChanged`
---
### TestSetupHardwareRecord
```csharp
public class TestSetupHardwareRecord : BasePropertyChanged, ITestSetupHardwareRecord
```
Represents hardware configuration for a test setup.
**Constructors:**
- `TestSetupHardwareRecord()`
- `TestSetupHardwareRecord(IDataReader reader)` — Populates from database query
- `TestSetupHardwareRecord(ITestSetupHardwareRecord copy)` — Copy constructor
**Properties:**
- `int DASId` — Default: `-1`
- `int TestSetupId`
- `bool AddDAS` — Default: `true`
- `int SamplesPerSecond`
- `bool IsClockMaster` — Default: `false`
- `byte PTPDomainId` — Default: `0`
- `int AntiAliasFilterRate`
---
### TestSetupROIsRecord
```csharp
public class TestSetupROIsRecord : BasePropertyChanged, ITestSetupROIRecord
```
Represents a Region of Interest period definition.
**Constructor:**
- `TestSetupROIsRecord(IDataReader reader)` — Populates from `sp_TestSetupROIsGet`
**Properties:**
- `int TestSetupROIId`
- `int TestSetupId`
- `string Suffix` — e.g., "_ROI Period 1"
- `double ROIStart` — Default: `-1.0D`
- `double ROIEnd` — Default: `1.0D`
- `bool IsEnabled` — Default: `true`
- `bool IsDefault` — Default: `true`
---
### CalculatedChannelRecord
```csharp
public class CalculatedChannelRecord : BasePropertyChanged, ICalculatedChannelRecord
```
Represents a calculated channel definition.
**Constructors:**
- `CalculatedChannelRecord()`
- `CalculatedChannelRecord(ICalculatedChannelRecord record)` — Copy constructor
- `CalculatedChannelRecord(IDataReader reader)` — Populates from database query
**Properties:**
- `string Name`
- `string TestSetupName`
- `int Id` — Database ID; default: `-1`
- `Operations Operation` — Default: `Operations.SUM`
- `string CalculatedValueCode`
- `string[] InputChannelIds` — Default: `["-1"]`
- `string CFCForInputChannels`
- `string ChannelFilterClassForOutput`
- `int TestSetupId`
- `bool ViewInRealtime`
- `int ClipLength`
---
### GraphRecord
```csharp
public class GraphRecord : BasePropertyChanged, IGraphRecord
```
Represents graph configuration for visualization.
**Constructors:**
- `GraphRecord()`
- `GraphRecord(IGraphRecord copy)` — Copy constructor
- `GraphRecord(IDataReader reader)` — Populates from database query
**Properties:**
- `int GraphId`
- `int TestSetupId`
- `string GraphName` — MaxLength: 50
- `string GraphDescription` — MaxLength: 50
- `string ChannelsString` — MaxLength: 2048
- `bool UseDomainMin`
- `double DomainMin` — Default: `double.MinValue`
- `bool UseDomainMax`
- `double DomainMax` — Default: `double.MaxValue`
- `bool UseRangeMin`
- `double RangeMin` — Default: `double.MinValue`
- `bool UseRangeMax`
- `double RangeMax` — Default: `double.MaxValue`
- `string ThresholdsString` — MaxLength: 2048
- `bool LocalOnly` — Default: `false`; marked as deprecated
---
### RegionOfInterest
```csharp
public class RegionOfInterest : IRegionOfInterest
```
Represents a time-based region of interest with channel assignments.
**Static Properties:**
- `bool Deserializing` — Controls whether property changes trigger notifications (used during deserialization)
**Constructors:**
- `RegionOfInterest()`
- `RegionOfInterest(bool isDefault = false)`
- `RegionOfInterest(string suffix = "", bool isDefault = false, double start = -1D, double end = 1D)`
**Properties:**
- `string Suffix` — Automatically prepends "_" if not present
- `double Start` — Default: `double.MinValue`; constrained to be less than `End`
- `double End` — Default: `double.MaxValue`; constrained to be greater than `Start`
- `bool IsEnabled` — Default: `true`
- `bool IsDefault`
- `string[] ChannelNames`
**Methods:**
- `void ResetSuffix()` — Clears suffix to empty string
- `void SetChannelNamesNoNotify(string[] names)` — Sets channel names without triggering change notifications
**Static Methods:**
- `string GetAnalogChanName(string serialNumber, string hardwareChannelName, string startOfHardware, string originalChannelName = "")`
- `string GetChanName(string serialNumber, string hardwareChannelName, string originalChannelName = "")`
- `string RemoveParentDASName(string entireChannelName)`
- `string RemoveAssignedByIDFromHardwareString(string chHardware)`
**Events:**
- `PropertyChangedEventHandler PropertyChanged`
---
### ISFFile
```csharp
public class ISFFile
```
Handles reading and writing ISF (Instrument Setup File) format files.
**Constructor:**
- `ISFFile()`
**Properties:**
- `char[] HeaderLine1` — 80 characters
- `char[] TestSetupName` — 8 characters starting at position 7
- `char[] NumberOfRecords` — 5 characters starting at position 15
- `char[] TestType` — 22 characters starting at position 20
- `char[] TestDivision` — 30 characters starting at position 42
- `char[] TCFile` — 8 characters starting at position 72
- `IISFSensorRecord[] Records` — Array of sensor records
**Methods:**
- `void AddRecord(IISFSensorRecord record)` — Adds a record and updates count
- `void WriteToFile(string pathToFile)` — Writes the ISF file to disk
- `void AddSensors(ISensorData[] sensors)` — Converts sensors to ISFSensorRecord and adds them
---
### ISFSensorRecord
```csharp
public class ISFSensorRecord : IISFSensorRecord
```
Represents a sensor record in ISF file format (4 records of 80 characters each).
**Constructor:**
- `ISFSensorRecord()` — Initializes with spaces and sets `TOMConfigurationName` to "STANDARD"
**Properties (Record 1):**
- `char[] Record1` — 80 characters
- `char[] Tag` — 2 characters at position 75
- `char[] DataChannelNumber` — 5 characters at position 7
- `bool UserIdSensorIDIsNotSpecified` — 1 character at position 15
- `char[] CapacityCharacters` — 11 characters at position 19
- `char[] SerialNumber` — 12 characters at position 30
- `char[] Sensitivity` — 11 characters at position 42
- `char[] BridgeResistance` — 11 characters at position 53
**Properties (Record 2):**
- `char[] Record2` — 80 characters
- `char[] EngineeringUnits` — 12 characters at position 7
- `char[] C1` — 11 characters at position 20
- `char[] EID` — 17 characters at position 31
- `char[] Unknown1` — 4 characters at position 49
- `char[] Unknown2` — 2 characters at position 53
- `char[] FireDelay` — 11 characters at position 55
- `char[] TOMConfigurationName` — 8 characters at position 66
**Properties (Record 3):**
- `char[] Record3` — 80 characters
- `char[] CommentPart1` — 15 characters at position 14
- `char[] CommentPart2` — 40 characters at position 33
**Properties (Record 4):**
- `char[] Record4` — 80 characters
- `char[] CommentPart3` — 15 characters at position 12
- `char[] SensorType` — 20 characters at position 30
- `char[] C2` — 11 characters at position 50
- `char[] C3` — 11 characters at position 61
**Methods:**
- `void SetDataChannelNumber(short value)`
- `void SetCapacity(double capacity)`
- `double GetCapacity()`
- `void SetSensitivity(double sensitivity)`
- `double GetSensitivity()`
- `void SetC1(double c1)` / `double GetC1()`
- `void SetC2(double c2)`
- `void SetC3(double c3)`
- `void SetFireDelay(double fireDelay)`
- `void SetSensorComment(string s)`
- `void Write(System.IO.BinaryWriter writer)`
- `void SetSensor(ISensorData sensor)`
---
### ArrayExtensions (Static Class)
```csharp
public static class ArrayExtensions
```
Extension methods for array manipulation.
**Methods:**
- `void Fill<T>(this T[] sourceArray, T with)` — Fills entire array with value
- `void SubFill<T>(this T[] source, T with, int startIndex, int finalIndex)` — Fills a range
- `void SetValues<T>(this T[] source, T[] with, int startIndex, int length, T pad)` — Copies values with padding
- `T[] GetValues<T>(this T[] source, int startIndex, int length)` — Extracts a sub-array
---
## 3. Invariants
- **SimpleHardware** is immutable (inherits from `Tuple<...>`).
- **TestSetupHardwareRecord.DASId** defaults to `-1`, indicating an unset/unassigned state.
- **CalculatedChannelRecord.Id** defaults to `-1`, indicating a new/unpersisted record.
- **CalculatedChannelRecord.InputChannelIds** is never null after construction (defaults to `["-1"]`).
- **RegionOfInterest.Start** is always less than `End` (enforced by property setters with 0.01 minimum separation).
- **RegionOfInterest.Suffix** is automatically normalized to start with `_` if non-empty.
- **ISFFile** uses fixed record length of 80 characters (`ConstantsAndEnums.RECORD_LENGTH`).
- **ISFSensorRecord** always consists of exactly 4 records of 80 characters each.
- **ISFSensorRecord.NumberOfRecords** in the file header equals `Records.Length * 4`.
- **GraphRecord.DomainMin/Max** and **RangeMin/Max** have default values of `double.MinValue`/`double.MaxValue` and are only meaningful when their corresponding `Use*` boolean is `true`.
---
## 4. Dependencies
### This module depends on:
- `DTS.Common.Base``BasePropertyChanged` base class
- `DTS.Common.Interface.TestSetups` — Interface contracts (`IROIPeriodChannelRecord`, `ITestSetupHardwareRecord`, `ITestSetupROIRecord`, `ICalculatedChannelRecord`, `IISFSensorRecord`)
- `DTS.Common.Interface.Graphs``IGraphRecord`
- `DTS.Common.Interface.Sensors``ISensorData`
- `DTS.Common.Interface.ISO.ExtraProperties``IExtraProperty`
- `DTS.Common.Interface.RegionOfInterest``IRegionOfInterest`
- `DTS.Common.Enums``Operations` enum, `UIItemStatus` enum
- `DTS.Common.Enums.Sensors``SensorConstants`
- `DTS.Common.Events.RegionOfInterest``RegionOfInterestChangedEvent`
- `Microsoft.Practices.Prism.Events``IEventAggregator`
- `Microsoft.Practices.ServiceLocation``ServiceLocator`
- `System.Data``IDataReader` for database record construction
- `System.ComponentModel``INotifyPropertyChanged`, `PropertyChangedEventHandler`
- `System.Windows.Input``ICommand`
### What depends on this module:
- Not determinable from the source files alone.
---
## 5. Gotchas
### TestSetupROIsRecord Constructor Bug
In `TestSetupROIsRecord(IDataReader reader)`, the `TestSetupId` property is incorrectly assigned from the `TestSetupROIId` column:
```csharp
TestSetupId = Utility.GetInt(reader, "TestSetupROIId"); // Should likely be "TestSetupId"
```
This appears to be a copy-paste error; `TestSetupId` should probably read from the `"TestSetupId"` column.
### RegionOfInterest Static State
`RegionOfInterest.Deserializing` is a **static** property that controls change notifications globally. If multiple threads are deserializing ROIs concurrently, or if the flag is not properly reset, notifications may be incorrectly suppressed or fired.
### RegionOfInterest.NotifyChanged Silent Failures
The `NotifyChanged()` method catches and swallows all exceptions silently. Failures in `ServiceLocator` or `IEventAggregator` resolution will go unnoticed.
### ISFFile Overwrites Without Prompt
`ISFFile.WriteToFile()` will delete an existing file at the target path without user confirmation via `Utils.FileUtils.DeleteFileOrMove()`.
### GraphRecord.LocalOnly Deprecated
The `

View File

@@ -0,0 +1,23 @@
---
source_files:
- Common/DTS.CommonCore/Classes/WinApi/WindowsAPIHelpers.cs
generated_at: "2026-04-17T16:26:10.768750+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "cc8a243ee7ad0716"
---
# WinApi
### Purpose
This module provides Windows API interop helpers for window management and monitor handling. It wraps native Win32 structures and functions to enable proper multi-monitor support and window sizing behavior in WPF applications, particularly for handling maximized window positioning relative to the work area (excluding taskbar).
### Public Interface
- **`POINT` (struct)**
- `public int x` - X coordinate.
- `public int y` - Y coordinate.
- `public POINT(int x, int y)` - Constructor.
- **`MINMAXINFO` (struct)**
- `public POINT ptReserved` - Reserved for system use.
- `public POINT ptMaxSize` - Maximum size

View File

@@ -0,0 +1,65 @@
---
source_files:
- Common/DTS.CommonCore/Classes/WindowsFolder/WindowsFolder.cs
generated_at: "2026-04-17T16:38:34.541099+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "95afd8653b72b5d8"
---
# Documentation: WindowsFolder.cs
## 1. Purpose
`WindowsFolder` is a utility class that provides functionality for opening Windows filesystem folders via the operating system's file explorer. It currently exposes a single method for launching Windows Explorer to display the application's manuals directory. This class exists to centralize folder-opening logic for the DTS Suite application, abstracting away the details of process invocation and path construction.
---
## 2. Public Interface
### `public static void OpenManualsFolder(string path)`
Opens the manuals folder in Windows Explorer.
- **Parameters:**
- `path` (string): The base directory path where the Manuals folder is expected to reside.
- **Behavior:**
1. Constructs the full path to the manuals folder by combining the provided `path` with `Constants.ManualsFolder`.
2. Launches Windows Explorer (`Constants.WindowsExplorer`) with the constructed path as an argument using `Process.Start()`.
- **Example usage:**
```csharp
WindowsFolder.OpenManualsFolder(@"C:\DTS\DTS.Suite\1.0\DataPRO");
```
---
## 3. Invariants
- The `path` parameter must be a valid directory path string; no null/empty validation is performed within the method.
- The `Constants.ManualsFolder` constant must be defined and represent a valid folder name.
- The `Constants.WindowsExplorer` constant must be defined and represent a valid executable path or name (likely `"explorer.exe"`).
- The caller is responsible for ensuring the Manuals folder exists at the constructed location before calling this method.
---
## 4. Dependencies
### This module depends on:
- **System** - Base .NET types
- **System.Diagnostics** - `Process` and `ProcessStartInfo` for launching external processes
- **System.IO** - `Path` for path manipulation
- **Constants** (location unspecified in source) - Provides `ManualsFolder` and `WindowsExplorer` constants
### What depends on this module:
- Cannot be determined from the source alone; no consumers are shown.
---
## 5. Gotchas
- **No existence check:** The method does not verify that the constructed `manualsPath` exists before attempting to open it. If the path is invalid, Windows Explorer behavior is undefined (it may open to a default location or show an error).
- **No error handling:** There is no try/catch block. Exceptions from `Process.Start()` (e.g., if Windows Explorer cannot be launched) will propagate to the caller.
- **No null/empty validation:** Passing `null` or an empty string as `path` will result in `Path.Combine()` producing unexpected results, potentially leading to runtime exceptions.
- **Comment discrepancy:** The XML documentation mentions a default path (`C:\DTS\DTS.Suite\(version)\DataPRO\Manuals`), but the method does not use this default—it relies entirely on the caller-provided `path` parameter. The comment describes context rather than implementation.

View File

@@ -0,0 +1,102 @@
---
source_files:
- Common/DTS.CommonCore/Constant/XamlConstants.xaml.cs
- Common/DTS.CommonCore/Constant/DigitalInputs.cs
- Common/DTS.CommonCore/Constant/EmbeddedSensors.cs
- Common/DTS.CommonCore/Constant/Constants.cs
generated_at: "2026-04-17T15:37:19.626495+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "11f8285a2389aede"
---
# Documentation: DTS.CommonCore Constants Module
## 1. Purpose
This module provides centralized constant definitions for the DTS data acquisition system. It consolidates hardware configuration thresholds, embedded sensor parameters, digital input breakpoints, clock synchronization profiles, recording mode definitions, and application-wide settings. The module serves as the single source of truth for magic numbers, hardware limits, default values, and configuration boundaries used throughout the system.
---
## 2. Public Interface
### `DTS.Common.Constant.XamlConstants` (partial class)
- **Signature**: `public partial class XamlConstants`
- **Behavior**: Empty partial class in code-behind; intended to be paired with a XAML resource file. No members defined in this source file.
---
### `DTS.Common.Constant.DigitalInputs` (static class)
| Member | Signature | Description |
|--------|-----------|-------------|
| `ConstantCurrentBreakPointDefault` | `public const double` | Default breakpoint value (19005D) for contact closure digital input transitions. |
| `VoltageInputBreakPointDefault` | `public const double` | Default breakpoint value (19661D) for voltage input digital modes (THL and TLH). |
| `DisplaySPDADCDefault` | `public const bool` | Default display setting for SLICE Pro Digital ADC (false). |
| `ConstantCurrentBreakPoint` | `public static double { get; set; }` | Mutable static property for current constant current breakpoint. Defaults to `ConstantCurrentBreakPointDefault`. Does not persist to storage. |
| `VoltageInputBreakPoint` | `public static double { get; set; }` | Mutable static property for voltage input breakpoint. Defaults to `VoltageInputBreakPointDefault`. Does not persist to storage. |
| `DisplaySPDADC` | `public static bool { get; set; }` | Mutable static property controlling SLICE Pro Digital analog ADC display. Defaults to `DisplaySPDADCDefault`. Does not persist to storage. |
---
### `DTS.Common.Constant.EmbeddedSensors` (static class)
**Power Management / Wake Up Constants:**
| Member | Value | Description |
|--------|-------|-------------|
| `MotionDetectInactivitySMaximum` | 300 | Maximum motion detect inactivity in seconds (5 minutes). |
| `MagnetTimeoutMsMaximum` | 300000 | Maximum magnet timeout in milliseconds (5 minutes). |
**Device Trigger Ranges:**
| Member | Value | Description |
|--------|-------|-------------|
| `EmbeddedLowGLinearAccelerometerRange` | 8 | Low-G linear accelerometer range. |
| `EmbeddedHighGLinearAccelerometerRange` | 400 | High-G linear accelerometer range. |
| `EmbeddedAngularAccelerometerRange` | 2000 | Angular accelerometer range. |
| `EmbeddedAngularRateSensorRange` | 2000 | Angular rate sensor range. |
| `HumidityMinimum` / `HumidityMaximum` | 10 / 100 | Humidity percentage bounds. |
| `PressureMinimum` / `PressureMaximum` | 5 / 15 | Pressure bounds. |
| `TemperatureMinimum` / `TemperatureMaximum` | 0 / 65 | Temperature bounds (Celsius). |
| `TimedIntervalEventDurationMsMinimum` / `Maximum` | 30 / 300000 | Timed interval event duration bounds in ms. |
| `TimedIntervalNumberOfEventsMaximum` | 100 | Maximum number of timed interval events. |
| `IntervalBetweenEventStartsMinutesMaximum` | 1440 | Maximum interval between event starts (24 hours). |
**Sample Rate Limits (from device IC spec):**
| Member | Minimum | Maximum |
|--------|---------|---------|
| `EmbeddedLowGLinearAccelerometerSampleRate` | 1 | 6400 |
| `EmbeddedHighGLinearAccelerometerSampleRate` | 1 | 5120 |
| `EmbeddedAngularAccelerometerSampleRate` | 1 | 1600 |
| `EmbeddedAngularAccelerometerAndRateSensorSampleRate` | 1 | 5120 |
| `EmbeddedAtmosphericSensorSampleRate` | 1 | 157 |
**Default Sample Rates (set to maximum SR):**
| Member | Value |
|--------|-------|
| `DefaultEmbeddedLowGLinearAccelerometerSampleRate` | 6400 |
| `DefaultEmbeddedHighGLinearAccelerometerSampleRate` | 5120 |
| `DefaultEmbeddedAngularAccelerometerSampleRate` | 1600 |
| `DefaultEmbeddedAngularAccelerometerAndRateSensorSampleRate` | 5120 |
| `DefaultEmbeddedAtmosphericSensorSampleRate` | 157 |
---
### `DTS.Common.Constants` (static class)
**String Constants:**
| Member | Value | Description |
|--------|-------|-------------|
| `ROI_TAG` | "ROI" | Region of interest tag identifier. |
| `ALL_TAG` | "ALL" | All-encompassing tag identifier. |
| `DAS_TEST_SETUPS` | "DASTestSetup" | DAS test setup directory/file identifier. |
| `USB` | "USB" | USB connection identifier. |
| `BACKUP_HEADER_EXTENSION` | ".header.bak" | Backup header file extension. |
| `BACKUP_FILE_EXTENSION` | ".bak" | Backup file extension. |
| `DAS_CONFIGS` | "DASConfigs" | DAS configurations identifier. |
| `TEMP_FILE_EXTENSION` | ".tmp" | Temporary file extension. |
| `UDP_STREAM_CH10_TF2` | "2HDR" | UDP streaming header identifier. |
| `EventNumber` | "_Event Number" | Event number label. |
| `UseMeasuredExcitation` | "UseMeasuredExcitation" | Measured excitation setting key. |
| `ManualsFolder` | "Manuals" | Manuals directory name. |
| `WindowsExplorer` | "explorer.exe" | Windows Explorer executable. |
| `NoValue` | "NOVALUE" | No-value placeholder. |

View File

@@ -0,0 +1,113 @@
---
source_files:
- Common/DTS.CommonCore/Constant/DASSpecific/TDAS.cs
- Common/DTS.CommonCore/Constant/DASSpecific/SLICE.cs
- Common/DTS.CommonCore/Constant/DASSpecific/PowerPRO.cs
- Common/DTS.CommonCore/Constant/DASSpecific/SLICE2_TOM.cs
- Common/DTS.CommonCore/Constant/DASSpecific/SLICEDB.cs
- Common/DTS.CommonCore/Constant/DASSpecific/SLICE2.cs
- Common/DTS.CommonCore/Constant/DASSpecific/SLICE1_5.cs
- Common/DTS.CommonCore/Constant/DASSpecific/SLICE6DB.cs
- Common/DTS.CommonCore/Constant/DASSpecific/SLICE6AIRBR.cs
- Common/DTS.CommonCore/Constant/DASSpecific/SLICE6.cs
- Common/DTS.CommonCore/Constant/DASSpecific/TSRAIR.cs
- Common/DTS.CommonCore/Constant/DASSpecific/SLICE6AIR.cs
generated_at: "2026-04-17T15:30:45.585201+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "0cfa9f366a8948ad"
---
# Documentation: DTS.Common.Constant.DASSpecific
## 1. Purpose
This module provides device-specific constants and capability validation logic for various Data Acquisition System (DAS) hardware types within the DTS ecosystem. Each class corresponds to a specific hardware variant (TDAS, SLICE, SLICE2, SLICE6, SLICE6AIR, TSRAIR, PowerPRO, etc.) and defines hardware limits such as maximum anti-aliasing filter rates, minimum firmware protocol versions required for specific features, and methods to query whether recording modes, streaming profiles, or clock synchronization profiles are supported given a particular protocol version. This module serves as the authoritative source for hardware capability boundaries and feature gating based on firmware versions.
---
## 2. Public Interface
### TDAS
- `public const uint MaxAAFilterRateHz = 4300` — Maximum anti-aliasing filter rate for TDAS hardware.
### SLICE
- `public const uint MaxAAFilterRateHz = 30000` — Maximum anti-aliasing filter rate for SLICE hardware.
### PowerPRO
- `public const uint MaxAAFilterRateHz = 20000` — Maximum anti-aliasing filter rate.
- `public const byte MIN_PROTOCOL_VER = 1` — Minimum supported protocol version.
- `public const byte DIAGNOS_SHUNT_DAC = 2` — Protocol version for shunt DAC diagnostics.
- `public const byte MIN_PROTOCOL_QUERYMACTABLE = 9` — Minimum protocol for MAC table queries (firmware B0H3).
- `public const byte MIN_PROTOCOL_MEASUREPOWERPROALLDIAGNOSTICCHANNEL = 12` — Minimum protocol for all diagnostic channel measurement.
### SLICE2_TOM
- `public static bool IsRecordingModeSupported(RecordingModes mode, int protocolVersion)` — Returns `true` for `CircularBuffer`, `MultipleEventCircularBuffer`, `Recorder`, `MultipleEventRecorder`, `HybridRecorder`, `MultipleEventHybridRecorder`, and `ContinuousRecorder`; `false` for all others. The `protocolVersion` parameter is accepted but not used in the logic.
### SLICEDB
- `public const uint MaxAAFilterRateHz = 200000` — Maximum anti-aliasing filter rate.
- `public const byte MIN_PROTOCOL_VER = 1`
- `public const byte MIN_PROTOCOL_ARM = 2`
- `public const byte MIN_PROTOCOL_ENABLEFAULTCHECKING = MIN_PROTOCOL_ARM`
- `public const byte MIN_PROTOCOL_DIAGNOSTICS = 3`
- `public const byte MIN_PROTOCOL_ONOVERRIDE = 4`
- `public const byte MIN_PROTOCOL_OMAP_GPIO = MIN_PROTOCOL_ONOVERRIDE`
- `public const byte MIN_PROTOCOL_INITHARDWAREINPUTLINES = MIN_PROTOCOL_ONOVERRIDE`
- `public const byte MIN_PROTOCOL_BASECALDATE = 5` — ECM Caldate support.
- `public const byte MIN_PROTOCOL_QUERYMACTABLE = 9` — MAC table query support (firmware B0H3).
- `public const byte MIN_PROTOCOL_TILT = 14`
### SLICE2
- `public const uint MaxAAFilterRateHz = 200000`
- `public const int SLICE1_5_BASETYPE = 2`
- `public const int SLICEPRO_DIM_BASETYPE = 3`
- `public const int SLICEPRO_TOM_BASETYPE = 5`
- `public const byte MIN_PROTOCOL_VER = 128`
- `public const int FILE_DATA = 133`
- `public const int MULTIPLE_EVENTS = 134`
- `public const int STACK_SENSORS = 136`
- `public const int STACK_FIRMWARE_UPDATE = 137`
- `public const int DIAGNOSTIC_TWO_VOLT_EXCITATION = 138`
- `public const int QUERY_ARM_AND_TRIGGER_STATUS_TIME_LEFT_IN_ARM = 139`
- `public const byte MIN_PROTOCOL_VER_GEN3 = 140`
- `public const int SLICE2_ONE_WIRE_ID = 142`
- `public const int EVENT_ARM_ATTEMPTS = 145`
- `public const int MEASURE_INTERNAL_OFFSET = 149`
- `public const int START_REC_DELAY_IN_SECONDS = 150`
- `public const int START_REALTIME_STREAM = 152`
- `public const int HALF_BRIDGE_SIG_PLUS_SUPPORT = 154`
### SLICE1_5
- `public const uint MaxAAFilterRateHz = 40000`
- `public const byte MIN_PROTOCOL_VER = 1`
- `public const int QUERY_ARM_AND_TRIGGER_STATUS_TIME_LEFT_IN_ARM = 2`
- `public const int IGNORE_SHORTED_START_EVENT = 4`
- `public const int START_REC_DELAY_IN_SECOND = 5`
- `public const int MEASURE_INTERNAL_OFFSET = 6`
- `public const int START_REALTIME_STREAM = 7`
- `public const int BASE_PLUS_MIN_MULTIEVENT_HYBRID_PROTOCOL = 8`
- `public static bool IsRecordingModeSupported(RecordingModes mode, int protocolVersion)` — Returns `true` for `CircularBuffer`, `Recorder`, `MultipleEventCircularBuffer`, `MultipleEventRecorder`, `HybridRecorder`, and `ContinuousRecorder` unconditionally. Returns `true` for `MultipleEventHybridRecorder` only if `protocolVersion >= BASE_PLUS_MIN_MULTIEVENT_HYBRID_PROTOCOL`. Returns `false` for all other modes.
### SLICE6DB
- `public const uint MaxAAFilterRateHz = 200000`
- `public const byte MIN_PROTOCOL_VER = 1`
- `public const byte MIN_PROTOCOL_QUERYTEMPLOGFILE = 8`
- `public const byte MIN_PROTOCOL_QUERYMACTABLE = 9` — Firmware B0H3.
- `public const byte MIN_PROTOCOL_TILT = 14`
- `public const int CLOCKSYNCPROFILE = 18`
- `public const int PTP_DOMAIN_ID_VER = 18` — PTP Domain ID support per case 30472.
- `public static bool IsClockSyncProfileSupported(ClockSyncProfile profile, int protocolVersion)` — Returns `true` for `None` always. Returns `true` for `Manual` only if `protocolVersion < CLOCKSYNCPROFILE`. Returns `true` for `Master_E2E` and `Slave_E2E` only if `protocolVersion >= CLOCKSYNCPROFILE`. Returns `false` for all others.
### SLICE6AIRBR
- `public const int MIN_PROTOCOL_VER = 1`
- `public const uint MaxAAFilterRateHz = 50000`
- `public static bool IsRecordingModeSupported(RecordingModes mode, int protocolVersion)` — Returns `true` for `CircularBuffer`, `Recorder`, `MultipleEventCircularBuffer`, `MultipleEventRecorder`, `HybridRecorder`, `MultipleEventHybridRecorder`, `ContinuousRecorder`, and `S6A_DeviceStreamingOnly`. Returns `false` for all others. `protocolVersion` is accepted but not used.
- `public static bool IsStreamingProfileSupported(UDPStreamProfile profile, int protocolVersion)` — Returns `true` for `RTCStreaming`, `DTS_UDP`, `CH10_MANUAL_CONFIG`, `CH10_PCM128_MM`, `CH10_ANALOG`, `CH10_PCM_STANDARD`, `CH10_PCM_SUPERCOM`, `CH10_PCM_128BIT_2HDR`, `CH10_ANALOG_2HDR`, `CH10_PCM_STANDARD_2HDR`, `CH10_PCM_SUPERCOM_2HDR`, `TMNS_PCM_STANDARD`, `TMNS_PCM_SUPERCOM`, and `IENA_PTYPE_STREAM`. Returns `false` for all others. `protocolVersion` is accepted but not used.
- `public static bool IsClockSyncProfileSupported(ClockSyncProfile profile, int protocolVersion)` — Returns `true` for `None`, `Master_E2E`, and `Slave_E2E`. Returns `false` for all others. `protocolVersion` is accepted but not used.
### SLICE6
- `public const uint MaxAAFilterRateHz = 20000`
- `public const int MIN_PROTOCOL_VER = 1`
- `public const int DIAGNOS_SHUNT_DAC = 2`
- `public const int START_REC_DELAY_IN_SECONDS = 3`
- `public const int IN_SLICE_TILT_SENSOR_ADC_PRE = 4

View File

@@ -0,0 +1,245 @@
---
source_files:
- Common/DTS.CommonCore/Controls/RoundedBox.xaml.cs
- Common/DTS.CommonCore/Controls/TestIDView.xaml.cs
- Common/DTS.CommonCore/Controls/checkbox.xaml.cs
- Common/DTS.CommonCore/Controls/GridLengthAnimation.cs
- Common/DTS.CommonCore/Controls/ISOPopup.xaml.cs
- Common/DTS.CommonCore/Controls/LookupPopup.xaml.cs
- Common/DTS.CommonCore/Controls/TestIdPreFixSuffixHelper.cs
- Common/DTS.CommonCore/Controls/AutoSizedGridView.cs
- Common/DTS.CommonCore/Controls/DynamicGrid.cs
- Common/DTS.CommonCore/Controls/TestIDViewModel.cs
- Common/DTS.CommonCore/Controls/TestIDControl.xaml.cs
- Common/DTS.CommonCore/Controls/GridViewColumnHeaderSelectable.xaml.cs
- Common/DTS.CommonCore/Controls/GridViewColumnHeaderSearchable.xaml.cs
- Common/DTS.CommonCore/Controls/GridViewColumnHeaderSearchableCheckBox.xaml.cs
generated_at: "2026-04-17T15:28:35.741418+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "7d23a26eb40cb4f6"
---
# DTS.Common.Controls Documentation
## 1. Purpose
This module provides a collection of custom WPF controls and helper classes for the DTS application framework. It includes specialized controls for test ID generation and display, animated grid layouts, data grid enhancements with searchable/selectable column headers, popup dialogs for ISO input and channel code lookup, and utility classes for managing test ID prefixes and suffixes. The controls integrate with the Prism event aggregation system and support MVVM patterns through `INotifyPropertyChanged` implementations.
---
## 2. Public Interface
### Classes
#### `RoundedBox`
A simple `UserControl` wrapper.
- `RoundedBox()` — Default constructor, calls `InitializeComponent()`.
- `void Connect(int connectionId, object target)` — Empty implementation (comment indicates `NotImplementedException` was considered but disabled).
---
#### `TestIDView`
A minimal `UserControl` for test ID display.
- `TestIDView()` — Default constructor, calls `InitializeComponent()`.
---
#### `checkbox`
A partial class handling tooltip events via event aggregation.
- `void ToolTipEventHandler(object sender, ToolTipEventArgs e)` — Marks event as handled, retrieves `IEventAggregator` via `ServiceLocator.Current`, and publishes a `HelpTextEvent` with a `HelpTextEventArg` containing the sender and event args.
---
#### `GridLengthAnimation`
An `AnimationTimeline` subclass for animating `GridLength` values.
- `GridLengthAnimation()` — Default constructor (no-op).
- `GridLength From` / `GridLength To` — Dependency properties defining animation range.
- `Type TargetPropertyType` — Returns `typeof(GridLength)`.
- `object GetCurrentValue(object defaultOriginValue, object defaultDestinationValue, AnimationClock animationClock)` — Interpolates between `From` and `To` values based on `animationClock.CurrentProgress`. Preserves `GridUnitType.Star` or `GridUnitType.Pixel` from the `To` value.
- `Freezable CreateInstanceCore()` — Returns a new `GridLengthAnimation` instance.
---
#### `ISOPopup`
A `Popup` subclass for ISO-related text input with input validation.
- `ISOPopup()` — Default constructor, calls `InitializeComponent()`.
- `void ISOPart_OnPreviewKeyUp(object sender, KeyEventArgs e)` — Filters keyboard input to allow only: letters (A-Z), numbers (0-9, NumPad0-9), control keys (Enter, Return, Tab, OemBackTab, Delete, Back, Home, End), and OemQuestion. Sets `e.Handled` to block disallowed keys.
- `void ISOPart_OnGotMouseCapture(object sender, MouseEventArgs e)` — Selects all text in the `TextBox` sender.
- `void ISOPart_OnGotKeyboardFocus(object sender, KeyboardFocusChangedEventArgs e)` — Selects all text in the `TextBox` sender.
---
#### `LookupPopup`
A `Popup` for selecting channel codes from a list.
- `IEnumerable<IChannelCode> AllChannelCodes` — Public property (getter only, private setter).
- `LookupPopup()` — Default constructor, calls `InitializeComponent()`.
- `delegate void ChannelCodeSelectedEventHandler(object sender, string code, string name)` — Event signature.
- `event ChannelCodeSelectedEventHandler ChannelCodeSelected` — Raised when a channel code is double-clicked.
- `IList PossibleChannels` — Dependency property for the list of selectable channels; defaults to an empty list of anonymous objects with `Code` and `Name` properties.
- `void PossibleChannels_OnMouseDoubleClick(object sender, MouseButtonEventArgs e)` — Raises `ChannelCodeSelected` with `Code` and `Name` extracted via reflection from the selected item.
---
#### `TestIdPreFixSuffixHelper` and Related Types
**Enum `TestIdFixedPrefixSuffixValues`**
- `NotFixed = -1`
- `None = 0`
- `TimeStamp = 1`
- `TestSetupName = 2`
**Class `TestIdPreFixSuffix`**
- `TestIdFixedPrefixSuffixValues FixedValue` — Read-only property, defaults to `NotFixed`.
- `TestIdPreFixSuffix(TestIdFixedPrefixSuffixValues fixedPrefixSuffix)` — Constructor that sets `FixedValue` and creates internal string `"TESTID_PREFIX_SUFFIX_" + fixedPrefixSuffix`.
- `TestIdPreFixSuffix(string dbPrefixSuffix)` — Constructor that stores the string directly.
- `string ToString()` — Returns the internal string.
**Class `TestIdPreFixSuffixHelper` (extends `Base.BasePropertyChanged`)**
- `TestIdPreFixSuffix TestIdPreFixSuffix` — Read-only property.
- `TestIdPreFixSuffixHelper(string testIdPreFixSuffix)` — Constructs with a string value.
- `TestIdPreFixSuffixHelper(TestIdFixedPrefixSuffixValues testIdPreFixSuffix)` — Constructs with an enum value.
- `string ToString()` — Returns localized string from `Strings.Strings.ResourceManager` if available, otherwise the raw string.
- `bool Equals(object obj)` — Compares `FixedValue` and, if `NotFixed`, compares string values.
---
#### `AutoSizedGridView`
A `GridView` subclass that auto-sizes columns on item preparation.
- `void PrepareItem(ListViewItem item)` — Override that tracks columns by hash code, identifies auto-width columns (`double.IsNaN(Width)` with no binding), and forces re-measurement. Also re-binds width bindings if lost.
---
#### `DynamicGrid`
A `Grid` subclass implementing `INotifyPropertyChanged` that auto-arranges children.
- `event PropertyChangedEventHandler PropertyChanged`
- `DynamicGrid()` — Constructor, calls `Refresh()`.
- `byte GridColumns` — Property (default 2); setter calls `Refresh()`.
- `void Refresh()` — Clears and rebuilds `ColumnDefinitions` and `RowDefinitions`, arranges children left-to-right, top-to-bottom. Last column is `Star`-sized; others are `Auto`. Adds a final `Star`-height row.
- `void OnVisualChildrenChanged(DependencyObject visualAdded, DependencyObject visualRemoved)` — Override that calls `Refresh()`.
---
#### `TestIDViewModel`
A view model for test ID generation.
- `event PropertyChangedEventHandler PropertyChanged`
- `string TestSetupLabel` — Property; setter raises `PropertyChanged` for itself and `TestSetupLabelVisibility`.
- `Visibility TestSetupLabelVisibility` — Returns `Collapsed` if label is empty, otherwise `Visible`.
- `string TestIdEditableText` — Property, default `string.Empty`.
- `string TestName` — Property.
- `TestIdPreFixSuffixHelper SelectedTestIdPrefixValueItem` — Default `TEST_ID_SUFFIX_VALUE_NONE_ITEM`.
- `TestIdPreFixSuffixHelper SelectedTestIdSuffixValueItem` — Default `TEST_ID_SUFFIX_VALUE_TIME_STAMP_ITEM`.
- `void PopulateAllTestIdPrefixSuffixValues(string[] serializedValues)` — Populates `AllTestIdPrefixSuffixValues` with built-in items (None, TimeStamp, TestSetupName) plus database values.
- `TestIdPreFixSuffixHelper[] AllTestIdPrefixSuffixValues` — Returns array of available prefix/suffix options.
- `string GetTestId()` — Builds test ID by joining prefix, `TestSetupLabel`, `TestIdEditableText`, and suffix with underscores.
- `string GetTestIdTimestamp()` — Returns formatted timestamp: `"YYYY_MM_DD HH_MM"`.
---
#### `TestIdControl`
A `UserControl` implementing test ID generation (marked for removal).
- Same public interface as `TestIDViewModel` (properties, methods).
- `TestIdControl()` — Constructor, calls `InitializeComponent()`.
- **Note:** Comment indicates this control should be removed after TTS module deletion and migration to new test setup wizard.
---
#### `GridViewColumnHeaderSelectable`
A `UserControl` for column headers with selection popup.
- `event PropertyChangedEventHandler PropertyChanged`
- `GridViewColumnHeaderSelectable()` — Constructor, subscribes to `ListViewStatusEvent` via `IEventAggregator`.
- `string ListviewId` — Dependency property.
- `string HeaderTitle` — Dependency property, default `"Awesome"`.
- `bool ToggleButtonIsChecked` — Controls popup state; raises `OpenChanged` event.
- `Geometry ToggleIconGeometry` — Not fully implemented in code-behind (getter references `dtsGridViewColumnHeader` resource lookup, but no field declaration visible).
- `event RoutedEventHandler OpenChanged` — Bubbling routed event.
- `event RoutedEventHandler ClickHandler` — Bubbling routed event.
- `event RoutedEventHandler SelectAll` — Bubbling routed event; raised by Select All/Clear All buttons.
- `string ToString()` — Returns `HeaderTitle`.
---
#### `GridViewColumnHeaderSearchable`
A `UserControl` for column headers with search functionality.
- `event PropertyChangedEventHandler PropertyChanged`
- `GridViewColumnHeaderSearchable()` — Constructor, subscribes to `ListViewStatusEvent`.
- `string ListviewId` — Dependency property.
- `string HeaderTitle` — Dependency property, default `"Awesome"`.
- `string HeaderSearchTerm` — Dependency property; changes raise `Search` event.
- `bool ToggleButtonIsChecked` — Controls popup state.
- `Geometry ToggleIconGeometry` — Returns `DownArrowIconGeometry` or `FilterIconGeometry` based on whether `HeaderSearchTerm` is empty.
- `event RoutedEventHandler OpenChanged` — Bubbling routed event.
- `event RoutedEventHandler ClickHandler` — Bubbling routed event.
- `event RoutedEventHandler Search` — Bubbling routed event.
**Class `BoolToInvertedBoolConverter`**
- `object Convert(object value, ...)` — Returns inverted boolean.
- `object ConvertBack(...)` — Throws `NotImplementedException`.
---
#### `GridViewColumnHeaderSearchableCheckBox`
A `UserControl` for column headers with search and boolean filter options.
- `event PropertyChangedEventHandler PropertyChanged`
- `GridViewColumnHeaderSearchableCheckBox()` — Constructor, subscribes to `ListViewStatusEvent`.
- `string ListviewId` — Dependency property.
- `string HeaderTitle` — Dependency property, default `"Awesome"`.
- `string HeaderSearchTerm` — Dependency property.
- `bool ToggleButtonIsChecked` — Controls popup state.
- `Geometry ToggleIconGeometry` — Returns icon based on search term state.
- `event RoutedEventHandler OpenChanged` — Bubbling routed event.
- `event RoutedEventHandler ClickHandler` — Bubbling routed event.
- `event RoutedEventHandler Search` — Bubbling routed event (registered as `"SearchCheckBox"`).
- `event RoutedEventHandler Filter` — Bubbling routed event; raised with `"All"`, `"True"`, or `"False"`.
---
## 3. Invariants
- **GridLengthAnimation**: `animationClock.CurrentProgress` must have a value (no null check); calling `GetCurrentValue` when `CurrentProgress` is null will throw.
- **ISOPopup**: The `ISOPart_OnPreviewKeyUp` handler only filters key input; paste operations are not explicitly handled.
- **LookupPopup**: `PossibleChannels_OnMouseDoubleClick` uses reflection to access `Code` and `Name` properties; items in `PossibleChannels` must have these properties or `NullReferenceException` may occur.
- **DynamicGrid**: `GridColumns` must be at least 1 for meaningful layout (0 would clear all columns).
- **AutoSizedGridView**: Column tracking uses `GetHashCode()`; if column objects are replaced with equal-hash instances, the tracking may not update correctly.
- **GridViewColumnHeaderSelectable/Searchable/SearchableCheckBox**: All require `ServiceLocator.Current` to return a valid `IEventAggregator` instance at construction time.
---
## 4. Dependencies
### External Dependencies (Imports)
- `System.Windows.*` — WPF core assemblies (`Controls`, `Input`, `Data`, `Media`, `Media.Animation`, `Navigation`, `Shapes`, `Controls.Primitives`).
- `Microsoft.Practices.ServiceLocation``ServiceLocator` for service location.
- `Microsoft.Practices.Prism.Events``IEventAggregator`, `ThreadOption` for event aggregation.
### Internal Dependencies
- `DTS.Common.Events``HelpTextEvent`, `HelpTextEventArg`, `ListViewStatusEvent`, `ListViewStatusArg`.
- `DTS.Common.Interface.Channels.ChannelCodes``IChannelCode` interface.
- `DTS.Common.Base``BasePropertyChanged`, `IBasePropertyChanged`.
- `DTS.Common.Utilities.Logging` — Referenced but not directly used in visible code.
- `Strings.Strings` — Resource manager for localization in `TestIdPreFixSuffixHelper`.
### Consumers
- Unknown from source alone; these are reusable controls likely consumed by various modules in the DTS application.
---
## 5. Gotchas
1. **TestIdControl is deprecated**: The class has a comment indicating it should be removed after TTS module deletion. New code should use `TestIDViewModel` instead.
2. **Reflection-based property access in LookupPopup**: `PossibleChannels_OnMouseDoubleClick` uses `GetProperty("Code")` and `GetProperty("Name")` via reflection. This is fragile and will fail silently (returning null) or throw if properties don't exist.
3. **GridLengthAnimation null progress risk**: `GetCurrentValue` accesses `animationClock.CurrentProgress.Value` without null checking. If the animation clock hasn't started or progress is unavailable, this will throw `InvalidOperationException`.
4. **checkbox class naming**: The class `checkbox` violates C# naming conventions (should be PascalCase `Checkbox`). This may cause confusion or issues with XAML namespace mapping.
5. **RoundedBox.Connect is a stub**: The `Connect` method has a commented-out `NotImplementedException`. Its purpose is unclear—it may be an interface implementation requirement or leftover code.
6. **GridViewColumnHeaderSelectable.OnListviewStatusEvent has empty body**: When `arg.Id == ListviewId` and status is `Unloaded`, the if-block is empty. This appears to be incomplete implementation.
7. **Duplicate code between TestIDViewModel and TestIdControl**: These classes have nearly identical logic. This is technical debt from the migration mentioned in the deprecation comment.
8. **DynamicGrid adds extra row**: `Refresh()` always adds a final `Star`-height row definition even if no children exist, which may affect layout in unexpected ways.
9. **GridViewColumnHeaderSearchableCheckBox.Search event name mismatch**: The routed event is registered with name `"SearchCheckBox"` but the CLR event is named `Search`, which could cause confusion in XAML binding.

View File

@@ -0,0 +1,240 @@
---
source_files:
- Common/DTS.CommonCore/Converters/BooleanToBorderThicknessConverter.cs
- Common/DTS.CommonCore/Converters/BooleanToBorderBrushConverter.cs
- Common/DTS.CommonCore/Converters/BooleanOrMultiConverter.cs
- Common/DTS.CommonCore/Converters/BooleanToGreenBorderConverter.cs
- Common/DTS.CommonCore/Converters/DateTimeWithMillisecondsToStringConverter.cs
- Common/DTS.CommonCore/Converters/EnumVisibilityConverter.cs
- Common/DTS.CommonCore/Converters/InverseEnumVisibilityConverter.cs
- Common/DTS.CommonCore/Converters/ActiveContentConverter.cs
- Common/DTS.CommonCore/Converters/FaultedTextConverter.cs
- Common/DTS.CommonCore/Converters/TriggerTextConverter.cs
- Common/DTS.CommonCore/Converters/NullableFloatConverter.cs
- Common/DTS.CommonCore/Converters/TriggerColorConverter.cs
- Common/DTS.CommonCore/Converters/FaultedColorConverter.cs
- Common/DTS.CommonCore/Converters/DateConverter.cs
- Common/DTS.CommonCore/Converters/InverseEnumEnabledConverter.cs
- Common/DTS.CommonCore/Converters/IsLessThanConverter.cs
- Common/DTS.CommonCore/Converters/ListToStringConverter.cs
- Common/DTS.CommonCore/Converters/IsGreaterThanConverter.cs
- Common/DTS.CommonCore/Converters/NonZeroToColorConverter.cs
- Common/DTS.CommonCore/Converters/HeightConverter.cs
- Common/DTS.CommonCore/Converters/ErrorToBooleanConverter.cs
- Common/DTS.CommonCore/Converters/WidthConverter.cs
- Common/DTS.CommonCore/Converters/StringListToVisibilityConverter.cs
- Common/DTS.CommonCore/Converters/StatusToBorderThicknessConverter.cs
- Common/DTS.CommonCore/Converters/ArrayVisibilityConverter.cs
- Common/DTS.CommonCore/Converters/ErrorToColorConverter.cs
- Common/DTS.CommonCore/Converters/GreaterThanToBoolConverter.cs
- Common/DTS.CommonCore/Converters/BooleanToColorConverter.cs
- Common/DTS.CommonCore/Converters/BooleanToItalicFontStyleConverter.cs
- Common/DTS.CommonCore/Converters/IntervalToVisibilityConverter.cs
- Common/DTS.CommonCore/Converters/DiagStatusShuntColorConverter.cs
- Common/DTS.CommonCore/Converters/DiagStatusOffsetColorConverter.cs
- Common/DTS.CommonCore/Converters/InverseBooleanToOpacityConverter.cs
- Common/DTS.CommonCore/Converters/StatusToColorConverter.cs
- Common/DTS.CommonCore/Converters/ColorToSolidColorBrushConverter .cs
- Common/DTS.CommonCore/Converters/BooleanAndToVisibiltyMultiConverter.cs
- Common/DTS.CommonCore/Converters/BooleanOrToVisibilityMultiConverter.cs
- Common/DTS.CommonCore/Converters/DoubleFromThousandthUnitToBaseUnit.cs
- Common/DTS.CommonCore/Converters/BooleanToOpacityConverter.cs
- Common/DTS.CommonCore/Converters/DASStatusArmTextConverter.cs
- Common/DTS.CommonCore/Converters/EnumBooleanConverter.cs
- Common/DTS.CommonCore/Converters/InitialOffsetToIEPESensorOffsetConverter.cs
- Common/DTS.CommonCore/Converters/DASStatusColorConverter.cs
- Common/DTS.CommonCore/Converters/DASStatusArmColorConverter .cs
- Common/DTS.CommonCore/Converters/PercentConverter.cs
- Common/DTS.CommonCore/Converters/NumericStringFormatConverter.cs
- Common/DTS.CommonCore/Converters/VisibilityToRowHeightConverter.cs
- Common/DTS.CommonCore/Converters/GroupImportErrorToStringConverter.cs
- Common/DTS.CommonCore/Converters/GroupNameToVisibilityConverter.cs
- Common/DTS.CommonCore/Converters/FilePathsToShortStringConverter.cs
- Common/DTS.CommonCore/Converters/InverseBooleanConverter.cs
- Common/DTS.CommonCore/Converters/EnumDescriptionTypeConverter.cs
- Common/DTS.CommonCore/Converters/TestDataToRegionOfInterestMaximumConverter.cs
generated_at: "2026-04-17T15:26:50.716956+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "3c372e9a540e3118"
---
# DTS.Common.Converters Documentation
## 1. Purpose
This module provides a comprehensive collection of WPF value converters for data binding transformations in the DTS application. It bridges the gap between domain models and UI presentation by converting values such as booleans, enums, numeric types, and collections into UI-appropriate representations like `Visibility`, `Brush`, `Thickness`, and formatted strings. The converters support common scenarios including conditional visibility, status indication colors, numeric comparisons, and localization-aware enum display.
---
## 2. Public Interface
### Boolean Converters
| Class | Signature | Behavior |
|-------|-----------|----------|
| `BooleanToBorderThicknessConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `1` when input `bool` is `true`, `2` when `false`. |
| `BooleanToBorderBrushConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `BrushesAndColors.Brush_Warning` when `true`, `Brushes.Transparent` when `false` or `null`. |
| `BooleanToGreenBorderConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `BrushesAndColors.BrushApplicationStatusPowerGreen` when `true`, `BrushesAndColors.BrushFlatControlDarkForeground` when `false` or `null`. |
| `BooleanToColorConverter` | `Convert(object, Type, object, CultureInfo) → object` | Configurable via properties: `Background`, `Inverted`, `AttentionBrush`, `WarningBrush`. Returns color based on boolean state. |
| `BooleanToItalicFontStyleConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `FontStyles.Italic` when `true`, `FontStyles.Normal` when `false` or `null`. |
| `BooleanToOpacityConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `0.5` when `true`, `1` when `false` or `null`. |
| `InverseBooleanToOpacityConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `1.0` when `true`, `0.5` when `false` or `null`. |
| `InverseBooleanConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns inverted boolean. `ConvertBack` also inverts. Returns `false` for `null` input. |
### Multi-Value Boolean Converters
| Class | Signature | Behavior |
|-------|-----------|----------|
| `BooleanOrMultiConverter` | `Convert(object[], Type, object, CultureInfo) → object` | Returns `true` if any boolean in `values` is `true`. Returns `false` if any value is not a `bool`. |
| `BooleanAndToVisibilityMultiConverter` | `Convert(object[], Type, object, CultureInfo) → object` | Returns `Visibility.Visible` if all booleans are `true`. Supports parameter flags: `"FALSE"` inverts logic, `"HIDE"` uses `Hidden` instead of `Collapsed`. |
| `BooleanOrToVisibilityMultiConverter` | `Convert(object[], Type, object, CultureInfo) → object` | Returns `Visibility.Visible` if any boolean is `true`. Same parameter flags as `BooleanAndToVisibilityMultiConverter`. |
### Enum Converters
| Class | Signature | Behavior |
|-------|-----------|----------|
| `EnumVisibilityConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `Visibility.Visible` when `value.Equals(parameter)`, otherwise `Visibility.Hidden`. |
| `InverseEnumVisibilityConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `Visibility.Hidden` when `value.Equals(parameter)`, otherwise `Visibility.Visible`. |
| `EnumBooleanConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `true` when `value.Equals(parameter)`. `ConvertBack` returns `parameter` when `value.Equals(true)`. |
| `InverseEnumEnabledConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `false` when `value.Equals(parameter)`, otherwise `true`. |
| `EnumDescriptionTypeConverter` | `ConvertTo(ITypeDescriptorContext, CultureInfo, object, Type) → object` | Returns `[Description]` attribute value from enum, with localization lookup via `Strings.Strings.ResourceManager`. Includes static helper `GetEnumDescription(Enum)`. |
### Status Converters
| Class | Signature | Behavior |
|-------|-----------|----------|
| `StatusToBorderThicknessConverter` | `Convert(object, Type, object, CultureInfo) → object` | Converts `UIItemStatus` enum to thickness: `None``1`, all others → `2`. |
| `StatusToColorConverter` | `Convert(object, Type, object, CultureInfo) → object` | Converts `UIItemStatus` to `Brush`: `None` → Black, `Success` → Complete, `Failed` → Failed, `Error` → Red, `Warning` → OrangeRed. |
| `FaultedTextConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `Strings.Strings.Faulted` when `true`, `Strings.Strings.FaultsClear` when `false` or non-bool. |
| `FaultedColorConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `Brush_ApplicationStatus_Failed.Color` when `true`, `Brush_ApplicationStatus_Complete.Color` when `false`. |
| `TriggerTextConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `Strings.Strings.Triggered` when `true`, `Strings.Strings.TriggerClear` when `false` or non-bool. |
| `TriggerColorConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `Brush_ApplicationStatus_Failed.Color` when `true`, `Brush_ApplicationStatus_Waiting.Color` when `false`. |
### DAS/Diagnostic Status Converters
| Class | Signature | Behavior |
|-------|-----------|----------|
| `DASStatusColorConverter` | `Convert(object, Type, object, CultureInfo) → object` | Converts `DASStatuses` enum to status brush (Idle, Busy, Failed, Complete). |
| `DASStatusArmTextConverter` | `Convert(object, Type, object, CultureInfo) → object` | Converts `DASStatuses` to localized arm status text (`Table_NA`, `NotArmed`, `Armed`). |
| `DASStatusArmColorConverter` | `Convert(object, Type, object, CultureInfo) → object` | Converts `DASStatuses` to arm-specific status colors. |
| `DiagStatusShuntColorConverter` | `Convert(object, Type, object, CultureInfo) → object` | Converts `DiagStatuses` to color, checking `FailedShunt` flag via bitwise AND. |
| `DiagStatusOffsetColorConverter` | `Convert(object, Type, object, CultureInfo) → object` | Converts `DiagStatuses` to color, checking `FailedOffset` flag via bitwise AND. |
### Numeric Converters
| Class | Signature | Behavior |
|-------|-----------|----------|
| `IsLessThanConverter` | `Convert(object, Type, object, CultureInfo) → object` | Parses `value` and `parameter` as `decimal`, returns `left < right`. Returns `false` on parse failure. |
| `IsGreaterThanConverter` | `Convert(object, Type, object, CultureInfo) → object` | Parses `value` and `parameter` as `decimal`, returns `left > right`. Returns `false` on parse failure. |
| `GreaterEqualThanToBoolConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `value >= parameter` for `int`, `double`, or `ushort`. Returns `false` for unsupported types. |
| `IntervalToVisibilityConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `Visibility.Visible` when `value >= parameter` for `int`, `double`, or `ushort`. |
| `DoubleFromThousandthUnitToBaseUnit` | `Convert(object, Type, object, CultureInfo) → object` | Divides by 1000 (e.g., mV → V). `ConvertBack` multiplies by 1000. Returns `0D` for `NaN` or non-double. |
| `InitialOffsetToIEPESensorOffsetConverter` | `Convert(object, Type, object, CultureInfo) → object` | Converts mV to V with IEPE midpoint offset: `(mV / 1000) + 12.25`. Includes static `ConvertDouble(double)` method. |
| `PercentConverter` | `Convert(object, Type, object, CultureInfo) → object` | Formats `decimal` as `"{0:F1}%"` using `CurrentUICulture`. |
| `NumericStringFormatConverter` | `Convert(object[], Type, object, CultureInfo) → object` | Multi-value converter. `values[0]` is number, `values[1]` is format string. Supports `int`, `double`, `float`, `decimal`. Returns `Strings.Strings.Table_NA` for `NaN`. |
### Visibility Converters
| Class | Signature | Behavior |
|-------|-----------|----------|
| `ArrayVisibilityConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `Visibility.Visible` if `IList.Count > 0` or `Array.Length > 0`, otherwise `Collapsed`. Returns `Hidden` for `null`. |
| `StringListToVisibilityConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `Visibility.Visible` if `List<string>.Any()`, otherwise `Collapsed`. |
| `GroupNameToVisibilityConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `Visibility.Visible` if string starts with `"Graph"`, otherwise `Collapsed`. |
| `VisibilityToRowHeightConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `0` for `Collapsed`, otherwise returns `parameter` (or `0` if null). Supports `InvertSource` dependency property. |
### Dimension Converters
| Class | Signature | Behavior |
|-------|-----------|----------|
| `HeightConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `value - parameter` as `double`. Implements `MarkupExtension` with singleton pattern. |
| `WidthConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `value * parameter` as `double`. Implements `MarkupExtension` with singleton pattern. |
### String/Text Converters
| Class | Signature | Behavior |
|-------|-----------|----------|
| `ListToStringConverter` | `Convert(object, Type, object, CultureInfo) → object` | Joins `List<string>` with `", "`. Throws `InvalidOperationException` for non-string target or null list. |
| `DateConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `DateTime` if value is `DateTime`, otherwise `Strings.Strings.Table_NA`. |
| `NullableFloatConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `float` value or `string.Empty` for non-float. |
| `DateTimeWithMillisecondsToStringConverter` | `Convert(object, Type, object, CultureInfo) → object` | Delegates to `Utils.Utils.FormatTimeStamp()`. |
| `ErrorToBooleanConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `true` if string is null/empty, `null` for non-string. |
| `ErrorToColorConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `SolidColorBrush(Colors.Red)` if string not empty, `SolidColorBrush(Colors.Black)` otherwise. |
| `FilePathsToShortStringConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns file name for single path, `Strings.Strings.MultipleFiles` for multiple, `string.Empty` for empty/null. |
| `GroupImportErrorToStringConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `GroupImportError.ExtraInfo` or `string.Empty`. |
### Other Converters
| Class | Signature | Behavior |
|-------|-----------|----------|
| `ActiveContentConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns value if `ContentControl`, otherwise `Binding.DoNothing`. Bidirectional. |
| `ColorToSolidColorBrushConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `new SolidColorBrush(color)` for `Color` input, `null` otherwise. |
| `NonZeroToColorConverter` | `Convert(object, Type, object, CultureInfo) → object` | Returns `BrushApplicationStatusPowerGreen` for `"0"`, `BrushApplicationStatusPowerClear` for `"---"`, `BrushApplicationStatusPowerRed` otherwise. |
| `TestDataToRegionOfInterestMaximumConverter` | `Convert(object[], Type, object, CultureInfo) → object` | Multi-value converter accepting 5 values: `dataStart`, `dataEnd`, `PreTrigger`, `PostTrigger`, `RecordingMode`. Returns appropriate maximum based on `RecordingModes` enum. |
---
## 3. Invariants
- **Boolean converters**: Input must be castable to `bool` or nullable bool; unexpected types may return default values or `null`.
- **Enum converters**: The `parameter` must match the enum type for `Equals()` comparison to succeed.
- `BooleanOrMultiConverter` and `BooleanAndToVisibilityMultiConverter`: All values in the array must be of type `bool`; presence of any non-bool results in `false`.
- `ListToStringConverter`: Input must be `List<string>`; null or other types throw `InvalidOperationException`.
- `StringListToVisibilityConverter`: Input must be `List<string>`; null throws `InvalidOperationException`.
- `HeightConverter` and `WidthConverter`: Input and parameter must be convertible to `double`.
- `IsLessThanConverter` and `IsGreaterThanConverter`: Values are parsed as `decimal` using the provided culture's `NumberFormat`.
- `TestDataToRegionOfInterestMaximumConverter`: Requires exactly 5 values in specific order; returns `double.PositiveInfinity` if preconditions not met.
- `EnumDescriptionTypeConverter`: Relies on `[Description]` attributes being present on enum fields.
- `VisibilityToRowHeightConverter`: `InvertSource` property must be set before conversion occurs.
---
## 4. Dependencies
### External Dependencies (Imports)
- `System.Windows.Data` - `IValueConverter`, `IMultiValueConverter`, `Binding`
- `System.Windows` - `Visibility`, `DependencyProperty`, `DependencyObject`, `FontStyles`, `MarkupExtension`
- `System.Windows.Media` - `Brush`, `Brushes`, `SolidColorBrush`, `Color`
- `System.Windows.Controls` - `ContentControl`
- `System.Globalization` - `CultureInfo`
- `System.ComponentModel` - `EnumConverter`, `DescriptionAttribute`, `ITypeDescriptorContext`
### Internal Dependencies
- `DTS.Common.Base` - Referenced by `ActiveContentConverter` (usage unclear from source)
- `DTS.Common.Enums` - `UIItemStatus`, `RecordingModes`
- `DTS.Common.Interface.Hardware` - `DASStatuses`, `DiagStatuses`
- `DTS.Common.Classes.Groups` - `GroupImportError`
- `DTS.Common.Strings` - `Strings` static class for localized strings
- `DTS.Common.BrushesAndColors` - Static brush definitions
- `DTS.Common.Utils.Utils` - `FormatTimeStamp()` method
### Consumers
Unknown from source alone. These converters are designed for XAML data binding and would be consumed by Views/UserControls in a WPF application.
---
## 5. Gotchas
1. **Inconsistent null handling**: `BooleanToBorderThicknessConverter` throws `NullReferenceException` on null input (direct cast), while `BooleanToBorderBrushConverter` handles null gracefully.
2. **Opacity semantics inverted between converters**: `BooleanToOpacityConverter` returns `0.5` for `true` and `1` for `false`, while `InverseBooleanToOpacityConverter` returns `1.0` for `true` and `0.5` for `false`. The naming is counterintuitive.
3. **NonZeroToColorConverter uses string comparison**: Checks `value.ToString() == "0"` rather than numeric comparison, which may produce unexpected results for numeric types.
4. **HeightConverter singleton pattern**: Uses a static `_instance` field with lazy initialization via `??` operator, which is not thread-safe.
5. **ConvertBack not implemented consistently**: Many converters return `null` or throw `NotImplementedException` for `ConvertBack`, making them one-way only. `InverseBooleanConverter` is an exception that supports two-way binding.
6. **GreaterEqualThanToBoolConverter filename mismatch**: The file is named `GreaterThanToBoolConverter.cs` but the class is `GreaterEqualThanToBoolConverter` (with "Equal" in the name).
7. **NullableFloatConverter XML comment is incorrect**: The XML doc says "Date converter that will display Table_NA when date is null" — this appears to be copy-pasted from `DateConverter`.
8. **IntervalToVisibilityConverter XML comment is incorrect**: The XML doc mentions "converts between two values and a bool (a >= b)" which describes a different converter.
9. **ListToStringConverter throws on null**: Unlike `StringListToVisibilityConverter` which throws, this could be handled more gracefully.
10. **TestDataToRegionOfInterestMaximumConverter fallthrough**: Returns `double.PositiveInfinity` for unrecognized input configurations, which may cause UI issues if not handled by callers.
11. **BooleanToColorConverter property defaults**: Properties `Background`, `Inverted`, `AttentionBrush`, `WarningBrush` default to `false`. These must be set in XAML as converter properties to change behavior.
12. **EnumDescriptionTypeConverter localization fallback**: If `Strings.Strings.ResourceManager.GetString()` returns null/whitespace, falls back to the description attribute text directly.

View File

@@ -0,0 +1,181 @@
---
source_files:
- Common/DTS.CommonCore/Dialogs/IRegionManagerAware.cs.cs
- Common/DTS.CommonCore/Dialogs/IPopupWindowActionAware.cs
- Common/DTS.CommonCore/Dialogs/ConfirmationEx.cs
- Common/DTS.CommonCore/Dialogs/ConfirmationWindow.xaml.cs
- Common/DTS.CommonCore/Dialogs/NotificationWindow.xaml.cs
- Common/DTS.CommonCore/Dialogs/PopupWindowAction.cs
- Common/DTS.CommonCore/Dialogs/BrowseForFolderDialog.cs
generated_at: "2026-04-17T15:34:12.771311+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "9007c4cfc646753a"
---
# Documentation: DTS.Common.Dialogs
## 1. Purpose
This module provides a WPF dialog infrastructure built on Prism's InteractionRequest pattern. It enables the display of modal and non-modal popup windows (confirmations and notifications) through trigger actions, supports region management within dialogs, and provides a Win32 wrapper for native folder selection dialogs. The module bridges Prism's MVVM-friendly interaction requests with custom WPF window implementations.
---
## 2. Public Interface
### Interfaces
#### `IRegionManagerAware`
Enables objects to receive a scoped `IRegionManager` instance.
```csharp
IRegionManager RegionManager { get; set; }
```
#### `IPopupWindowActionAware`
Enables objects to receive host window and notification context.
```csharp
Window HostWindow { get; set; }
Notification HostNotification { get; set; }
```
---
### Classes
#### `ConfirmationEx : Confirmation`
Extended confirmation with configurable buttons and imagery.
| Property | Type | Default |
|----------|------|---------|
| `Buttons` | `MessageBoxButton` | `MessageBoxButton.OKCancel` |
| `Image` | `MessageBoxImage` | `MessageBoxImage.Question` |
| `Result` | `MessageBoxResult` | (unset) |
---
#### `ConfirmationWindow`
WPF window for displaying confirmations. Removes the system close button via Win32 API.
| Member | Type | Description |
|--------|------|-------------|
| `ConfirmationTemplateProperty` | `DependencyProperty` | Registered for `DataTemplate` |
| `ConfirmationTemplate` | `DataTemplate` | Template for confirmation content |
| `Connect(int, object)` | `void` | **Throws `NotImplementedException`** |
---
#### `NotificationWindow : Window`
WPF window for displaying notifications. Removes the system close button via Win32 API.
| Member | Type | Description |
|--------|------|-------------|
| `NotificationTemplateProperty` | `DependencyProperty` | Registered for `DataTemplate` |
| `NotificationTemplate` | `DataTemplate` | Template for notification content |
| `ImageUriProperty` | `DependencyProperty` | Registered for `Uri` |
| `ImageUri` | `Uri` | URI for notification image |
| `Connect(int, object)` | `void` | Empty implementation |
| `CoppyToClibord_Click(object, RoutedEventArgs)` | `void` | Sets clipboard to hardcoded string |
---
#### `PopupWindowAction : TriggerAction<FrameworkElement>`
Trigger action that displays popup windows in response to `InteractionRequestedEventArgs`.
**Nested Enum:**
```csharp
public enum WindowPositions { CenterOwner, CenterScreen }
```
**Dependency Properties:**
| Property | Type | Default |
|----------|------|---------|
| `WindowContent` | `FrameworkElement` | `null` |
| `ContentTemplate` | `DataTemplate` | `null` |
| `IsModal` | `bool` | `null` (effectively false) |
| `StartupPosition` | `WindowPositions` | `CenterScreen` |
| `CenterOverAssociatedObject` | `bool` | `null` (legacy, unused) |
| `AllowMultipleNotificationWindows` | `bool` | `null` (effectively false) |
**Protected Methods:**
- `Invoke(object parameter)` — Main entry point; creates and displays the window.
- `PrepareContentForWindow(Notification, Window)` — Wires up `IRegionManagerAware` and `IPopupWindowActionAware` on content and its DataContext.
- `GetWindow(Notification)` — Returns either a generic window with `WindowContent` or a specialized window via `CreateWindow`.
- `CreateWindow(Notification)` — Creates `ConfirmationWindow` or `NotificationWindow` based on notification type.
- `GetImageUri(PopupWindowImage)` — Maps enum to pack URI for images.
---
#### `BrowseForFolderDialog`
Win32 `SHBrowseForFolder` wrapper for folder selection.
**Properties:**
| Property | Type | Description |
|----------|------|-------------|
| `SelectedFolder` | `string` | Final selected path (read-only after dialog) |
| `Title` | `string` | Dialog header text |
| `InitialFolder` | `string` | Pre-selected folder path |
| `InitialExpandedFolder` | `string` | Pre-selected and expanded folder (overrides `InitialFolder`) |
| `OKButtonText` | `string` | Custom OK button text |
| `BrowseInfo` | `BROWSEINFOW` | Direct access to Win32 structure |
| `BrowserDialogFlags` | `BrowseInfoFlags` | Flags for dialog behavior |
**Methods:**
- `ShowDialog()``Nullable<bool>` — Shows dialog without owner.
- `ShowDialog(Window owner)``Nullable<bool>` — Shows dialog with WPF window owner.
**Nested Types:**
- `BrowseCallbackProc` — Delegate for browse event handling.
- `BrowseInfoFlags` — Flags enum (`BIF_NEWDIALOGSTYLE`, `BIF_RETURNONLYFSDIRS`, etc.).
- `BROWSEINFOW` — Win32 structure with `hwndOwner`, `pidlRoot`, `pszDisplayName`, `lpszTitle`, `ulFlags`, `lpfn`, `lParam`, `iImage`.
- `MessageFromBrowser` — Messages received from dialog (`BFFM_INITIALIZED`, `BFFM_SELCHANGED`, etc.).
- `MessageToBrowser` — Messages sent to dialog (`BFFM_SETSELECTIONW`, `BFFM_SETEXPANDED`, `BFFM_SETOKTEXT`, etc.).
---
## 3. Invariants
1. **Window close button removal**: Both `ConfirmationWindow` and `NotificationWindow` always strip the `WS_SYSMENU` style during `SourceInitialized`, removing the system close button.
2. **WindowContent parent check**: `PopupWindowAction.Invoke` returns immediately without action if `WindowContent.Parent != null`.
3. **Notification type requirement**: `PopupWindowAction.CreateWindow` returns `null` if the notification is not a `Confirmation` and `notification.Content` is not castable to `NotificationContentEventArgs`.
4. **Default browse flags**: `BrowseForFolderDialog` always initializes with `BIF_NEWDIALOGSTYLE`.
5. **Scoped RegionManager**: If `WindowContent` lacks a `RegionManager`, `PopupWindowAction` creates a new scoped `RegionManager` and assigns it.
---
## 4. Dependencies
**External Dependencies (from imports):**
- `Microsoft.Practices.Prism.Regions``IRegionManager`, `RegionManager`
- `Microsoft.Practices.Prism.Interactivity.InteractionRequest``Notification`, `Confirmation`, `InteractionRequestedEventArgs`
- `System.Windows.Interactivity``TriggerAction<T>`
- `System.Windows` — WPF core types
**Internal Dependencies (inferred):**
- `DTS.Common.Enums.PopupWindowImage` — Enum for notification image types
- `DTS.Common.Events.NotificationContentEventArgs` — Content type for notifications
**Native Dependencies:**
- `user32.dll``SetWindowLong`, `GetWindowLong`, `SendMessageW`
- `shell32.dll``SHBrowseForFolderW`, `SHGetPathFromIDList`
---
## 5. Gotchas
1. **`ConfirmationWindow.Connect` throws**: The `Connect` method is implemented but throws `NotImplementedException`. Purpose is unclear from source—may be related to XAML compilation or an interface requirement.
2. **Hardcoded clipboard text**: `NotificationWindow.CoppyToClibord_Click` (note typo in method name) sets clipboard to the literal string `"Hello, clipboard"`. This appears to be debug/test code left in production.
3. **Commented-out timeout functionality**: Both `ConfirmationEx` and `PopupWindowAction` contain commented-out properties and logic for dialog auto-close/timeout (`Timeout`, `TimeoutResult`, `TimeoutInterval`). This feature was partially implemented but disabled.
4. **Legacy `CenterOverAssociatedObject` property**: The `CenterOverAssociatedObjectProperty` is registered but its usage in `Invoke` is commented out. `StartupPosition` is the current mechanism.
5. **Default dependency property values**: `IsModal` and `AllowMultipleNotificationWindows` default to `null` (via `PropertyMetadata(null)`), which boxes to `false` when cast. This is unconventional—typically defaults are explicit `false`.
6. **Image path relies on assembly structure**: `GetImageUri` constructs pack URIs expecting images in an `Images/` folder within the executing assembly. Relocation of image resources will break this.

View File

@@ -0,0 +1,477 @@
---
source_files:
- Common/DTS.CommonCore/Enums/IsoRestrictionLevels.cs
- Common/DTS.CommonCore/Enums/GPSSentenceTypes.cs
- Common/DTS.CommonCore/Enums/UartDataFormat.cs
- Common/DTS.CommonCore/Enums/NetworkSelection.cs
- Common/DTS.CommonCore/Enums/ScriptTypes.cs
- Common/DTS.CommonCore/Enums/InitializationTypes.cs
- Common/DTS.CommonCore/Enums/Strings.cs
- Common/DTS.CommonCore/Enums/MigrationResult.cs
- Common/DTS.CommonCore/Enums/SLICE6MulticastProperties.cs
- Common/DTS.CommonCore/Enums/RibbonTabNames.cs
- Common/DTS.CommonCore/Enums/IsoSupportLevels.cs
- Common/DTS.CommonCore/Enums/ImportFormats.cs
- Common/DTS.CommonCore/Enums/TabControlOperation.cs
- Common/DTS.CommonCore/Enums/IncludeOverwriteName.cs
- Common/DTS.CommonCore/Enums/RibbonControlOperation.cs
- Common/DTS.CommonCore/Enums/UICultures.cs
- Common/DTS.CommonCore/Enums/T0Mode.cs
- Common/DTS.CommonCore/Enums/VelocityUnit.cs
- Common/DTS.CommonCore/Enums/ImportStatus.cs
- Common/DTS.CommonCore/Enums/IsoViewMode.cs
- Common/DTS.CommonCore/Enums/PopupWindowImage.cs
- Common/DTS.CommonCore/Enums/UIItemStatus.cs
- Common/DTS.CommonCore/Enums/DigitalOutputs.cs
- Common/DTS.CommonCore/Enums/DigitalInputs.cs
- Common/DTS.CommonCore/Enums/DataFlag.cs
- Common/DTS.CommonCore/Enums/Squibs.cs
- Common/DTS.CommonCore/Enums/SupportedExportFormatBitFlags.cs
- Common/DTS.CommonCore/Enums/UartBaudRate.cs
- Common/DTS.CommonCore/Enums/EnumBindingSourceExtension.cs
- Common/DTS.CommonCore/Enums/UDPStreamProfile.cs
- Common/DTS.CommonCore/Enums/ExcitationVoltageOptions.cs
- Common/DTS.CommonCore/Enums/RecordingModes.cs
- Common/DTS.CommonCore/Enums/ApplicationStatusTypes.cs
- Common/DTS.CommonCore/Enums/ExportHeaderLine.cs
- Common/DTS.CommonCore/Enums/StreamDigitalFilterTypes.cs
- Common/DTS.CommonCore/Enums/CFCFilter.cs
- Common/DTS.CommonCore/Enums/ClockSource.cs
generated_at: "2026-04-17T15:26:45.282462+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "9a7e9b192694200c"
---
# DTS.CommonCore.Enums Module Documentation
## 1. Purpose
This module provides a centralized collection of enumeration types, constants, and supporting utility classes used throughout the DTS (Data Translation System) codebase. It defines domain-specific types for hardware configuration (DAS/SLICE6 devices), data acquisition (channel modes, filters, clock sources), import/export operations, UI localization, and application state management. The enums serve as the canonical type definitions for cross-module communication and data serialization.
---
## 2. Public Interface
### Enums
#### `GPSSentenceTypes`
```csharp
public enum GPSSentenceTypes { GPGGA, GPRMC }
```
Defines NMEA GPS sentence types for parsing GPS data.
#### `UartDataFormat`
```csharp
public enum UartDataFormat { Binary, PlainText, NMEA }
```
Specifies the format of UART data streams.
#### `NetworkSelection`
```csharp
public enum NetworkSelection { Default, NetworkId, NetworkDesc }
```
Defines network selection modes for device discovery/configuration.
#### `ScriptTypes`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum ScriptTypes { Migration, Initialization }
```
Categorizes script execution types. Uses `EnumDescriptionTypeConverter` for UI display.
#### `InitializationTypes`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum InitializationTypes { Aero, Crash, TSRAIR }
```
Defines initialization categories for test setups.
#### `StringReplacementMode`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum StringReplacementMode { All, First, Last }
```
Controls string replacement behavior in text operations.
#### `MigrationResult`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum MigrationResult { OK, ExceptionThrown, WarningAllowStreamingModesWasNotMigrated }
```
Indicates outcome of data migration operations.
#### `SLICE6Properties`
```csharp
public enum SLICE6Properties { SLICE6MulticastAddress, SLICE6MulticastCommandPort, SLICE6MulticastResponsePort }
```
Properties for SLICE6 UDP broadcast autodiscovery.
#### `IsoSupportLevels`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum IsoSupportLevels
{
[Description("ISO 13499")] ISO_ONLY,
[Description("User specified channel codes")] TRANSITORY,
[Description("No ISO")] NO_ISO
}
```
Defines ISO 13499 compliance levels for channel coding.
#### `ImportFormats`
```csharp
public enum ImportFormats
{
NOT_SPECIFIED = 1, DTS_XML = 2, ISF = 3, TSF = 4, DTS_CSV = 5,
TTS_XML = 6, CrashDesigner_XML = 7, E2X = 8, TTS_CSV = 9
}
```
Supported import file formats with explicit integer values.
#### `TabControlOperation` / `RibbonControlOperation`
```csharp
public enum TabControlOperation { AddedItem, RemovedItem }
public enum RibbonControlOperation { AddedItem, RemovedItem }
```
Track UI control modification operations. Note: `RibbonControlOperation` XML comment incorrectly references "TabControl".
#### `IncludeOverwriteName` / `ExportChoices`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum IncludeOverwriteName { IncludedCheckBox, OverwriteCheckBox, ImportingTestSetupName }
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum ExportChoices { ExportType, UnfilteredEUCheckBox, FilteredEUCheckBox, MVCheckBox, ADCCheckBox }
```
Define import/export UI selection options.
#### `UICultures`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum UICultures
{
[DescriptionResource("UICultures_de-DE")] de_DE,
[DescriptionResource("UICultures_en-US")] en_US,
[DescriptionResource("UICultures_es-ES")] es_ES,
[DescriptionResource("UICultures_fr-FR")] fr_FR,
[DescriptionResource("UICultures_it-IT")] it_IT,
[DescriptionResource("UICultures_ja-JP")] ja_JP
}
```
Supported UI localization cultures using resource-based descriptions.
#### `T0Mode`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum T0Mode
{
[Description("DAS")] DAS = 0,
[Description("Test")] Test = 1
}
```
Defines T0 (time zero) reference mode for data acquisition.
#### `VelocityUnit`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum VelocityUnit
{
[Description("EditTestSetupObjectMeta_VelocityUnit_KilometerPerHour")] KilometerPerHour = 0,
[Description("EditTestSetupObjectMeta_VelocityUnit_MeterPerSecond")] MeterPerSecond = 1
}
```
Velocity measurement units with resource-key descriptions.
#### `ImportExtraStatus` / `PossibleStatus`
```csharp
public enum ImportExtraStatus { None, NormalizingIds, ReadingCalibrations, ReadingChannels, ReadingCustomerDetails, ReadingEngineerDetails, ReadingGroups, ReadingHardware, ReadingLabDetails, ReadingSensors, ReadingTestSetups, ReadingUsers, ReadingXML }
public enum PossibleStatus { Waiting, Working, Done, Failed, Reading, Importing }
```
Track import operation progress states.
#### `IsoViewMode`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum IsoViewMode
{
[Description("ISOOnly")] ISOOnly,
[Description("ISOAndUserCode")] ISOAndUserCode,
[Description("UserCodeOnly")] UserCodeOnly,
[Description("ChannelNameOnly")] ChannelNameOnly
}
```
Controls channel identification display mode in UI.
#### `PopupWindowImage`
```csharp
public enum PopupWindowImage { Warning = 0, Error = 1, Question = 2, Information = 3 }
```
Defines popup dialog icon types.
#### `UIItemStatus`
```csharp
public enum UIItemStatus { None, Success, Failed, Error, Warning }
```
Represents UI operation result states.
#### `DigitalOutputModes`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum DigitalOutputModes
{
[Description("Off")] NONE = 0,
[DescriptionResource("DigitalOutputMode_FVLH")] FVLH = 1 << 0,
[DescriptionResource("DigitalOutputMode_FVHL")] FVHL = 1 << 1,
[DescriptionResource("DigitalOutputMode_CCNO")] CCNO = 1 << 2,
[DescriptionResource("DigitalOutputMode_CCNC")] CCNC = 1 << 3
}
```
Bitwise flags for digital output channel configuration (5V transitions and contact closure modes).
#### `DigitalInputModes`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum DigitalInputModes
{
NONE = 1 << 0,
[DescriptionResource("DigitalInputMode_TLH")] TLH = 1 << 1,
[DescriptionResource("DigitalInputMode_THL")] THL = 1 << 2,
[DescriptionResource("DigitalInputMode_CCNO")] CCNO = 1 << 3,
[DescriptionResource("DigitalInputMode_CCNC")] CCNC = 1 << 4
}
```
Bitwise flags for digital input channel configuration (transition detection and contact closure modes).
#### `DataFlag`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum DataFlag
{
[Description("None")] None = 0,
[Description("Normal")] Normal = 1,
[Description("Saturated")] Saturated = 2,
[Description("Zero Crossing Error")] ZeroCrossing = 3,
[Description("Broken Wire")] BrokenWire = 4,
[Description("Other")] Other = -1
}
```
Data quality flags for channel samples. Note: `Other` has value -1.
#### `SquibMeasurementType` / `SquibFireMode`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum SquibMeasurementType { NONE = 0, CURRENT = 1 << 0, INIT_SIGNAL = 1 << 1, VOLTAGE = 1 << 2 }
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum SquibFireMode
{
NONE = 1 << 0,
[DescriptionResource("SquibFireMode_Cap")] CAP = 1 << 1,
[DescriptionResource("SquibFireMode_CC")] CONSTANT = 1 << 2,
AC = 1 << 3
}
```
Bitwise flags for squib (explosive initiator) configuration.
#### `SupportedExportFormatBitFlags`
```csharp
[Flags]
public enum SupportedExportFormatBitFlags
{
none = 0x0, csvunfiltered = 0x1, diademadc = 0x2, isounfiltered = 0x4,
somatunfiltered = 0x8, tdmsadc = 0x10, toyotaunfiltered = 0x20,
tsvunfiltered = 0x40, csvfiltered = 0x80, isofiltered = 0x200,
somatfiltered = 0x400, tdasadc = 0x800, toyotafiltered = 0x1000,
tsvfiltered = 0x2000, rdfadc = 0x4000, ChryslerDDAS = 0x8000,
HDFUnfiltered = 0x10000, HDFFiltered = 0x20000, HDFMV = 0x40000,
HDFADC = 0x80000, xlsxfiltered = 0x100000, xlsxunfiltered = 0x200000,
CSVADC = 0x400000, CSVMV = 0x800000, Ch10FilteredEU = 0x1000000,
Ch10UnfilteredEU = 0x2000000, FIATASC = 0x4000000
}
```
Bitwise flags for export format capabilities.
#### `UartBaudRate`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum UartBaudRate : uint
{
_110 = 110, _300 = 300, _600 = 600, _1200 = 1200, _2400 = 2400,
_4800 = 4800, _9600 = 9600, _14400 = 14400, _19200 = 19200,
_38400 = 38400, _57600 = 57600, _115200 = 115200, _230400 = 230400,
_460800 = 460800, _921600 = 921600
}
```
Standard UART baud rates with underlying `uint` values matching the rate.
#### `UDPStreamProfile`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum UDPStreamProfile : byte
{
RTCStreaming = 0, DTS_UDP = 1, CH10_MANUAL_CONFIG = 2,
CH10_PCM128_MM = 3, CH10_ANALOG = 4, CH10_PCM_STANDARD = 5,
CH10_PCM_SUPERCOM = 6, CH10_PCM_128BIT_2HDR = 7, CH10_ANALOG_2HDR = 8,
CH10_PCM_STANDARD_2HDR = 9, CH10_PCM_SUPERCOM_2HDR = 10,
TMNS_PCM_STANDARD = 11, TMNS_PCM_SUPERCOM = 12, IENA_PTYPE_STREAM = 13,
UART_STREAM = 14
}
```
UDP streaming profiles for SLICE6A devices, supporting Chapter 10, TmNS, and IENA formats.
#### `RecordingModes`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum RecordingModes
{
CircularBuffer, Recorder, HybridRecorder, S6A_DeviceStreamingOnly,
CircularBufferPlusUART, RecorderPlusUART, MultipleEventCircularBuffer,
MultipleEventRecorder, ContinuousRecorder, RecorderAndStreamSubSample,
CircularBufferAndStreamSubSample, Active, MultipleEventActive,
MultipleEventHybridRecorder, Streaming, Scheduled, Interval,
MultipleEventCircularBufferPlusUART, MultipleEventRecorderPlusUART,
ContinuousRecorderPlusUART, RAMActive, MultipleEventRAMActive,
RecordOnBoot, RecordOnBootPlusUART, MultipleEventHybridAndStream,
HybridAndStream, MultipleEventCircularBufferAndStream,
MultipleEventRecorderAndStream
}
```
DAS recording mode configurations.
#### `ApplicationStatusTypes`
```csharp
public enum ApplicationStatusTypes
{
IDLE, SettingConfiguration, ClearingFlash, Arm, AutoArmPrepare,
WaitingForStart, WaitingForTrigger, WaitingForStartWithEvent,
WaitingForTriggerCheck, WaitingForAutoArm, WaitingForStreaming,
Passed, FailedStart, FailedTrigger, Done, FailedArm, FailedDisarm,
// ... (50+ additional states)
}
```
Comprehensive application state machine values for DAS operations.
#### `FtssHeaderLine` / `XLSXExportHeaderLine`
```csharp
public enum FtssHeaderLine
{
[Description("Headers")] Headers = 0,
[Description("Test Date")] TestDate,
[Description("Test Time")] TestTime,
// ... (additional header fields)
[Description("Time of T0 (UTC)")] Timestamp,
[Description("Data Starts Here")] DataStart,
[Description("Time")] Labels
}
```
Defines CSV/XLSX export header line content with localized descriptions.
#### `StreamDigitalFilterTypes`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum StreamDigitalFilterTypes
{
NO_DSP_FILTER = 0,
CH10_IIR_6TH_OPTION_80X = 5,
CH10_FIR_45T65T_OPTION_80X = 6,
ALL_RT_IIR_6TH_OPTION_80X = 13,
ALL_RT_FIR_45T65T_OPTION_80X = 14
}
```
DSP filter profiles for S6A streaming (IIR/FIR options).
#### `CFCFilter`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum CFCFilter
{
[Description("None")] None = 0,
[Description("Unfiltered")] Unfiltered = -2,
[Description("CFC 10")] Class10 = 17,
[Description("CFC 60")] Class60 = 100,
[Description("CFC 180")] Class180 = 300,
[Description("CFC 600")] Class600 = 1000,
[Description("CFC 1000")] Class1000 = 1650
}
```
SAE CFC (Channel Filter Class) filter definitions per ISO 6487.
#### `ClockSyncProfile`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum ClockSyncProfile : byte
{
None = 0, Manual, Slave_E2E, Master_E2E, Auto_E2E,
Master_E2E_IRIG, Master_E2E_IRIG_EXT_PPS, Master_E2E_GPS,
Master_E2E_GPS_EXT_PPS, Master_E2E_EXT_PPS,
IRIG = 21, IRIG_EXT_PPS, GPS, GPS_EXT_PPS, EXT_PPS,
// ... (additional PPS output profiles)
}
```
PTP/IRIG/GPS clock synchronization profiles for distributed DAS systems.
#### `InputClockSource` / `OutputClockSource`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum InputClockSource : byte
{
None = 0, PTP = 1 << 0, IRIG = 1 << 1, GPS = 1 << 2, OnePPS = 1 << 3,
PTP_OnePPS = (1 << 0) | (1 << 3), IRIG_OnePPS = (1 << 1) | (1 << 3),
GPS_OnePPS = (1 << 2) | (1 << 3)
}
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum OutputClockSource : byte { /* bitwise combinations */ }
```
Bitwise clock source configuration for time synchronization.
### Classes and Static Members
#### `RibbonTabNames`
```csharp
public static class RibbonTabNames
{
public const string Tab1 = "TBD";
public const string Tab2 = "TBD";
public const string Tab3 = "TBD";
}
```
Placeholder constants for ribbon UI tab names (values not yet defined).
#### `IsoViewModeStatic`
```csharp
public abstract class IsoViewModeStatic
{
public static IsoViewMode ViewMode { get; set; }
}
```
Global static holder for ISO view mode across modules. Does not persist; must be set from database separately.
#### `SelectedItemsStatus`
```csharp
public abstract class SelectedItemsStatus
{
public static void SetUpdating(object o, bool updating);
public static bool GetUpdating(object o);
}
```
Thread-safe dictionary-based status tracking for UI update operations.
#### `EnumBindingSourceExtension`
```csharp
public class EnumBindingSourceExtension : MarkupExtension
{
public Type EnumType { get; set; }
public EnumBindingSourceExtension();
public EnumBindingSourceExtension(Type enumType);
public override object ProvideValue(IServiceProvider serviceProvider);
}
```
WPF markup extension for binding enums to UI controls. Supports nullable enums.
#### `ExcitationVoltageOptions`
```csharp
public class ExcitationVoltageOptions
{
public enum ExcitationVoltageOption { Undefined = 1, Volt2 = 2,

View File

@@ -0,0 +1,63 @@
---
source_files:
- Common/DTS.CommonCore/Enums/Channels/ChannelCodeType.cs
generated_at: "2026-04-17T16:38:59.797080+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "d62e91265181d499"
---
# Documentation: ChannelCodeType.cs
## 1. Purpose
This module defines the enumeration and constants for channel code types within the DTS system. It establishes a standardized distinction between ISO 13499-compliant channel codes and user-defined channel codes, providing both type identification (via the `ChannelCodeType` enum) and validation constraints (via length constants) for each code type.
---
## 2. Public Interface
### Class: `ChannelEnumsAndConstants`
**Namespace:** `DTS.Common.Enums.Channels`
#### Constants
| Name | Type | Value | Description |
|------|------|-------|-------------|
| `IsoCodeTypeString` | `string` | `"ISO 13499"` | String identifier for ISO-type channel codes |
| `UserCodeTypeString` | `string` | `"User"` | String identifier for user-defined channel codes |
| `ISO_CODE_LENGTH` | `int` | `16` | Fixed length for ISO channel codes |
| `USER_CODE_LENGTH` | `int` | `50` | Maximum length for user-defined channel codes |
#### Enum: `ChannelCodeType`
| Value | Description |
|-------|-------------|
| `ISO` | Represents ISO 13499-compliant channel codes |
| `User` | Represents user-defined channel codes |
---
## 3. Invariants
- ISO channel codes must have a fixed length of exactly **16 characters** (`ISO_CODE_LENGTH`).
- User-defined channel codes must not exceed **50 characters** (`USER_CODE_LENGTH`).
- A channel code type must be either `ISO` or `User`—no other values are defined in the enumeration.
- The string representation of ISO type is always `"ISO 13499"`; the string representation of User type is always `"User"`.
---
## 4. Dependencies
**This module depends on:**
- None (no imports or external references in source)
**What depends on this module:**
- Cannot be determined from source alone. The namespace `DTS.Common.Enums.Channels` suggests this is part of a core utilities library likely consumed by channel-related components throughout the system.
---
## 5. Gotchas
1. **Inconsistent naming convention:** Constants use mixed naming styles—`IsoCodeTypeString` uses PascalCase with "Iso" capitalized, while `ISO_CODE_LENGTH` uses SCREAMING_SNAKE_CASE. This may

View File

@@ -0,0 +1,50 @@
---
source_files:
- Common/DTS.CommonCore/Enums/Communication/CommunicationConstantsAndEnums.cs
generated_at: "2026-04-17T16:09:21.372435+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "d613cb9c5eb24602"
---
# Communication
### Purpose
This module defines communication operation outcomes and a callback contract for reporting communication status. It provides a standardized enumeration for tracking the success, failure, or timeout states of connect, disconnect, send, and receive operations, enabling consistent error handling and status reporting across the communication layer.
### Public Interface
**`CommunicationConstantsAndEnums`** (static class)
- Contains all communication-related enums and delegates.
**`CommunicationResult`** (enum)
- `ConnectOK` - Connection succeeded
- `ConnectFailed` - Connection attempt failed
- `ConnectTimeout` - Connection attempt timed out
- `DisconnectOK` - Disconnection succeeded
- `DisconnectFailed` - Disconnection attempt failed
- `DisconnectTimeout` - Disconnection attempt timed out
- `SendOK` - Send operation succeeded
- `SendFailed` - Send operation failed
- `SendTimeout` - Send operation timed out
- `ReceiveOK` - Receive operation succeeded
- `ReceiveFailed` - Receive operation failed
- `ReceiveTimeout` - Receive operation timed out
- `Canceled` - Operation was canceled
**`CommunicationCallback`** (delegate)
- Signature: `delegate bool CommunicationCallback(ICommunicationReport report)`
- Accepts an `ICommunicationReport` instance and returns a boolean result.
### Invariants
- The `CommunicationResult` enum values are implicitly ordered as defined; no explicit integer values are assigned.
- Each operation type (Connect, Disconnect, Send, Receive) has exactly three outcome variants: OK, Failed, and Timeout, plus a global `Canceled` state.
### Dependencies
- **Depends on**: `DTS.Common.Interface.Communication.ICommunicationReport` (used in delegate signature)
- **Depended on by**: Not determinable from source alone
### Gotchas
- None identified from source alone.
---

View File

@@ -0,0 +1,473 @@
---
source_files:
- Common/DTS.CommonCore/Enums/DASFactory/WakeupTriggers.cs
- Common/DTS.CommonCore/Enums/DASFactory/UseCasesTSRAIR.cs
- Common/DTS.CommonCore/Enums/DASFactory/S6DBDiagnosticChannelList.cs
- Common/DTS.CommonCore/Enums/DASFactory/ConstantsAndEnums.cs
- Common/DTS.CommonCore/Enums/DASFactory/DFConstantsAndEnums.cs
generated_at: "2026-04-17T15:37:22.946695+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "ef8ddd30e450a408"
---
# Documentation: DTS.Common.Enums.DASFactory
## 1. Purpose
This module provides the core enumerations, constants, and utility extension methods for the DASFactory (Data Acquisition System Factory) component of the DTS system. It defines hardware device identifiers (`DASType`), recording modes, module types, diagnostic channel mappings, command status codes, fault flags, and various operational constants used throughout the data acquisition pipeline. The module serves as a central contract for hardware-specific identifiers and operational parameters, enabling consistent communication between the host software and DTS recording hardware.
---
## 2. Public Interface
### Enumerations
#### `WakeupTriggers`
**File:** `WakeupTriggers.cs`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum WakeupTriggers
{
[Description("WakeupTriggers_MotionDetect")]
MotionDetect,
}
```
Defines wakeup trigger types for device power management. Currently supports only `MotionDetect`.
---
#### `UseCasesTSRAIR : byte`
**File:** `UseCasesTSRAIR.cs`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum UseCasesTSRAIR : byte
{
AEROSPACE,
AEROSPACE_with_motion,
VIBRATION,
SCHEDULED,
INTERVAL,
STREAMING,
PRETRIGGER_TEST,
}
```
Defines TSR AIR device use case configurations.
---
#### `S6DBDiagnosticChannelList`
**File:** `S6DBDiagnosticChannelList.cs`
```csharp
public enum S6DBDiagnosticChannelList
{
InputVoltage = 0,
BackupVoltage = 1,
TemperatureC = 2,
BatterySoc = 3,
DiagInputVoltage = 100,
DiagMcuTemperature = 101,
DiagChargerPower = 102,
DiagChargerInputCurrent = 103,
DiagEnv_1_Temperature = 104,
DiagEnv_1_Humidity = 105,
// ... (continues through DiagBatteryThermistor2Temperature = 119)
}
```
Maps diagnostic channel identifiers for SLICE6DB hardware. Values 0-3 match legacy Base channels; values 100+ are DB-specific diagnostic channels.
---
#### `DASType`
**File:** `ConstantsAndEnums.cs` and `DFConstantsAndEnums.cs` (defined in both)
```csharp
public enum DASType
{
NONE,
HID_SLICE,
WINUSB_SLICE,
G5,
SIM,
TOM,
DIM,
TSR,
HEADS,
MINIDAU,
ETHERNET_SLICE,
ETHERNET_RIBEYE,
SLICE_DB,
TSR2,
ETHERNET_TDAS,
CDCUSB_SLICE,
ETHERNET_SLICE2,
WINUSB_SLICE1_5,
ETHERNET_SLICE1_5,
ETHERNET_SLICE6,
ETHERNET_SLICE6AIR,
WINUSB_SLICE6,
WINUSB_SLICE6AIR,
ETHERNET_SLICE6DB,
SERIAL_TDAS,
// Additional values in DFConstantsAndEnums.cs:
ETHERNET_POWERPRO,
ETHERNET_TSR_AIR,
ETHERNET_SLICE6DB3,
WINUSB_TSR_AIR,
ETHERNET_SLICEPRODB,
WINUSB_SLICE6AIR_BR,
ETHERNET_SLICE6AIR_BR,
}
```
Identifies DAS device types. **Note:** This enum is defined in both `ConstantsAndEnums.cs` and `DFConstantsAndEnums.cs` with the latter containing additional values.
---
#### `VoltageStatusColor`
**File:** `ConstantsAndEnums.cs` and `DFConstantsAndEnums.cs` (defined in both)
```csharp
public enum VoltageStatusColor
{
Green,
Red,
Yellow,
Off
}
```
Represents voltage status indicator colors.
---
#### `RecordingMode`
**File:** `DFConstantsAndEnums.cs`
```csharp
public enum RecordingMode
{
InvalidArmMode = 0,
CircularBuffer = 1,
RecorderMode = 2,
AutoCircularBufferMode = 4,
AutoRecorderMode = 5,
ImmediateMode = 0x06,
HighPowerRecorderMode = 0x07,
LowPowerRecorderMode = 0x08,
ContinuousRecorderMode = 0x09,
HybridRecorderMode = 0x0A,
MultiHybridRecorderMode = 0x0B,
RAMActive = 0x0C,
MultipleEventRAMActive = 0x0D,
a14_NormalRecorderAndStreamSubSampleMode = 0x0E,
// ... (many additional modes through 0x28)
}
```
Defines all available recording modes for DAS units. Values are protocol-level identifiers sent to firmware.
---
#### `ModuleType`
**File:** `DFConstantsAndEnums.cs`
```csharp
public enum ModuleType
{
SliceBridge,
SliceARS,
G5Analog,
G5Digital,
ProSIM,
ProTOM,
ProDIM,
RibeyeLED,
SLICEIEPE,
// ... (many additional module types)
StreamIn
}
```
Identifies different hardware module types that can be connected to a DAS unit.
---
#### `ConfigMode`
**File:** `DFConstantsAndEnums.cs`
```csharp
public enum ConfigMode
{
Disabled,
Normal,
DummyArm,
Clock,
UART,
StreamOut,
StreamIn,
}
```
Determines how each channel is handled when the DAS unit arms.
---
#### `CommandStatus`
**File:** `DFConstantsAndEnums.cs`
```csharp
public enum CommandStatus
{
StatusNoError = 0x00,
StatusInvalidParameter,
// ... (many status codes organized by category)
StatusArmInvalidSampleRate = 0x30,
StatusFlashEraseError = 0x10,
// ... through StatusNoResponse
}
```
Defines command execution status codes returned from firmware.
---
#### `FaultFlags` (Flags enum)
**File:** `DFConstantsAndEnums.cs`
```csharp
[Flags]
public enum FaultFlags
{
IncomingStatusLineDropped = 1 << 0,
ADCBufferOverrun = 1 << 1,
FlashCRCError = 1 << 2,
// ... (through NO_DATA = 1 << 13)
}
```
Legacy SLICE 1 ARM status fault flags.
---
#### `QATSExtendedFault` (Flags enum)
**File:** `DFConstantsAndEnums.cs`
Extended fault flags for S6DB, S6DB-3, TSAIR, and SPDB hardware.
---
#### `MultiCastDeviceClasses` (Flags enum)
**File:** `DFConstantsAndEnums.cs`
Bitwise device class identifiers used in UDP broadcast responses from devices.
---
#### `ProtocolLimitedCommands`
**File:** `DFConstantsAndEnums.cs`
Enumerates commands that may be protocol-limited (not supported on all firmware versions).
---
#### `TiltAxes`
**File:** `DFConstantsAndEnums.cs`
48 possible 3-axis assignments for SLICE6 bubble level tilt feature.
---
#### `TMAT_TEMPLATES`
**File:** `DFConstantsAndEnums.cs`
TMAT template identifiers with associated file name metadata attributes.
---
### Constants
#### `ConstantsAndEnums.cs`
```csharp
public const int EVENT_NUMBER_PRETEST_DIAG = -1;
public const int EVENT_NUMBER_POSTTEST_DIAG = -2;
public const int EVENT_NUMBER_MEASURE_BRIDGE = -3;
```
#### `DFConstantsAndEnums.cs` (selected constants)
```csharp
public const int TSR_AIR_HIGH_G_CUTOFF_RATE_SPS = 500;
public const byte ArmStateIdle = 0;
public const string MADEUPEVENT_TESTID = "__MadeUp__";
public const string NO_CONFIGURATION = "NO_CONFIGURATION";
public const string TOMSWITCH_ARMED = "TOMSAFETY_ARMED";
public const string SAFETYSWITCH_EXCEPTION = "SAFETYSWITCH_EXCEPTION";
public const string CHANNEL_SEPARATOR = "_";
public const string SERIAL_SEPARATOR = "-";
public const int CHANNEL_X = 0;
public const int CHANNEL_Y = 1;
public const int CHANNEL_Z = 2;
public const int CHANNEL_TEMPERATURE = 0;
public const int CHANNEL_HUMIDITY = 1;
public const int CHANNEL_PRESSURE = 2;
public const int SCHEDULE_AHEAD_IN_MINUTES = 2;
public const int High_g_Linear_1_Index = 3;
public const int High_g_Linear_2_Index = 4;
public const int High_g_Linear_3_Index = 5;
public const int WSAEISCONN = 0X2748;
public static readonly DateTime FIRST_USE_DATE_NOT_SET = (DateTime)System.Data.SqlTypes.SqlDateTime.MinValue;
public static readonly int[] TSRAIR_ValidSampleRates = { 100, 500, 1000, 5000, 10000, 15000, 20000 };
```
---
### Static Properties
**File:** `DFConstantsAndEnums.cs`
```csharp
public static bool AlwaysShowUnsignedADC = false;
public static int OneShotWaitTimeMs = 3000;
public static string TemperatureLogTimeFormat { get; set; } = "MM-dd-yyyy HH:mm:ss";
public static string TemperatureLogValueFormat { get; set; } = "N2";
public static bool UseDropDownForTestObjectAndPosition { get; set; } = false;
public static bool AllowEnableFaultCheckingOnS6DB { get; set; } = true;
public static double TDASRemoveOffsetWeighting { get; set; } = 1D;
public static double TDASShuntEmulationWeighting { get; set; } = .5D;
public static int ExpectedMaxTDASDiagnosticRunTimePerChannelMS { get; set; } = 8000;
public static bool UseUDPForAutoArmATDMonitor { get; set; } = false;
public static bool ExtraCommunicationLogging { get; set; } = false;
public static int ReceiveBufferSizeBytes { get; set; } = 65536;
public static int SendBufferSizeBytes { get; set; } = 65536;
public static uint RemoteKeepAliveSeconds { get; set; } = 60;
public static uint RemoteKeepAliveRetryIntervalSeconds { get; set; } = 5;
public static uint LocalKeepAliveTimeOutMS { get; set; } = 5000;
public static uint LocalKeepAliveRetryIntervalMS = 1000;
public static int HeartbeatAsyncConnectTimeoutMS = 10000;
public static int WaitTimeBetweenUnitConnects = 100;
public static bool DontDoSDL { get; set; } = false;
public static string RealtimeUDPAddress { get; set; } = "UDP://239.1.2.10:8400";
public static int UDP_RECEIVE_TIMEOUT = 10000;
```
---
### Methods
#### `IsSLICE6ERFirmware(string firmwareVersion)`
**File:** `DFConstantsAndEnums.cs`
```csharp
public static bool IsSLICE6ERFirmware(string firmwareVersion)
```
Returns `true` if the firmware version string indicates an Ethernet Digital Recorder (EDR). Parses firmware version tokens and checks for "G1" or "G3" prefixes per the SLICE Base Types specification.
---
### Extension Methods (`RecordingModeExtensions`)
**File:** `DFConstantsAndEnums.cs`
```csharp
public static bool UsesTestLength(RecordingModes mode)
```
Returns `true` if the recording mode uses test length for timing.
```csharp
public static bool IsTSRAIROnlyRecordingMode(RecordingModes mode)
```
Returns `true` for modes exclusive to TSR AIR: `Active`, `MultipleEventActive`, `Scheduled`, `Interval`.
```csharp
public static bool IsTSRAirRecordingMode(RecordingModes mode)
```
Returns `true` for modes allowed on TSR AIR devices.
```csharp
public static bool SupportsT0Correction(DFConstantsAndEnums.RecordingMode recordingMode)
```
Returns `true` for circular buffer and hybrid recorder modes.
```csharp
public static RecordingModes ToRecordingModes(DFConstantsAndEnums.RecordingMode recordingMode)
public static RecordingModes ToRecordingModesAlt(DFConstantsAndEnums.RecordingMode mode)
public static DFConstantsAndEnums.RecordingMode FromRecordingModes(this RecordingModes recordingMode)
```
Converts between `DFConstantsAndEnums.RecordingMode` and `RecordingModes` enum types.
```csharp
public static bool IsACircularBufferMode(DFConstantsAndEnums.RecordingMode mode)
public static bool IsACircularBufferMode(RecordingModes mode)
```
Returns `true` for circular buffer variants.
```csharp
public static bool IsARecorderMode(DFConstantsAndEnums.RecordingMode mode)
public static bool IsARecorderMode(RecordingModes mode)
```
Returns `true` for recorder mode variants.
```csharp
public static bool IsAHybridRecorderMode(DFConstantsAndEnums.RecordingMode mode)
public static bool IsAHybridRecorderMode(RecordingModes mode)
```
Returns `true` for hybrid recorder modes.
```csharp
public static bool DoesModeSupportAutoArm(RecordingModes mode)
```
Returns `true` if the mode supports auto-arm functionality.
```csharp
public static bool IsAMultipleEvent(RecordingModes mode)
public static bool CanBeAMultipleEvent(RecordingModes mode)
```
Returns `true` for multiple-event recording modes.
```csharp
public static bool IsAStreamMode(RecordingModes mode)
public static bool IsAStreamMode(DFConstantsAndEnums.RecordingMode mode)
```
Returns `true` for streaming modes.
```csharp
public static bool TestWillBeStreaming(RecordingModes recordingMode, bool streaming)
```
Returns `true` if the test will be streaming (checks both mode and streaming flag).
```csharp
public static bool IsAUartMode(RecordingModes mode)
public static bool IsAUartMode(DFConstantsAndEnums.RecordingMode mode)
```
Returns `true` for UART-enabled recording modes.
```csharp
public static bool IsAnOpenEndedRecordingMode(RecordingModes mode)
public static bool IsAnOpenEndedRecordingMode(DFConstantsAndEnums.RecordingMode mode)
```
Returns `true` for modes with no set recording time or post-trigger time.
---
## 3. Invariants
- **Event number ranges:** Diagnostic event numbers are negative integers (`EVENT_NUMBER_PRETEST_DIAG = -1`, `EVENT_NUMBER_POSTTEST_DIAG = -2`, `EVENT_NUMBER_MEASURE_BRIDGE = -3`).
- **Channel indices:** Axis channels are 0-indexed (`CHANNEL_X = 0`, `CHANNEL_Y = 1`, `CHANNEL_Z = 2`).
- **Diagnostic channel numbering:** Legacy Base channels use values 0-3; DB-specific diagnostic channels start at 100.
- **RecordingMode values:** Enum values are protocol-level identifiers with specific hex values that must match firmware expectations.
- **Flags enums:** `TempLogChannelBits`, `FaultFlags`, `MultiCastDeviceClasses`, and `QATSExtendedFault` are bitfield enums intended for bitwise operations.
- **TSR AIR sample rates:** Valid sample rates are constrained to the values in `TSRAIR_ValidSampleRates` array: 100, 500, 1000, 5000, 10000, 15000, 20000 SPS.
- **RecordingMode equivalence:** `RecordingMode.AutoActiveMode` and `RecordingMode.Aerospace` share the same value (0x1D) by design.
---
## 4. Dependencies
### This module depends on:
- `DTS.Common.Base.Classes` - Base class infrastructure
- `DTS.Common.Converters` - `EnumDescriptionTypeConverter` for enum description handling
- `DTS.Common.Behaviors` - `StringMetaDataAttr` attribute used in `TMAT_TEMPLATES`
- `System.ComponentModel` - `DescriptionAttribute`, `TypeConverterAttribute`
- `System.Collections.Generic` - `HashSet`, `Dictionary`, `IReadOnlyDictionary`
- `System.Linq` - LINQ extension methods
- `System.Data.SqlTypes` - `SqlDateTime.MinValue` for `FIRST_USE_DATE_NOT_SET`
### What depends on this module:
Cannot be determined from source alone. This module appears to be a foundational types library that would be referenced by DASFactory implementation classes, hardware communication layers, and UI components that need to display or configure device parameters.
---
## 5. Gotchas
1. **Duplicate enum definitions:** `DASType` and `VoltageStatusColor` are defined in both `ConstantsAndEnums.cs` and `DFConstantsAndEnums.cs`. The version in `DFConstantsAndEnums.cs` contains additional values. Consumers should verify which version they are referencing.
2. **RecordingMode value collision:** `RecordingMode.AutoActiveMode` and `RecordingMode.Aerospace` both equal `0x1D`. The source comment states: "not sure why this is duplicated here [AutoActiveMode = AeroSpace] but both have the same value. I'll just preserve it for now since I want to avoid any side effects."
3. **Static field state management:** The comment on `AlwaysShowUnsignedADC` states: "this property only holds the value of the attribute and does not store or retrieve it." Similarly, `UseDropDownForTestObjectAndPosition` "does not query database, so property must be set and maintained separately." These static properties require external lifecycle management.
4. **Incomplete documentation:** Several `RecordingMode` values have comments of "???" indicating unclear purpose: `ImmediateMode`, `HighPowerRecorderMode`, `LowPowerRecorderMode`, `ContinuousRecorderMode`, `HybridRecorderMode`, `MultiHybridRecorderMode`.
5. **Internal display modes:** Some `RecordingMode` values (0x17-0x1C) are marked as "internal to the OBR-DDR" and "don't show up in the UI."
6. **Firmware version parsing assumption:** `IsSLICE6ERFirmware` assumes firmware version strings follow a specific tokenized format with a 4-character final token. Behavior is undefined for malformed inputs.
7. **External reference tracking:** Multiple constants reference external bug/feature tracking numbers (e.g., "17567", "29796", "18090", "15575") that may provide context but are not accessible from source alone.

View File

@@ -0,0 +1,30 @@
---
source_files:
- Common/DTS.CommonCore/Enums/DBExport/TestObjectFields.cs
- Common/DTS.CommonCore/Enums/DBExport/CustomDirectionFields.cs
- Common/DTS.CommonCore/Enums/DBExport/CustomFinLoc2Fields.cs
- Common/DTS.CommonCore/Enums/DBExport/CustomFinLoc1Fields.cs
- Common/DTS.CommonCore/Enums/DBExport/CustomFinLoc3Fields.cs
- Common/DTS.CommonCore/Enums/DBExport/CustomFilterFields.cs
- Common/DTS.CommonCore/Enums/DBExport/PositionFields.cs
- Common/DTS.CommonCore/Enums/DBExport/MainLocationFields.cs
- Common/DTS.CommonCore/Enums/DBExport/PhysicalDimensionFields.cs
- Common/DTS.CommonCore/Enums/DBExport/TopLevelFields.cs
generated_at: "2026-04-17T16:03:09.382231+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "b6ddcd5a7a148c81"
---
# DBExport
### 1. Purpose
This module defines a set of public enumerations that serve as schemas for database export and import operations. It maps database fields for various domain entities—such as Test Objects, Locations (Fine and Main), Directions, Positions, and Physical Dimensions—to strongly typed constants. These enums likely facilitate serialization, XML tagging, or DataRow-to-Object mapping within the DTS system, ensuring consistent field naming when interacting with the underlying data store or external ISO-compatible components.
### 2. Public Interface
The module exposes the following enumerations:
* **`enum TestObjectFields`**: Defines fields for test objects.
* Values: `s_GUID`, `TEST_OBJECT`, `TEXT_L1`, `TEXT_L2`, `VERSION`, `DATE`, `REMARKS`, `EXPIRED`, `SORTKEY`, `LAST_CHANGE`, `LAST_CHANGE_TEXT`, `HISTORY`.
* **`enum CustomDirectionFields`**: Defines fields for `ISODll.MMEDirection`.
* Values: `Direction`, `Expired`, `History

View File

@@ -0,0 +1,86 @@
---
source_files:
- Common/DTS.CommonCore/Enums/DTS.Viewer/ChartOptions/TimeUnitType.cs
- Common/DTS.CommonCore/Enums/DTS.Viewer/ChartOptions/FilterOption.cs
- Common/DTS.CommonCore/Enums/DTS.Viewer/ChartOptions/YRangeScale.cs
- Common/DTS.CommonCore/Enums/DTS.Viewer/ChartOptions/WakeMethodType.cs
- Common/DTS.CommonCore/Enums/DTS.Viewer/ChartOptions/ChartUnitType.cs
generated_at: "2026-04-17T16:34:18.274852+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "17f23c64b5cf1df1"
---
# Documentation: Chart Options Enums
## 1. Purpose
This module defines a set of enumeration types used for configuring chart display options in the DTS Viewer component. These enums control time unit representation, data filtering, Y-axis scaling, device wake methods, and chart unit types. They are designed for integration with the Xceed WPF Toolkit PropertyGrid, providing both programmatic enum values and user-facing display strings via `Description` attributes.
---
## 2. Public Interface
### TimeUnitTypeEnum
**Namespace:** `DTS.Common.Enums.Viewer`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum TimeUnitTypeEnum
```
| Member | Value | Description |
|--------|-------|-------------|
| `MS` | 0 | "ms" - Milliseconds |
| `Seconds` | 1 | "Seconds" |
---
### TimeUnitTypeItemSource
**Namespace:** `DTS.Common.Enums.Viewer`
```csharp
public class TimeUnitTypeItemSource : IItemsSource
```
| Method | Return Type | Description |
|--------|-------------|-------------|
| `GetValues()` | `ItemCollection` | Returns a list of `TimeUnitTypeEnum` values for PropertyGrid dropdowns via `EnumUtil.GetValuesList<TimeUnitTypeEnum>()` |
---
### FilterOptionEnum
**Namespace:** `DTS.Common.Enums.Viewer`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum FilterOptionEnum
```
| Member | Value | Description |
|--------|-------|-------------|
| `Unfiltered` | 0 | "Unfiltered" |
| `TestSetupDefault` | 1 | "Test Setup Default" |
| `Custom` | 2 | "Custom" |
---
### FilterOptionEnumItemSource
**Namespace:** `DTS.Common.Enums.Viewer`
```csharp
public class FilterOptionEnumItemSource : IItemsSource
```
| Method | Return Type | Description |
|--------|-------------|-------------|
| `GetValues()` | `ItemCollection` | Returns a list of `FilterOptionEnum` values via `EnumUtil.GetValuesList<FilterOptionEnum>()` |
---
### YRangeScaleEnum
**Namespace:** `DTS.Common.Enums.Viewer`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum YRangeScale

View File

@@ -0,0 +1,17 @@
---
source_files:
- Common/DTS.CommonCore/Enums/DTS.Viewer/Filter/SearchEnum.cs
generated_at: "2026-04-17T16:08:31.229189+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "c1355309c7e0a5e8"
---
# Filter
### Purpose
This module defines the `FilterEnum` enumeration, which distinguishes between filter contexts within the DTS Viewer component. It provides a simple categorization for filtering operations, differentiating between Test and Graph filter types.
### Public Interface
**`enum

View File

@@ -0,0 +1,84 @@
---
source_files:
- Common/DTS.CommonCore/Enums/DTS.Viewer/Reports/PowerSpectralDensity/WindowAveragingType.cs
- Common/DTS.CommonCore/Enums/DTS.Viewer/Reports/PowerSpectralDensity/PassFilterType.cs
- Common/DTS.CommonCore/Enums/DTS.Viewer/Reports/PowerSpectralDensity/WindowWidth.cs
- Common/DTS.CommonCore/Enums/DTS.Viewer/Reports/PowerSpectralDensity/WindowType.cs
generated_at: "2026-04-17T16:34:44.658125+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "693ffc5f875269f1"
---
# Power Spectral Density Enumerations Documentation
## 1. Purpose
This module defines four enumeration types used for configuring Power Spectral Density (PSD) report generation within the DTS Viewer system. These enums provide strongly-typed configuration options for FFT (Fast Fourier Transform) windowing parameters, including window function type, window size, averaging method, and filter type. All enums are decorated with `TypeConverter` and `Description` attributes to support user-friendly display in UI components.
---
## 2. Public Interface
### `WindowAveragingType`
**Namespace:** `DTS.Common.Enums.Viewer.Reports`
Defines the spectral averaging method applied during PSD analysis.
| Member | Description Attribute | Implicit Value |
|--------|----------------------|----------------|
| `Averaging` | "Averaging" | 0 |
| `PeakHoldMax` | "Peak Hold MAX" | 1 |
| `PeakHoldMin` | "Peak Hold MIN" | 2 |
---
### `PassFilterType`
**Namespace:** `DTS.Common.Enums.Viewer.Reports`
Defines the analog filter approximation type used in signal processing.
| Member | Description Attribute | Implicit Value |
|--------|----------------------|----------------|
| `Bessel` | "Bessel" | 0 |
| `Butterworth` | "Butterworth" | 1 |
| `Chebyshev` | "Chebyshev" | 2 |
---
### `WindowWidth`
**Namespace:** `DTS.Common.Enums.Viewer.Reports`
Defines the FFT window size (number of samples). Values are explicitly assigned to match their numeric representation.
| Member | Description Attribute | Explicit Value |
|--------|----------------------|----------------|
| `FiveTwelve` | "512" | 512 |
| `TenTwentyFour` | "1024" | 1024 |
| `TwentyFortyEight` | "2048" | 2048 |
| `FortyNinetySix` | "4096" | 4096 |
| `EightyOneNinetyTwo` | "8192" | 8192 |
---
### `WindowType`
**Namespace:** `DTS.Common.Enums.Viewer.Reports`
Defines the window function applied to the signal before FFT transformation.
| Member | Description Attribute | Implicit Value |
|--------|----------------------|----------------|
| `Rectangle` | "Rectangle" | 0 |
| `Hamming` | "Hamming" | 1 |
| `Hanning` | "Hanning" | 2 |
| `Blackman` | "Blackman" | 3 |
| `BlackmanHarris` | "Blackman-Harris" | 4 |
| `FlatTop` | "Flat Top" | 5 |
---
## 3. Invariants
- All four enums are decorated with `[TypeConverter(typeof(EnumDescriptionTypeConverter))]`, indicating they are intended for UI binding where the `Description` attribute value should be displayed rather than the enum member name.
- `WindowWidth` members have explicit integer values that are always powers of 2 (512, 1024, 2048, 4096, 8192), suitable for FFT algorithms.
- `WindowWidth` values are strictly increasing

View File

@@ -0,0 +1,18 @@
---
source_files:
- Common/DTS.CommonCore/Enums/DTS.Viewer/TestMetadata/ChannelGroups.cs
- Common/DTS.CommonCore/Enums/DTS.Viewer/TestMetadata/TestGraphsFields.cs
- Common/DTS.CommonCore/Enums/DTS.Viewer/TestMetadata/TestSetupFields.cs
- Common/DTS.CommonCore/Enums/DTS.Viewer/TestMetadata/TestRunMetadataFields.cs
- Common/DTS.CommonCore/Enums/DTS.Viewer/TestMetadata/TestModuleFields.cs
- Common/DTS.CommonCore/Enums/DTS.Viewer/TestMetadata/TestChannelFields.cs
generated_at: "2026-04-17T16:22:17.505152+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "9fe8117654f84538"
---
# TestMetadata
### Purpose
This module defines strongly-typed enumerations that serve as field identifiers for parsing,

View File

@@ -0,0 +1,13 @@
---
source_files:
- Common/DTS.CommonCore/Enums/Database/DbType.cs
generated_at: "2026-04-17T16:39:03.755353+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "9ce7aa6428961cfb"
---
# Documentation: `DTS.Common.Enums.Database.DbType`
## 1. Purpose
This module defines the `DbType` enumeration, which specifies the database

View File

@@ -0,0 +1,74 @@
---
source_files:
- Common/DTS.CommonCore/Enums/GroupTemplates/GroupTemplateChannelFields.cs
- Common/DTS.CommonCore/Enums/GroupTemplates/GroupTemplateFields.cs
generated_at: "2026-04-17T16:37:01.677534+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "8d4381d6f54274f5"
---
# Documentation: Group Template Field Enums
## 1. Purpose
This module defines two enumeration types within the `DTS.Common.Enums.GroupTemplates` namespace that serve as field identifiers for group template entities and their associated channels. These enums provide strongly-typed constants for referencing specific fields, likely used in data mapping, validation, serialization, or UI binding scenarios where field names need to be referenced programmatically rather than via magic strings.
---
## 2. Public Interface
### `GroupTemplateChannelFields`
**Namespace:** `DTS.Common.Enums.GroupTemplates`
Defines field identifiers for channel objects within group templates.
| Member | Implicit Value |
|--------|----------------|
| `Required` | 0 |
| `Name` | 1 |
| `ISOCode` | 2 |
| `Custom` | 3 |
| `DisplayOrder` | 4 |
---
### `GroupTemplateFields`
**Namespace:** `DTS.Common.Enums.GroupTemplates`
Defines field identifiers for group template entities.
| Member | Implicit Value |
|--------|----------------|
| `Name` | 0 |
| `Description` | 1 |
| `Channels` | 2 |
| `LastModifiedBy` | 3 |
| `LastModified` | 4 |
| `AssociatedGroups` | 5 |
---
## 3. Invariants
- Both enums use implicit integer backing values starting at 0, incrementing by 1 for each subsequent member.
- The `Name` member exists in both enums but represents different entities and has different implicit values (`1` in `GroupTemplateChannelFields`, `0` in `GroupTemplateFields`).
- All enum members are `public` by default (standard C# enum member visibility).
---
## 4. Dependencies
**Dependencies (what this module imports):**
- None. These are self-contained enum definitions with no external references.
**Dependents (what depends on this module):**
- Unknown from source alone. Consumers would reference the `DTS.Common.Enums.GroupTemplates` namespace to use these field identifiers.
---
## 5. Gotchas
- **Member name collision:** `Name` exists in both enums. Code referencing these values must use the fully-qualified type or disambiguate via the enum type to avoid confusion.
- **Implicit value ordering:** The implicit integer values differ for semantically similar fields. For example, `Name` is value `1` in `GroupTemplateChannelFields` but `0` in `GroupTemplateFields`. Any serialization or persistence logic relying on these integer values should account for this.
- **No explicit values defined:** Neither enum explicitly assigns values to members. Refactoring (adding, removing, or reordering members) could break any code or stored data that depends on the implicit integer values.

View File

@@ -0,0 +1,13 @@
---
source_files:
- Common/DTS.CommonCore/Enums/Groups/GroupImport.cs
generated_at: "2026-04-17T16:39:22.780687+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "06d8fd51cf37a800"
---
# Documentation: GroupImportEnums
## 1. Purpose
This module defines the `Steps` enumeration used to track the progression of a group import workflow. It encapsulates the stages of the import process within the `GroupImportEnums` abstract container class, providing strongly-typed state management for

View File

@@ -0,0 +1,40 @@
---
source_files:
- Common/DTS.CommonCore/Enums/Groups/GroupList/GroupFields.cs
generated_at: "2026-04-17T16:08:31.227396+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "7fad27458f4f959c"
---
# GroupList
### Purpose
This module defines the `GroupFields` enumeration, which specifies the standard field names for Group entities within the DTS system. It provides a type-safe way to reference group properties, likely used for data binding, sorting, filtering, or display column configuration in group listing views. The enum supports localized display names via `Description` attributes.
### Public Interface
**`enum GroupFields`**
- A public enum decorated with `[TypeConverter(typeof(EnumDescriptionTypeConverter))]` to enable conversion between enum values and their string descriptions.
- **Values:**
- `Name` — Description key: "GroupField_Name"
- `DisplayName` — Description key: "GroupField_DisplayName"
- `Description` — Description key: "GroupField_Description"
- `ChannelCount` — Description key: "GroupField_ChannelCount"
- `LastModified` — Description key: "GroupField_LastModified"
- `LastModifiedBy` — Description key: "GroupField_LastModifiedBy"
- `AssociatedTestSetups` — Description key: "GroupField_AssociatedTestSetups"
### Invariants
- Each enum value has an associated `[Description]` attribute containing a localization resource key (not a display string directly).
- The underlying integer values follow default C# enum behavior (starting at 0, incrementing by 1).
### Dependencies
- **Depends on:** `DTS.Common.Converters.EnumDescriptionTypeConverter` (for type conversion), `System.ComponentModel` (for `TypeConverter` and `Description` attributes).
- **Depended on by:** Not determinable from source alone; likely consumed by Group listing/view components.
### Gotchas
- The `Description` attribute values (e.g., "GroupField_Name") appear to be localization keys, not human-readable strings. Consumers must resolve these via a localization mechanism.
- Unlike `TestSetupFields`, this enum uses `Description` attributes and a custom `TypeConverter`, suggesting different display handling patterns across the codebase.
---

View File

@@ -0,0 +1,153 @@
---
source_files:
- Common/DTS.CommonCore/Enums/Hardware/HardwareListTags.cs
- Common/DTS.CommonCore/Enums/Hardware/SLICEConfigurations.cs
- Common/DTS.CommonCore/Enums/Hardware/HardwareTypes.cs
generated_at: "2026-04-17T15:39:37.643124+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "b97b7d2daf9e6693"
---
# Documentation: DTS.Common.Enums.Hardware
## 1. Purpose
This module defines the core hardware enumeration types and utility functions for the DTS (Data Acquisition System) hardware platform. It provides a centralized definition of hardware device types (`HardwareTypes`), SLICE configurations, hardware list metadata tags, and an abstract `HardwareConstants` class containing static helper methods for querying hardware capabilities such as recording mode support, streaming profiles, clock synchronization, trigger inversion support, and embedded sensor detection. This module serves as the canonical reference for hardware type identification and capability resolution across the system.
---
## 2. Public Interface
### Enums
#### `HardwareListTags`
Defines metadata tags used to identify hardware list properties.
```csharp
public enum HardwareListTags
{
Included,
SerialNumber,
HardwareType,
ChannelCount,
Firmware,
MaxSampleRate,
TestSampleRate,
CalDate,
CalDueDate,
IPAddress,
FirstUseDate
}
```
#### `SLICEConfigurations`
Defines SLICE hardware sample rate configurations. Decorated with `[TypeConverter(typeof(EnumDescriptionTypeConverter))]`.
```csharp
public enum SLICEConfigurations
{
[Description("SLICE_CONFIGURATION_MEGA")]
MEGA,
[Description("SLICE_CONFIGURATION_800K")]
EIGHT_HUNDRED,
[Description("SLICE_CONFIGURATION_700K")]
SEVEN_HUNDRED,
[Description("SLICE_CONFIGURATION_600K")]
SIX_HUNDRED
}
```
#### `HardwareTypes`
Defines all supported hardware device types with explicit integer values. Decorated with `[TypeConverter(typeof(EnumDescriptionTypeConverter))]`. Contains 59 defined values (0-58, with gaps at 22 and 35).
Key values include:
- `SLICE_Base = 0` through `SLICE6_AIR_BR = 58`
- `UNDEFINED = 38` - Represents unknown/empty hardware type
- Various SLICE variants, TDAS equipment, embedded sensor modules, and specialty hardware
#### `SLICEBridgeTypes`
Defines bridge module types. Decorated with `[TypeConverter(typeof(EnumDescriptionTypeConverter))]`.
```csharp
public enum SLICEBridgeTypes
{
[Description("BRIDGETYPE_BRIDGE_DESCRIPTION")]
Bridge,
[Description("BRIDGETYPE_IEPE_DESCRIPTION")]
IEPE,
[Description("BRIDGETYPE_ARS_DESCRIPTION")]
ARS,
[Description("BRIDGETYPE_ACC_DESCRIPTION")]
ACC,
[Description("BRIDGETYPE_RTC_DESCRIPTION")]
RTC,
[Description("BRIDGETYPE_UART_DESCRIPTION")]
UART,
[Description("BRIDGETYPE_STREAM_OUT_DESCRIPTION")]
StreamOut
}
```
#### `RackSizes`
Defines rack size configurations. Decorated with `[TypeConverter(typeof(EnumDescriptionTypeConverter))]`.
```csharp
public enum RackSizes
{
[Description("RACK_SIZE_4M")]
FOUR,
[Description("RACK_SIZE_8M")]
EIGHT
}
```
### HardwareConstants Class
Abstract class providing static utility methods and constants for hardware capability queries.
#### Constants
```csharp
public const int INVALID_IDASCOMMUNICATION_RECORD_ID = -1;
public const int DEFAULTMEMORYSIZE_PRO = 16000000;
public const int DEFAULTMEMORYSIZE_DIM = 2000000;
public const int DEFAULTMEMORYSIZE_TOM = 2000000;
```
#### Properties
```csharp
public static bool AllowSoftDisconnects { get; set; } = false;
```
Global configuration for allowing soft disconnects; must be set by the application.
#### Methods
```csharp
public static SolidColorBrush GetBrushForVoltageStatus(DFConstantsAndEnums.VoltageStatusColor status)
```
Returns a `SolidColorBrush` corresponding to the voltage status color (Green, Red, Yellow, Off).
```csharp
public static bool SupportsTriggerInversion(HardwareTypes type, int protocolVersion)
```
Returns `true` if the hardware type supports trigger inversion. Supports SLICE, SLICE1.5, SLICE2 variants.
```csharp
public static bool SupportsStartInversion(HardwareTypes type, int protocolVersion)
```
Returns `true` if the hardware type supports start inversion. Supports SLICE, SLICE1.5, SLICE2 variants, and `SLICE6_AIR`.
```csharp
public static bool IsEthernetRecorder(HardwareTypes type)
```
Returns `true` if the hardware type is `S6A_EthernetRecorder`.
```csharp
public static bool HasEmbeddedSensors(HardwareTypes hardware)
```
Returns `true` for embedded sensor hardware types (`EMB_*` series, `TSR_AIR`, `TSR_AIR_RevB`, `DIR`, `DKR`).
```csharp
public static bool HasEmbeddedChannelType(HardwareTypes hardware, string channelType)
```
Determin

View File

@@ -0,0 +1,25 @@
---
source_files:
- Common/DTS.CommonCore/Enums/Reports/ReportConstantsAndEnums.cs
generated_at: "2026-04-17T16:38:59.428727+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "0ce66b15a5017737"
---
# Documentation for ReportConstantsAndEnums.cs
## 1. Purpose
This file defines the namespace `DTS.Common.Enums.Reports` and is intended to serve as a central location for constants and enumerations related to the reporting subsystem. However, the source code currently contains no types or members; the namespace block is empty.
## 2. Public Interface
**None.**
The namespace `DTS.Common.Enums.Reports` is currently empty. There are no public classes, structs, enums, or functions defined in this file.
## 3. Invariants
None identified from source alone. The file contains no logic or data structures to enforce constraints.
## 4. Dependencies
* **Imports:** The file imports `System`, `System.Collections.Generic`, `System.Linq`, `System.Text`, and `System.Threading.Tasks`.
* *Note:* Because the namespace is empty, all imported namespaces are currently unused.
* **Consumers:** Cannot

View File

@@ -0,0 +1,314 @@
---
source_files:
- Common/DTS.CommonCore/Enums/Sensors/SensorChangeTypes.cs
- Common/DTS.CommonCore/Enums/Sensors/SensorStatus.cs
- Common/DTS.CommonCore/Enums/Sensors/PossibleFilters.cs
- Common/DTS.CommonCore/Enums/Sensors/LinearizationFormula.cs
- Common/DTS.CommonCore/Enums/Sensors/CalibrationEnforcement.cs
- Common/DTS.CommonCore/Enums/Sensors/CalibrationBehaviors.cs
- Common/DTS.CommonCore/Enums/Sensors/InitialOffsetTypes.cs
- Common/DTS.CommonCore/Enums/Sensors/FilterClassType.cs
- Common/DTS.CommonCore/Enums/Sensors/ZeroMethodType.cs
- Common/DTS.CommonCore/Enums/Sensors/CSVImportTags.cs
- Common/DTS.CommonCore/Enums/Sensors/SensorConstants.cs
generated_at: "2026-04-17T15:32:07.953285+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "dc5ee5fbfa705d3b"
---
# DTS.Common.Enums.Sensors Module Documentation
## 1. Purpose
This module provides the core enumerations, constants, and utility methods for sensor configuration and management within the DTS system. It defines sensor lifecycle states, calibration behaviors and enforcement policies, filter class types (CFC standards), zero calculation methods, CSV import/export field definitions with versioning support, and various sensor-related constants including default values, bridge types, and sensitivity units. The module serves as the foundational type system for sensor-related operations across the application.
---
## 2. Public Interface
### Enums
#### `SensorChangeTypes`
```csharp
public enum SensorChangeTypes { OffsetTolerance }
```
Defines types of sensor changes. Currently only `OffsetTolerance` is defined.
#### `SensorStatus`
```csharp
public enum SensorStatus { Available, InUse, OutForService, OutForCalibration, Retired }
```
Defines the lifecycle states of a sensor.
#### `PossibleFilters`
```csharp
public enum PossibleFilters { All, Analog, Squib, DigitalIn, DigitalOut, UART, StreamOut, StreamIn }
```
Describes different ways of filtering channels and sensors by type.
#### `NonLinearStyles`
```csharp
public enum NonLinearStyles { IRTraccManual, IRTraccDiagnosticsZero, IRTraccZeroMMmV, IRTraccAverageOverTime, Polynomial, IRTraccCalFactor }
```
Defines non-linear calibration styles.
#### `NonLinearSLICEWareStyles`
```csharp
public enum NonLinearSLICEWareStyles { Manual, DiagnosticZeroMMmV, ZeroMMmV, AverageOverTime, Polynomial }
```
Defines non-linear calibration styles specific to SLICEWare.
#### `CalibrationEnforcement`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum CalibrationEnforcement { None, NonLinear, Linear }
```
Defines calibration enforcement policies. Uses `EnumDescriptionTypeConverter` for display string conversion.
#### `CalibrationBehaviors`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum CalibrationBehaviors { LinearIfAvailable, NonLinearIfAvailable, UseBothIfAvailable }
```
Defines how calibration data should be applied.
#### `InitialOffsetTypes`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum InitialOffsetTypes { None = 0, EU = 1, EUAtMV = 2, LHS = 3, RHS = 4, FRONTAL = 5 }
```
Defines the format of initial offset values.
#### `FilterClassType`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum FilterClassType
```
Defines SAE filter class types with associated frequencies:
| Member | Value | Notes |
|--------|-------|-------|
| `None` | 0 | Code = P unless `UseZeroForUnfiltered` is True, then Code = 0 |
| `AdHoc` | -1 | |
| `Unfiltered` | -2 | Code = 0 |
| `CFC10` | 17 | 17 Hz |
| `CFC60` | 100 | 100 Hz; Code = D |
| `CFC180` | 300 | 300 Hz; Code = C |
| `CFC600` | 1000 | 1000 Hz; Code = B |
| `CFC1000` | 1650 | 1650 Hz; Code = A |
#### `ZeroMethodType`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum ZeroMethodType { AverageOverTime = 0, UsePreEventDiagnosticsZero = 1, None = 2 }
```
Defines methods for calculating electrical zero.
#### `OriginalZeroMethodType`
```csharp
public enum OriginalZeroMethodType { AverageOverTime, UsePreCalZero, None }
```
Original version of zero method types for legacy compatibility.
#### `SensorConstants.SensorSettings`
```csharp
public enum SensorSettings
```
Defines sensor setting identifiers including `Range`, `CFC`, `Polarity`, `Position`, `OutputMode`, `SQMode`, `DIMode`, `ZeroMethod`, `FilterClass`, `UartBaudRate`, `StreamOutUDPProfile`, `ACCouplingEnabled`, `BridgeType`, and others.
#### `SensorConstants.SensorType`
```csharp
public enum SensorType { Analog, DigitalIn, DigitalOut, Squib, Clock, UART, StreamOut, StreamIn }
```
#### `SensorConstants.SensUnits`
```csharp
public enum SensUnits { NONE = 0, mV = 1, mVperV = 2, mVperVperEU = 3, mVperEU = 4 }
```
Defines sensitivity unit types.
#### `SensorConstants.BridgeType`
```csharp
public enum BridgeType
```
Defines bridge/sensor setup types as bit flags: `IEPE`, `QuarterBridge`, `HalfBridge`, `FullBridge`, `DigitalInput`, `SQUIB`, `TOMDigital`, `HalfBridge_SigPlus`, `RTC`, `UART`, `StreamOut`, `StreamIn`.
#### `SensorConstants.SensorCalPolicy`
```csharp
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
public enum SensorCalPolicy { AllowAlways, DONT_ALLOW }
```
Defines how to handle sensors with out-of-date calibrations.
#### `SensorConstants.CouplingModes`
```csharp
public enum CouplingModes { AC = 0, DC }
```
#### `SensorConstants.AvailableRangesLowG` / `AvailableRangesARS`
Enums defining valid ranges for TSR AIR LowG and ARS channels.
---
### CSVImportTags Class
```csharp
public abstract class CSVImportTags
```
#### Constants
```csharp
public const int MIN_VALID_VERSION = 0;
public const int MAX_VALID_VERSION = 6;
```
#### Methods
```csharp
public static bool IsSensorTag(int version)
```
Returns `true` if the version is in the sensor tags versions set (0, 2, 3, 4).
```csharp
public static Tags[] GetVersionTags(int version)
```
Returns all tags for a given CSV import version. Returns empty array if version not found.
```csharp
public static string GetStringForTag(Tags tag)
```
Returns the display string for a given tag.
```csharp
public static Tags GetTagForString(string s)
```
Returns the tag for a given display string. Returns `Tags.Unknown` if not found.
```csharp
public static int GetVersionForTag(Tags t)
```
Returns the version a tag was introduced in. Returns `int.MaxValue` if not found.
#### Nested Enum: `Tags`
Defines 100+ CSV import/export fields with `[Display(Name = "...")]` and `[Version(int)]` attributes indicating when each field was introduced.
---
### SensorConstants Class
```csharp
public abstract class SensorConstants
```
#### Constants
- `VOLTAGE_INSERTION_UNIT`, `TSRAIR_ACCEL_UNIT`, `TSRAIR_ARS_UNIT`, `TSRAIR_TEMPERATURE_UNIT`, `TSRAIR_HUMIDITY_UNIT`, `TSRAIR_PRESSURE_UNIT` - Unit strings
- `DEGREES`, `DEGREE_ANGLE` - Degree unit strings
- `MIN_BRIDGE_RESISTANCE_OHMS` (1), `MAX_BRIDGE_RESISTANCE_OHMS` (32000)
- `SENSOR_FIRST_USE_DEFAULT` (false)
- `SQUIB_DELAY_CONSTANT`, `SQUIB_LIMIT_DURATION_CONSTANT`, `SQUIB_DURATION_CONSTANT`, `SQUIB_LOW_TOLERANCE_CONSTANT`, `SQUIB_HIGH_TOLERANCE_CONSTANT`, `SQUIB_FIREMODE_CONSTANT`, `SQUIB_CURRENT_CONSTANT`
- `DIGITALOUT_MODE_CONSTANT`, `DIGITALOUT_DELAY_CONSTANT`, `DIGITALOUT_LIMITDURATION_CONSTANT`, `DIGITALOUT_DURATION_CONSTANT`
- `UART_BAUDRATE_CONSTANT` (57600), `UART_DATABITS_CONSTANT` (8), `UART_STOPBITS_CONSTANT`, `UART_PARITY_CONSTANT`, `UART_FLOWCONTROL_CONSTANT`, `UART_DATAFORMAT_CONSTANT`
- `STREAMIN_ADDRESS_CONSTANT`, `STREAMOUT_PROFILE_CONSTANT`, `STREAMOUT_ADDRESS_CONSTANT`, `STREAMOUT_TIME_CHID_CONSTANT`, `STREAMOUT_DATA_CHID_CONSTANT`, `STREAMOUT_TMNS_CONFIG_CONSTANT`, `STREAMOUT_IRIG_TDP_INTERVAL_CONSTANT`
- `LinearValuesSeparator` ("||")
- Test-specific prefixes: `TEST_SPECIFIC_DOUT`, `TEST_SPECIFIC_SQUIB`, `TEST_SPECIFIC_DIN`, `TEST_SPECIFIC_EMB`, `TEST_SPECIFIC_EMB_CLK`, `TEST_SPECIFIC_UART`, `TEST_SPECIFIC_STREAM_OUT`, `TEST_SPECIFIC_STREAM_IN`
#### Static Properties (Cached/Mutable)
- `δThorax`, `δAbdomen`, `D0Thorax`, `D0Abdomen`, `δThoraxLower`, `D0ThoraxLower` - 3D IR-TRACC equation values
- `UseSensorFirstUseDate`, `UseISOCodeFilterMapping`
- `DefaultZeroMethodType`, `DefaultZeroMethodStart`, `DefaultZeroMethodEnd`
- `DefaultRangeHiG`, `DefaultRangeLowG`, `DefaultRangeLowGDisplay`, `DefaultRangeARS`, `DefaultRangeTemperature`, `DefaultRangeHumidity`, `DefaultRangePressure`
- `SensorCalOutOfDateWarningPeriodDays`, `SensorCalPolicyCurrent`
- `DisableAutoSense`
- `DefaultBridgeOffsetMVTolLow`, `DefaultBridgeOffsetMVTolHigh`, `DefaultIEPEOffsetMVTolLow`, `DefaultIEPEOffsetMVTolHigh`
#### Static Methods
```csharp
public static bool IsTestSpecificDigitalOut(string sn)
public static bool IsTestSpecificSquib(string sn)
public static bool IsTestSpecificDigitalIn(string sn)
public static bool IsTestSpecificEmbedded(string sn)
public static bool IsTestSpecificEmbeddedClock(string sn)
public static bool IsTestSpecificStreamOut(string sn)
public static bool IsTestSpecificStreamIn(string sn)
public static bool IsTestSpecificUart(string sn)
```
Check if a serial number belongs to a test-specific sensor type.
```csharp
public static BridgeType ConvertIntToBridgeType(int bridge)
public static int ConvertBridgeToInt(BridgeType bridge)
```
Convert between integer and `BridgeType` enum. Note: integer mapping is not the bitmask value.
```csharp
public static bool IsTSRAirHighGChannel(string moduleSerialNumber)
public static bool IsTSRAirLowGChannel(string moduleSerialNumber)
public static bool IsTSRAirARSChannel(string moduleSerialNumber)
public static bool IsTSRAirAtmChannel(string moduleSerialNumber)
public static bool IsTSRAirHumidityChannel(string moduleSerialNumber, int channelNumber)
```
Identify TSR AIR channel types by module serial number suffix.
---
### SensUnitStringConverter (Nested Class)
```csharp
public abstract class SensUnitStringConverter
{
public static SensUnits ConvertFromString(string s)
}
```
Converts string representations to `SensUnits`. Accepts formats: "none", "mv", "mv/v", "mvperv", "mv/v/eu", "mvpervpereu", "mv/eu", "mvpereu". Throws `InvalidCastException` for unrecognized strings.
---
## 3. Invariants
- **CSV Version Range**: Valid CSV import versions are 0-6 (`MIN_VALID_VERSION` to `MAX_VALID_VERSION`).
- **Sensor Tag Versions**: Only versions 0, 2, 3, 4 are considered sensor tag versions (checked by `IsSensorTag`).
- **ZeroMethodType Values**: The order and explicit values of `ZeroMethodType` enum must be preserved for legacy compatibility (e.g., importing GM ISF).
- **Bridge Resistance Range**: Valid bridge resistance is between `MIN_BRIDGE_RESISTANCE_OHMS` (1) and `MAX_BRIDGE_RESISTANCE_OHMS` (32000).
- **ARS Range Limits**: `ARSMin` = 250, `ARSMax` = 2000.
- **LowG Range Limits**: `LowGMin` = 8, `LowGMax` = 64.
- **TSR AIR Channel Numbers**: Temperature = 9, Humidity = 10, Pressure = 11.
- **Thread Safety**: `CSVImportTags` lookup methods use locking (`MY_LOCK`) for thread-safe lazy initialization.
---
## 4. Dependencies
### This module depends on:
- `System` (core types, `Enum`, `InvalidCastException`)
- `System.ComponentModel` (`TypeConverter`, `DescriptionAttribute`)
- `System.ComponentModel.DataAnnotations` (`DisplayAttribute`)
- `System.IO.Ports` (`StopBits`, `Parity`, `Handshake`)
- `System.Collections.Generic` (`Dictionary`, `HashSet`, `List`)
- `System.Linq` (`Enumerable` extensions)
- `DTS.Common.Converters` (`EnumDescriptionTypeConverter`)
- `DTS.Common.Attributes` (`VersionAttribute`, `DisplayAttribute` - inferred from usage pattern)
- `DTS.Common.Base.Classes` (inferred from `DescriptionResourceAttribute` usage)
### What depends on this module:
Cannot be determined from source alone. This is a foundational enums/constants module likely used throughout the DTS system.
---
## 5. Gotchas
1. **ZeroMethodType Enum Ordering**: The comment explicitly states: "Lots of legacy compatibility (e.g. importing GM ISF) depends on the order/value of this enum." Do not reorder or reassign values.
2. **"Original Defaults" vs Database Defaults**: Constants like `SQUIB_DELAY_CONSTANT`, `SQUIB_HIGH_TOLERANCE_CONSTANT`, etc. represent "original" defaults for restore functionality, NOT necessarily the current database defaults. The comments state: "represents the _original_ default... (not the default in the db)".
3. **Bridge Type Integer Conversion**: `ConvertBridgeToInt` and `ConvertIntToBridgeType` do NOT use the bitmask values for storage. The comment states: "this is apparently needed for historical reasons as the sensor db apparently doesn't use the bitmask value for storage?"
4. **Static Property Initialization**: Properties like `DefaultZeroMethodType`, `UseISOCodeFilterMapping`, `SensorCalPolicyCurrent` are cached values that must be set by the application on startup or when settings change. They do not serialize/deserialize automatically.
5. **FilterClassType.None Behavior**: The `None` value has special behavior: "Code = P unless UseZeroForUnfiltered is True, then Code = 0". The `UseZeroForUnfiltered` flag is not defined in this module.
6. **Squib High Tolerance Changed**: Per case 26826, `SQUIB_HIGH_TOLERANCE_CONSTANT` was raised from 8.0 to 10.0 ohms.
7. **Deprecated SensorSettings Values**: `LimitDuration`, `Duration`, `Delay` in `SensorSettings` enum are marked as "deprecated in 2.1".
8. **CSVImportTags Lookups**: The lookup dictionaries are lazily initialized on first access and protected by a lock. First call to any lookup method will trigger `PopulateLookups()`.

View File

@@ -0,0 +1,30 @@
---
source_files:
- Common/DTS.CommonCore/Enums/Sensors/SensorsList/DigitalInputFields.cs
- Common/DTS.CommonCore/Enums/Sensors/SensorsList/DigitalOutFields.cs
- Common/DTS.CommonCore/Enums/Sensors/SensorsList/SensorListTabs.cs
- Common/DTS.CommonCore/Enums/Sensors/SensorsList/UartSettingFields.cs
- Common/DTS.CommonCore/Enums/Sensors/SensorsList/SquibFields.cs
- Common/DTS.CommonCore/Enums/Sensors/SensorsList/StreamInSettingFields.cs
- Common/DTS.CommonCore/Enums/Sensors/SensorsList/StreamOutSettingFields.cs
- Common/DTS.CommonCore/Enums/Sensors/SensorsList/CACOption.cs
- Common/DTS.CommonCore/Enums/Sensors/SensorsList/AnalogSensorFields.cs
generated_at: "2026-04-17T16:02:00.657197+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "88a963f18588aa76"
---
# SensorsList
1. **Purpose**
This module defines a set of enumerations used to represent fields, settings, and configuration options for various sensor types within the DTS application. It provides strongly-typed identifiers for sensor attributes (e.g., `SerialNumber`, `Description`, `CalDate`) and tab indices for UI navigation, facilitating data binding, grid column mapping, and serialization logic for sensor lists including Analog, Squib, Digital I/O, UART, and Stream types.
2. **Public Interface**
* `enum DigitalInputFields`: Represents fields for digital input sensors. Values: `Included`, `SerialNumber`, `Description`, `Mode`, `ModifiedBy`, `LastModified`.
* `enum CanSettingFields`: Represents CAN bus configuration fields. Values: `CanIsFD`, `CanArbBaseBitrate`, `CanArbBaseSJW`, `CanDataBitrate`, `CanDataSJW`, `CanFileType`.
* `enum DigitalOutFields`: Represents fields for digital output sensors. Values: `Included`, `SerialNumber`, `Description`, `Delay`, `Duration`, `ModifiedBy`, `LastModified`.
* `enum SensorListTabs`: Represents the index of tabs in a sensor list UI. Values: `ANALOG` (0), `SQUIB` (1), `DIGITAL_IN` (2), `DIGITAL_OUT` (3), `UART` (4), `STREAM_IN` (5), `STREAM_OUT` (6).
* `enum UartSettingFields`: Represents UART configuration fields. Values: `Included`, `SerialNumber`, `BaudRate`, `DataBits`, `StopBits`, `Parity`, `FlowControl`, `DataFormat`, `LastModifiedBy`, `LastModified`.
* `enum SquibFields`: Represents fields for squib sensors. Values: `Included`, `SerialNumber`, `Description`, `ResistanceLow`, `ResistanceHigh`, `Id`, `Mode`, `Delay`, `Current`, `Duration`, `ModifiedBy`, `LastModified`.
* `enum Stream

View File

@@ -0,0 +1,15 @@
---
source_files:
- Common/DTS.CommonCore/Enums/SettingsExport/TopLevelFields.cs
generated_at: "2026-04-17T16:38:51.048562+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "1828e96646beb944"
---
# SettingsExport
## Documentation: `TopLevelFields.cs`
### 1. Purpose
This module defines the `TopLevelFields` enumeration within the `DTS.Common.Enums.SettingsExport` namespace. It provides a strongly-typed definition of valid root-level XML tags used during settings export operations. The enumeration constrains the top-level structure of the configuration XML to four specific categories: `GlobalSettings`, `TestSetupDefaultSettings`, `SensorSettings`, and `Test

View File

@@ -0,0 +1,20 @@
---
source_files:
- Common/DTS.CommonCore/Enums/SliceSimpleArm/SSACommands.cs
generated_at: "2026-04-17T16:38:55.388061+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "9955e959b81580a0"
---
# Documentation: SSACommands.cs
## 1. Purpose
This module defines the communication protocol vocabulary for the "SliceSimpleArm" subsystem within the `DTS.CommonCore` library. It provides two enumerations, `SSACommand` and `SSAResponse`, which standardize the instruction set sent to the hardware or subsystem and the status codes returned, ensuring type-safe interaction between the caller and the SliceSimpleArm device logic.
## 2. Public Interface
### `enum SSACommand`
Defines the specific operations that can be requested of the SliceSimpleArm device.
* **Members:**
* `ConfigureDevice`: Instruction to

View File

@@ -0,0 +1,15 @@
---
source_files:
- Common/DTS.CommonCore/Enums/TSRAIRGo/NavigationButtonId.cs
generated_at: "2026-04-17T16:38:38.460380+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "ec4149e7fd946e07"
---
# TSRAIRGo
## Documentation: `NavigationButtonId.cs`
### 1. Purpose
This module defines the `NavigationButtonId` enumeration within the `DTS.Common.Enums.TSRAIRGo` namespace. It provides a set of strongly

View File

@@ -0,0 +1,58 @@
---
source_files:
- Common/DTS.CommonCore/Enums/TTS/TTSEnums.cs
generated_at: "2026-04-17T16:52:23.961528+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "a183c0066bcc75c1"
---
# Documentation: TTSEnums.cs
## 1. Purpose
This module provides enumerations and a reflection-based attribute system for managing TTS (Toyota Test System) data import field definitions. It exists to track which fields in a Toyota import format are currently supported, deprecated, or removed—addressing issue 18396 where excessive columns caused confusion. The module defines field ordering, bridge types, and zero methods used in Toyota data acquisition configurations.
---
## 2. Public Interface
### `FieldSupportLevel` (enum)
Indicates the current support status for a field.
| Value | Description |
|-------|-------------|
| `RequiredParameter` | Field is actively required |
| `RemainedButNotUsed` | Field exists in schema but is not utilized |
| `RemovedParameter` | Field has been removed |
---
### `FieldSupportAttribute` (class)
Attribute for marking enum fields with their support level.
**Properties:**
- `FieldSupportLevel SupportLevel { get; set; }` — The support level assigned to the decorated field.
**Constructor:**
- `FieldSupportAttribute(FieldSupportLevel value)` — Constructs the attribute with the specified support level.
**Static Method:**
- `FieldSupportLevel GetSupportLevel(Enum genericEnum)` — Retrieves the `FieldSupportAttribute.SupportLevel` from an enum value via reflection. Returns `FieldSupportLevel.RemovedParameter` if no attribute is found or if the member info is unavailable.
---
### `ToyotaFieldOrder` (enum)
Defines the field ordering and support status for Toyota import columns. Values are explicitly numbered 032.
| Value | Integer | Support Level |
|-------|---------|---------------|
| `ChannelNumber` | 0 | RequiredParameter |
| `ChannelCode` | 1 | RequiredParameter |
| `JCodeOrDescription` | 2 | RequiredParameter |
| `ChannelRange` | 3 | RequiredParameter |
| `ChannelFilterHz` | 4 | RequiredParameter |
| `SensorID` | 5 | RemainedButNotUsed |
| `SensorSerialNumber` | 6 | RequiredParameter |
| `SensorSensitivity` | 7 | RemainedButNotUsed |
| `SensorExcitationVol

View File

@@ -0,0 +1,29 @@
---
source_files:
- Common/DTS.CommonCore/Enums/TestSetups/RealtimeGraphsEnum.cs
generated_at: "2026-04-17T16:09:21.373000+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "2598dae9bd481f7f"
---
# TestSetups
### Purpose
This module defines the allowed configurations for realtime graph display layouts. It provides a type-safe enumeration with description attributes for UI binding, supporting one, three, or six simultaneous graph views with explicit integer values matching the graph count.
### Public Interface
**`RealtimeGraphsEnum`** (enum)
- `[TypeConverter(typeof(EnumDescriptionTypeConverter))]` - Enables custom description-based conversion
- `One = 1` - Description: "RealtimeGraphs_One"
- `Three = 3` - Description: "RealtimeGraphs_Three"
- `Six = 6` - Description: "RealtimeGraphs_Six"
### Invariants
- The underlying integer value of each enum member corresponds to the number of graphs it represents (1, 3, or 6).
- Description attributes follow the naming pattern `RealtimeGraphs_<Name>`.
### Dependencies
- **Depends on**:
- `System

View File

@@ -0,0 +1,13 @@
---
source_files:
- Common/DTS.CommonCore/Enums/TestSetups/TestSetupsList/TestSetupFields.cs
generated_at: "2026-04-17T16:39:53.108378+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "151d2dd565cd5f83"
---
# Documentation: TestSetupFields.cs
## 1. Purpose
This module defines a standard enumeration, `TestSetupFields`, which serves as a strongly-typed list of property identifiers

View File

@@ -0,0 +1,122 @@
---
source_files:
- Common/DTS.CommonCore/Events/LoginUserEvent.cs
- Common/DTS.CommonCore/Events/TextPastedEvent.cs
- Common/DTS.CommonCore/Events/BusyIndicatorChangeNotification.cs
- Common/DTS.CommonCore/Events/ComActiveEvent.cs
- Common/DTS.CommonCore/Events/CloseApplicationRequested.cs
- Common/DTS.CommonCore/Events/TabControlSelectionChanged.cs
- Common/DTS.CommonCore/Events/RaiseNotification.cs
- Common/DTS.CommonCore/Events/PageSetActiveEvent.cs
- Common/DTS.CommonCore/Events/GroupTemplateChangeNotification.cs
- Common/DTS.CommonCore/Events/DatabaseVersionChangedEvent.cs
- Common/DTS.CommonCore/Events/SetSaveButton.cs
- Common/DTS.CommonCore/Events/DBConnectionEvent.cs
- Common/DTS.CommonCore/Events/AutomaticModeStatusEvent.cs
- Common/DTS.CommonCore/Events/SetPageVisibilityEvent.cs
- Common/DTS.CommonCore/Events/LogoutUserEvent.cs
- Common/DTS.CommonCore/Events/PageNameEvent.cs
- Common/DTS.CommonCore/Events/TestEvent.cs
- Common/DTS.CommonCore/Events/PageSelectionChanged.cs
- Common/DTS.CommonCore/Events/UserEvent.cs
- Common/DTS.CommonCore/Events/ListViewStatusEvent.cs
- Common/DTS.CommonCore/Events/HelpTextEvent.cs
- Common/DTS.CommonCore/Events/PageModifiedEvent.cs
- Common/DTS.CommonCore/Events/FeedbackEvent.cs
- Common/DTS.CommonCore/Events/AssemblyListNotification.cs
- Common/DTS.CommonCore/Events/CancelProcess.cs
- Common/DTS.CommonCore/Events/TabControlSelectionEventArgs.cs
- Common/DTS.CommonCore/Events/SLICE6MulticastPropertyEvent.cs
- Common/DTS.CommonCore/Events/AppStatusEvent.cs
- Common/DTS.CommonCore/Events/PageErrorEvent.cs
- Common/DTS.CommonCore/Events/PageNavigationRequestEvent.cs
- Common/DTS.CommonCore/Events/ProgressBarEvent.cs
- Common/DTS.CommonCore/Events/NotificationContentEventArgs.cs
- Common/DTS.CommonCore/Events/ShowStatus.cs
generated_at: "2026-04-17T15:26:58.440755+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "c17782c70c9f76dc"
---
# DTS.Common.Events Module Documentation
## 1. Purpose
This module defines the event aggregation layer for the DTS application using the Prism Framework's `CompositePresentationEvent<T>` pattern. It provides a loosely-coupled pub/sub messaging system enabling communication between application components without direct references. The events cover user authentication lifecycle, database connectivity, UI state management (busy indicators, save buttons, progress bars), page navigation and modification tracking, tab control operations, and hardware communication status (COM ports, SLICE6 multicast properties).
---
## 2. Public Interface
### Authentication Events
**`LoginUserEvent`** : `CompositePresentationEvent<LoginUserArg>`
- Published when a user logs in. Payload contains `UserName`.
**`LogoutUserEvent`** : `CompositePresentationEvent<LogoutUserArg>`
- Published when a user logs out. `LogoutUserArg.Reason` uses enum `Reasons` (value: `DatabaseSwitch`).
### Database Events
**`DBConnectionEvent`** : `CompositePresentationEvent<DBConnectionArg>`
- Notifies subscribers of database connection state changes.
- `DBConnectionArg` properties: `Connected` (bool), `DBName` (string), `Server` (string).
**`DatabaseVersionChangedEvent`** : `CompositePresentationEvent<DatabaseVersionChangedEventArgs>`
- Notifies subscribers when database version changes.
- `DatabaseVersionChangedEventArgs.Version` (string, defaults to `string.Empty`).
### Application Lifecycle Events
**`CloseApplicationRequested`** : `CompositePresentationEvent<object>`
- Published when application closure is requested.
**`AppStatusEvent`** : `CompositePresentationEvent<AppStatusArg>`
- Notifies application busy/available state.
- `AppStatusArg` enum values: `Busy`, `Available`, `Shutdown`, `Close`, `UserLogout`.
**`AppStatusExEvent`** : `CompositePresentationEvent<AppStatusExArg>`
- Extended app status with additional process name.
- `AppStatusExArg` properties: `Status` (AppStatusArg), `Name` (string).
**`BusyIndicatorChangeNotification`** : `CompositePresentationEvent<bool>`
- Controls busy indicator visibility. Payload is boolean state.
### UI Control Events
**`SetSaveButton`** : `CompositePresentationEvent<SaveButtonUsability>`
- Enables/disables save button.
- `SaveButtonUsability.IsUsable` (bool).
**`TabControlSelectionChanged`** : `CompositePresentationEvent<TabControlSelectionEventArgs>`
- Notifies tab control changes.
- `TabControlSelectionEventArgs` constructor: `(TabControlOperation operation, object item)`.
- Properties: `Operation`, `Item`.
**`SetPageHeaderVisibilityEvent`** : `CompositePresentationEvent<SetPageHeaderVisibilityEventArgs>`
- Controls page header visibility.
- Properties: `SetVisiblity` (bool), `Visibility` (System.Windows.Visibility).
**`ProgressBarEvent`** : `CompositePresentationEvent<ProgressBarEventArg>`
- Controls progress bar state.
- `ProgressBarEventArg` properties: `ProgressBarName`, `ProgressBarColor`, `SetPercentage`, `ProgressBarPercentage`, `SetText`, `ProgressBarText`, `SetVisibility`, `ProgressBarVisibility`.
- Default constructor sets `ProgressBarName` to `"Footer"`.
**`RaiseNotification`** : `CompositePresentationEvent<NotificationContentEventArgs>`
- Displays notification popup.
- `NotificationContentEventArgs` constructor: `(string message, string messageDetails = "", PopupWindowImage image = PopupWindowImage.Error, string title = "")`.
- Properties: `Message`, `MessageDetails`, `Image`, `Title`.
**`NotificationContentEventArgsWithoutTitle`**
- Variant without title property. Constructor: `(string message, string messageDetails = "", PopupWindowImage image = PopupWindowImage.Error)`.
### Page Events
**`PageSetActiveEvent`** : `CompositePresentationEvent<PageSetActiveEventArg>`
- Notifies when a page becomes active.
- `PageSetActiveEventArg.Page` (type: `IDataPROPage`).
**`PageNameEvent`** : `CompositePresentationEvent<PageNameEventArg>`
- Notifies page name updates.
- Constructor

View File

@@ -0,0 +1,55 @@
---
source_files:
- Common/DTS.CommonCore/Events/ChannelCodes/ChannelCodesViewChangedEvent.cs
- Common/DTS.CommonCore/Events/ChannelCodes/ChannelCodeCommittedEvent.cs
generated_at: "2026-04-17T16:37:05.716975+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "b761fbf8ad38db94"
---
# Documentation: Channel Code Events
## 1. Purpose
This module defines two Prism event types for the event aggregation system, enabling loosely-coupled communication between components regarding channel code operations. `ChannelCodesViewChangedEvent` notifies subscribers when the channel codes view mode changes, while `ChannelCodeCommittedEvent` broadcasts when channel codes are committed, carrying details about the committed codes and user permissions. These events follow the Prism CompositePresentationEvent pattern for pub/sub messaging within the DTS application.
---
## 2. Public Interface
### `ChannelCodesViewChangedEvent`
**Location:** `DTS.Common.Events` namespace
**Declaration:**
```csharp
public class ChannelCodesViewChangedEvent : CompositePresentationEvent<DTS.Common.Enums.IsoViewMode> { }
```
**Behavior:** An event class that publishes/subscribes to view mode changes. The payload is a single `DTS.Common.Enums.IsoViewMode` value indicating the new view mode.
---
### `ChannelCodeCommittedEvent`
**Location:** `DTS.Common.Events.ChannelCodes` namespace
**Declaration:**
```csharp
public class ChannelCodeCommittedEvent : CompositePresentationEvent<ChannelCodeCommittedEventArgs[]> { }
```
**Behavior:** An event class that publishes/subscribes to channel code commit notifications. The payload is an array of `ChannelCodeCommittedEventArgs` objects, allowing multiple codes to be committed in a single event.
---
### `ChannelCodeCommittedEventArgs`
**Location:** `DTS.Common.Events.ChannelCodes` namespace
**Properties:**
| Property | Type | Access |
|----------|------|--------|
| `ChannelCodeType` | `ChannelEnumsAndConstants.ChannelCodeType` | `public` getter, `private` setter |
| `Code` | `string` | `public` getter, `private` setter |
| `Name` | `string` | `public` getter, `private` setter |
| `CanUserCommitChannelCodes` | `bool` | `public` getter, `private` setter |
**Constructor:**
```csharp
public ChannelCodeCommittedEventArgs(
ChannelEnumsAndConstants.ChannelCodeType channelCode

View File

@@ -0,0 +1,49 @@
---
source_files:
- Common/DTS.CommonCore/Events/DASFactory/DASConfigurationEvent.cs
generated_at: "2026-04-17T16:39:24.799726+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "e793e8752d6c6ffb"
---
# Documentation: DASConfigurationEvent
## 1. Purpose
`DASConfigurationEvent` is a Prism-based event class used to publish and subscribe to DAS (Data Acquisition System) configuration notifications within the system. It exists to decouple configuration notification logic, specifically to alert consumers when blank or missing configurations are detected. According to the source comments, its current scope is limited to notifying about blank or missing configurations, particularly in the context of emergency downloads with DAS units that have blank filestore(s).
## 2. Public Interface
### `DASConfigurationEvent` (class)
**Namespace:** `DTS.Common.Events.DASFactory`
**Inheritance:** `CompositePresentationEvent<IDASConfigurationArg>`
**Signature:**
```csharp
public class DASConfigurationEvent : CompositePresentationEvent<IDASConfigurationArg> { }
```
**Behavior:** This is a marker class that inherits from Prism's `CompositePresentationEvent<T>` with a generic payload type of `IDASConfigurationArg`. It defines no additional members; all functionality (Subscribe, Publish, etc.) is provided by the base class. It is intended to be used with Prism's `IEventAggregator` for loosely-coupled event publication and subscription.
## 3. Invariants
- The event payload must always be an object implementing `IDASConfigurationArg`.
- This class cannot be instantiated or used without a Prism `IEventAggregator` instance (implied by inheritance from `CompositePresentationEvent<T>`).
- The event is designed specifically for configuration-related notifications within the DASFactory domain.
## 4. Dependencies
**This module depends on:**
- `DTS.Common.Interface.DASFactory` — provides the `IDASConfigurationArg` interface used as the event payload type.
- `Microsoft.Practices.Prism.Events` — provides the `CompositePresentationEvent<T>` base class for the pub/sub event pattern.
**What depends on this module:**
- Not determinable from the source file alone. Consumers would typically be other modules that subscribe to or publish this event via `IEventAggregator`.
## 5. Gotchas
- **Limited scope:** The XML comment explicitly states this event is "currently only used to notify when blank or missing configurations occur." Developers should not assume it handles all configuration change scenarios.
- **Historical context:** The comment references issue/ticket "17872" regarding emergency downloads with DAS units having blank filestore(s). This suggests the event was introduced for a specific use case and may have narrow applicability.
- **No custom implementation:** The class body is empty; all behavior comes from the base class. Any payload validation or transformation must occur before publishing or after subscribing, not within this class.

View File

@@ -0,0 +1,60 @@
---
source_files:
- Common/DTS.CommonCore/Events/DTS.Viewer/Reports/SaveReportToCSVRequestedEvent.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/Reports/SaveReportToPDFRequestedEvent.cs
generated_at: "2026-04-17T16:37:24.004362+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "82218c788c94f519"
---
# Documentation: Report Export Events
## 1. Purpose
This module defines two Prism event aggregation events for requesting report exports in the DTS Viewer application. `SaveReportToCSVRequestedEvent` and `SaveReportToPDFRequestedEvent` enable loosely-coupled communication between components that trigger report exports and the handlers that process them, following the event aggregator pattern from the Prism library.
## 2. Public Interface
### `SaveReportToCSVRequestedEvent`
**Signature:** `public class SaveReportToCSVRequestedEvent : CompositePresentationEvent<SaveReportToCSVRequestedEventArgs>`
A composite presentation event that, when published, signals a request to export a report to CSV format. Subscribers receive a `SaveReportToCSVRequestedEventArgs` payload.
---
### `SaveReportToCSVRequestedEventArgs`
**Signature:** `public class SaveReportToCSVRequestedEventArgs`
Payload class containing data for CSV export requests.
| Property | Type | Description |
|----------|------|-------------|
| `Directory` | `string` | Target directory path for the exported file. |
| `ParentVM` | `IBaseViewModel` | Reference to the parent view model initiating the request. |
---
### `SaveReportToPDFRequestedEvent`
**Signature:** `public class SaveReportToPDFRequestedEvent : CompositePresentationEvent<SaveReportToPDFRequestedEventArgs>`
A composite presentation event that, when published, signals a request to export a report to PDF format. Subscribers receive a `SaveReportToPDFRequestedEventArgs` payload.
---
### `SaveReportToPDFRequestedEventArgs`
**Signature:** `public class SaveReportToPDFRequestedEventArgs`
Payload class containing data for PDF export requests.
| Property | Type | Description |
|----------|------|-------------|
| `Directory` | `string` | Target directory path for the exported file. |
| `ParentVM` | `IBaseViewModel` | Reference to the parent view model initiating the request. |
---
## 3. Invariants
- Both event classes inherit from `CompositePresentationEvent<T>`, requiring subscribers to handle the corresponding `EventArgs` type.
- The `Directory` property is expected to contain a

View File

@@ -0,0 +1,46 @@
---
source_files:
- Common/DTS.CommonCore/Events/DTS.Viewer/Reports/PowerSpectralDensity/PSDReportGRMSValuesUpdatedEvent.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/Reports/PowerSpectralDensity/PSDReportSettingsChangedEvent.cs
generated_at: "2026-04-17T16:24:44.542867+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "39fc236fad6b3b49"
---
# PowerSpectralDensity
### Purpose
This module defines Prism event aggregation types for communicating changes related to Power Spectral Density (PSD) reports. It provides two event classes—`PSDReportGRMSValuesUpdatedEvent` and `PSDReportSettingsChangedEvent`—that enable loosely-coupled publication and subscription of PSD report state changes across the application, particularly for GRMS (G-RMS, likely Root Mean Square acceleration) value updates and settings model changes.
### Public Interface
**`PSDReportGRMSValuesUpdatedEvent`**
- Inherits from `CompositePresentationEvent<PSDReportGRMSValuesUpdatedEventArg>`
- No additional members; serves as a typed event carrier for the Prism EventAggregator
**`PSDReportGRMSValuesUpdatedEventArg`**
- `IChannelGRMSSummary[] Values` — Array of GRMS summary values (getter/setter)
- `IBaseViewModel ParentVM` — Reference to the parent view model (getter/setter)
**`PSDReportSettingsChangedEvent`**
- Inherits from `CompositePresentationEvent<PSDReportSettingsChangedEventArg>`
- No additional members; serves as a typed event carrier for the Prism EventAggregator
**`PSDReportSettingsChangedEventArg`**
- `IPSDReportSettingsModel Model` — The PSD report settings model (getter/setter)
- `IBaseViewModel ParentVM` — Reference to the parent view model (getter/setter)
### Invariants
- Event argument properties (`Values`, `Model`, `ParentVM`) are publicly settable with no null validation in the source; consumers should not assume non-null values.
- The `Values` array in `PSDReportGRMSValuesUpdatedEventArg` may be empty but should not be assumed sorted or filtered.
### Dependencies
- **Depends on:** `DTS.Common.Base` (for `IBaseViewModel`), `DTS.Common.Interface` (for `IChannelGRMSSummary`, `IPSDReportSettingsModel`), `Microsoft.Practices.Prism.Events` (for `CompositePresentationEvent<T>`)
- **Dependents:** Unknown from source alone; likely consumed by PSD report view models and related UI components.
### Gotchas
- The event argument classes use mutable auto-properties with no constructor initialization. Callers must ensure all required properties are set before publishing.
- The `ParentVM` property appears in both event argument types, suggesting a pattern where event handlers may need to communicate back to the originating view model, but the exact usage pattern is unclear from source alone.
---

View File

@@ -0,0 +1,83 @@
---
source_files:
- Common/DTS.CommonCore/Events/DTS.Viewer/TestModification/RefreshTestRequestEvent.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/TestModification/ShowT0CursorEvent.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/TestModification/TestModificationChangedEvent.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/TestModification/SetUseZeroForUnfilteredEvent.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/TestModification/TestModificationEvent.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/TestModification/ShiftT0Event.cs
generated_at: "2026-04-17T16:03:15.424024+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "f3ae1bbc7522d687"
---
# TestModification
### Purpose
This module defines a set of Prism events for coordinating test modification operations within the DTS Viewer system. It provides a loosely-coupled messaging mechanism for components to communicate changes to test data, T0 cursor state, and filtering behavior without direct references. All events inherit from `CompositePresentationEvent<T>` from the legacy Microsoft.Practices.Prism library.
### Public Interface
**RefreshTestRequestEvent**
- Signature: `public class RefreshTestRequestEvent : CompositePresentationEvent<string>`
- Payload: `string` (test ID)
- Behavior: Published to request a refresh of a specific test identified by its ID.
**ShowT0CursorEvent**
- Signature: `public class ShowT0CursorEvent : CompositePresentationEvent<bool>`
- Payload: `bool` (true to show, false to hide)
- Behavior: Controls visibility of the T0 cursor in the viewer.
**TestModificationChangedEvent**
- Signature: `public class TestModificationChangedEvent : CompositePresentationEvent<ITestModificationModel>`
- Payload: `ITestModificationModel`
- Behavior: Notifies subscribers when the data folder or test modification model has changed.
**SetUseZeroForUnfilteredEvent**
- Signature: `public class SetUseZeroForUnfilteredEvent : CompositePresentationEvent<bool>`
- Payload: `bool`
- Behavior: Controls whether 0 or P is used in the isocode filter field when modifying an isocode from a filter.
**TestModificationEvent**
- Signature: `public class TestModificationEvent : CompositePresentationEvent<TestModificationArgs>`
- Payload: `TestModificationArgs`
- Behavior: Published whenever a test is modified by the viewer. Used by DataPro to regenerate an ROI when an event is modified.
**TestModificationArgs**
- Properties:
- `string DataSetDirectory { get; private set; }` - Path to the DTS file
- `string TestId { get; private set; }` - Identifier of the modified test
- Constructor: `TestModificationArgs(string dtsFilePath, string testId)`
**ShiftT0Event**
- Signature: `public class ShiftT0Event : CompositePresentationEvent<ShiftT0EventArguments>`
- Payload: `ShiftT0EventArguments`
- Behavior: Published to shift the T0 marker position.
**ShiftT0EventArguments**
- Properties:
- `double T0Time { get; }` - The T0 time value
- `bool IsInitialization { get; }` - Whether this shift is part of initialization
- `int T0Steps { get; }` - Steps/samples from T0 to shift
- `bool IsKeyPress { get; }` - Whether shift was caused by arrow key press
- Constructors:
- `ShiftT0EventArguments(double t0, bool isInitialization)` - Sets T0Time, defaults T0Steps=0, IsKeyPress=false
- `ShiftT0EventArguments(int steps, bool isInitialization, bool isKeyPress)` - Sets T0Steps, defaults T0Time=0D
### Invariants
- `TestModificationArgs.DataSetDirectory` and `TestId` are set only at construction and cannot be modified.
- `ShiftT0EventArguments` properties are immutable after construction.
- When using the time-based constructor for `ShiftT0EventArguments`, `T0Steps` is always 0 and `IsKeyPress` is always false.
- When using the steps-based constructor for `ShiftT0EventArguments`, `T0Time` is always 0D.
### Dependencies
- **Depends on**: `Microsoft.Practices.Prism.Events` (legacy Prism event aggregation), `DTS.Common.Interface` (for `ITestModificationModel`)
- **Depended on by**: Unclear from source alone; likely consumed by viewer components, DataPro, and any module that modifies test data.
### Gotchas
- The XML comment for `TestModificationChangedEvent` states "The Data Folder changed event" which appears inconsistent with the class name and payload type (`ITestModificationModel`).
- Several files use `// ReSharper disable CheckNamespace` suggesting namespace inconsistencies that were suppressed rather than fixed.
- The `ShiftT0EventArguments` class has two mutually exclusive constructors; the time-based and steps-based approaches cannot be combined in a single instance.
---

View File

@@ -0,0 +1,62 @@
---
source_files:
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerChartOptions/ResetZoomChangedEvent.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerChartOptions/CursorShowChangedEvent.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerChartOptions/CursorsClearChangedEvent.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerChartOptions/CursorShowMinMaxChangedEvent.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerChartOptions/CursorsAlailableChangedEvent.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerChartOptions/SaveToPDFRequestedEvent.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerChartOptions/ChartAxisChangedEvent.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerChartOptions/ChartOptionsChangedEvent.cs
generated_at: "2026-04-17T16:02:47.397446+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "e4db1ed01ee3ab20"
---
# ViewerChartOptions
### Purpose
This module defines Prism-based event classes for chart viewer operations, enabling loosely-coupled communication between components in the viewer subsystem. Events cover zoom reset, cursor display/clearing, PDF export, and axis/options changes. Uses the older `Microsoft.Practices.Prism.Events` namespace (Prism 4.x or earlier).
### Public Interface
**ResetZoomChangedEvent**
- Inherits `CompositePresentationEvent<bool>` - Event payload is a boolean.
**CursorShowChangedEvent**
- Inherits `CompositePresentationEvent<bool>` - Event payload is a boolean.
**CursorsClearChangedEvent**
- Inherits `CompositePresentationEvent<bool>` - Event payload is a boolean.
**CursorShowMinMaxChangedEvent**
- Inherits `CompositePresentationEvent<bool>` - Event payload is a boolean.
**CursorsAlailableChangedEvent**
- Inherits `CompositePresentationEvent<bool>` - Event payload is a boolean. Note: typo in class name ("Alailable" vs "Available").
**SaveToPDFRequestedEvent**
- Inherits `CompositePresentationEvent<string>` - Event payload is a string (likely file path).
**ChartAxisChangedEvent**
- Inherits `CompositePresentationEvent<ChartAxisChangedEventArg>` - Event payload is `ChartAxisChangedEventArg`.
**ChartAxisChangedEventArg**
- `IBaseViewModel ParentVM { get; set; }` - Parent view model reference.
- `string Axis { get; set; }` - Axis identifier.
- `double MinValue { get; set; }` - Minimum axis value.
- `double MaxValue { get; set; }` - Maximum axis value.
**ChartOptionsChangedEvent**
- Inherits `CompositePresentationEvent<ChartOptionsChangedEventArg>` - Event payload is `ChartOptionsChangedEventArg`.
**ChartOptionsChangedEventArg**
- `IBaseViewModel ParentVM { get; set; }` - Parent view model reference.
- `IChartOptionsModel Model { get; set; }` - Chart options model.
- `string ChartType { get; set; }` - Chart type identifier.
### Invariants
- All events inherit from `CompositePresentationEvent<T>` and are empty classes (no additional members).
- Event args classes (`ChartAxisChangedEventArg`, `ChartOptionsChangedEventArg`) are mutable POCOs with public getters and setters.
- The `

View File

@@ -0,0 +1,57 @@
---
source_files:
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerFilter/FilterParameterChangedEvent.cs
generated_at: "2026-04-17T16:39:31.229290+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "e2918a5abc891c6f"
---
# Documentation: FilterParameterChangedEvent
## 1. Purpose
This module provides a Prism Event Aggregator event for broadcasting filter parameter changes within a viewer context. It enables loosely coupled communication between view models when filter criteria are modified, allowing components to react to filter changes without direct references to the source. The event carries information about both the requesting view model and the filter parameter value.
## 2. Public Interface
### `FilterParameterArgs`
A payload class that carries data for filter parameter change notifications.
| Property | Type | Description |
|----------|------|-------------|
| `Requester` | `IBaseViewModel` | The view model that requested the filter operation. Has public getter and setter. |
| `Param` | `string` | The filter parameter value. Has public getter and setter. |
### `FilterParameterChangedEvent`
An event class for publishing/subscribing to filter parameter changes.
```
public class FilterParameterChangedEvent : CompositePresentationEvent<FilterParameterArgs>
```
Inherits from `CompositePresentationEvent<FilterParameterArgs>`, providing standard Prism event aggregation capabilities (publish, subscribe, unsubscribe).
## 3. Invariants
- The `FilterParameterChangedEvent` always publishes payloads of type `FilterParameterArgs`.
- Both `Requester` and `Param` properties are nullable (no validation is enforced at the type level).
- The class uses a default parameterless constructor (implicitly defined).
- The event follows the Prism Event Aggregator pattern and requires an `IEventAggregator` instance to function properly.
## 4. Dependencies
### This module depends on:
- **`DTS.Common.Base`** - Provides `IBaseViewModel` interface used for the `Requester` property.
- **`Microsoft.Practices.Prism.Events`** - Provides `CompositePresentationEvent<T>` base class for event definition.
### What depends on this module:
- **Unknown from source alone** - No consumers are defined in this file. Typically, view models that publish or subscribe to filter changes would depend on this event.
## 5. Gotchas
- **Namespace mismatch**: The file is located at `Common/DTS.CommonCore/Events/DTS.Viewer/ViewerFilter/` but the declared namespace is `DTS.Common.Events`. The `// ReSharper disable CheckNamespace` directive suppresses the IDE warning, suggesting this is intentional but may cause confusion when locating the file.
- **Mutable payload**: `FilterParameterArgs` properties have public setters, allowing modification after event publication. Subscribers could potentially mutate the payload, affecting other subscribers.
- **No null

View File

@@ -0,0 +1,55 @@
---
source_files:
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerSettings/CalibrationBehaviorSettableInViewerChangedEvent.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerSettings/ViewerSettingsVisibilityChangedEvent.cs
generated_at: "2026-04-17T16:37:21.633818+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "cb19af85b80535a7"
---
# Documentation: Viewer Settings Events
## 1. Purpose
This module defines two Prism event classes used for communication within a viewer subsystem. These events facilitate decoupled publish/subscribe messaging regarding viewer settings state changes—specifically, whether calibration behavior can be set in the viewer, and the visibility state of viewer settings UI. Both events inherit from `CompositePresentationEvent<T>` and serve as typed message carriers in an event aggregation pattern.
---
## 2. Public Interface
### `CalibrationBehaviorSettableInViewerChangedEvent`
- **Signature:** `public class CalibrationBehaviorSettableInViewerChangedEvent : CompositePresentationEvent<bool>`
- **Behavior:** A typed event that carries a `bool` payload indicating whether calibration behavior is settable in the viewer. Subscribers receive `true` or `false` to denote the current settable state. No additional members are defined beyond the inherited `CompositePresentationEvent<bool>`.
### `ViewerSettingsVisibilityChangedEvent`
- **Signature:** `public class ViewerSettingsVisibilityChangedEvent : CompositePresentationEvent<Visibility>`
- **Behavior:** A typed event that carries a `System.Windows.Visibility` payload (e.g., `Visible`, `Hidden`, `Collapsed`). Subscribers receive visibility state changes for the viewer settings UI. No additional members are defined beyond the inherited `CompositePresentationEvent<Visibility>`.
---
## 3. Invariants
- Both event classes are sealed by implication of having no `virtual` or `abstract` members; they are intended for instantiation and use as-is.
- The payload type for `CalibrationBehaviorSettableInViewerChangedEvent` is always `bool`; no other type may be published through this event.
- The payload type for `ViewerSettingsVisibilityChangedEvent` is always `System.Windows.Visibility`; no other type may be published through this event.
- Both classes reside in the `DTS.Common.Events` namespace regardless of their file location (see Gotchas).
---
## 4. Dependencies
### This module depends on:
- `Microsoft.Practices.Prism.Events.CompositePresentationEvent<T>` — base class for both events, providing publish/subscribe infrastructure.
- `System.Windows.Visibility` — enum type used as payload for `ViewerSettingsVisibilityChangedEvent`.
### What depends on this module:
- **Inferred consumers:** Any component that publishes or subscribes to viewer settings state changes, likely within a viewer module or related UI components. Specific consumers cannot be determined from these source files alone.
---
## 5. Gotchas
- **Namespace/file location mismatch:** Both files contain `// ReSharper disable CheckNamespace` and are located in a subdirectory path (`DTS.Viewer/ViewerSettings/`), yet declare namespace `DTS.Common.Events`. This suggests intentional namespace flattening for event aggregation purposes, but may cause confusion when navigating the codebase.
- **No explicit constructors or members:** Both classes rely entirely on inherited functionality from `CompositePresentationEvent<T>`. Developers unfamiliar with Prism's event aggregation pattern may need to reference Prism documentation to understand usage (Subscribe, Publish, etc.).
- **WPF dependency:** `ViewerSettingsVisibilityChangedEvent` uses `System.Windows.Visibility`, tying it to WPF/UI concerns. This may limit reusability in non-WPF contexts.

View File

@@ -0,0 +1,58 @@
---
source_files:
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerTestSummary/ChannelSelectionCountNotification.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerTestSummary/ChannelsModificationNotification.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerTestSummary/ChannelSelectionChangeNotification.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerTestSummary/GraphChannelReadCalcProgressChangedEvent.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerTestSummary/GraphChannelsReadCompletedNotification.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerTestSummary/DataFileSelectedEvent.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerTestSummary/GraphLoadedCountNotification.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerTestSummary/TestLoadedCountNotification.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerTestSummary/TestSummaryCountNotification.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerTestSummary/GraphClearNotification.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerTestSummary/GraphSelectedChannelCountNotification.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerTestSummary/GraphSelectedChannelsNotification.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerTestSummary/ChannelsModificationLineFitNotification.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerTestSummary/TestSummaryChangeNotification.cs
- Common/DTS.CommonCore/Events/DTS.Viewer/ViewerTestSummary/DataFolderChangedEvent.cs
generated_at: "2026-04-17T15:29:01.513697+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "fc5a35e0bc4c988a"
---
# Documentation: DTS.Common.Events (ViewerTestSummary)
## 1. Purpose
This module defines a set of Prism-based pub/sub events for coordinating state changes within the Viewer Test Summary subsystem. These events facilitate loose coupling between components by enabling notification of channel selections, graph loading/progress, test summary changes, and data file/folder selections. The events follow the `CompositePresentationEvent<T>` pattern from Microsoft.Practices.Prism, allowing subscribers to receive strongly-typed payloads when specific UI or data operations occur.
---
## 2. Public Interface
### Channel Selection Events
#### `ChannelSelectionCountNotification`
- **Signature:** `public class ChannelSelectionCountNotification : CompositePresentationEvent<int>`
- **Behavior:** Publishes the count of selected channels as an integer value.
#### `ChannelSelectionChangeNotification`
- **Signature:** `public class ChannelSelectionChangeNotification : CompositePresentationEvent<List<ITestChannel>>`
- **Behavior:** Publishes a list of `ITestChannel` objects when the selected Test Summary list changes.
#### `ChannelsModificationNotification`
- **Signature:** `public class ChannelsModificationNotification : CompositePresentationEvent<List<ITestChannel>>`
- **Behavior:** Publishes a list of `ITestChannel` objects when the number of selected graphs changes.
#### `ChannelsModificationLineFitNotification`
- **Signature:** `public class ChannelsModificationLineFitNotification : CompositePresentationEvent<LineFitArgs>`
- **Behavior:** Publishes line fit modification data with channel and index range information.
**Payload class `LineFitArgs`:**
```csharp
public LineFitArgs(ITestChannel channel, ulong startIndex, ulong endIndex)
```
- `Channel` (ITestChannel): The test channel being modified
- `StartIndex` (ulong): Starting index for the line fit
- `EndIndex` (ulong): Ending index for

View File

@@ -0,0 +1,79 @@
---
source_files:
- Common/DTS.CommonCore/Events/Database/DbStatusEvent.cs
generated_at: "2026-04-17T16:40:13.623179+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "d12f546e7f17ce45"
---
# Documentation: DbStatusEvent.cs
## 1. Purpose
This module provides an event mechanism for broadcasting database status changes within the application, specifically related to database switch operations. It exists to decouple database operation outcomes from their consumers, allowing loosely-coupled components to react to database synchronization, backup, restore, and connection failures. The module implements the Prism event aggregation pattern via `CompositePresentationEvent<T>`.
---
## 2. Public Interface
### `DbStatusEvent`
**Signature:** `public class DbStatusEvent : CompositePresentationEvent<DbStatusArg>`
A concrete event class that serves as a typed event carrier in the Prism event aggregation system. It carries `DbStatusArg` as its payload. This class has no additional members beyond its inherited functionality.
---
### `DbStatusArg`
**Signature:** `public class DbStatusArg`
An immutable payload class containing the details of a database status event.
**Constructor:**
```csharp
public DbStatusArg(EventTypes error, Exception exception)
```
Constructs a new instance with the specified status type and optional exception.
**Properties:**
| Property | Type | Access | Description |
|----------|------|--------|-------------|
| `Status` | `EventTypes` | Get only | The type of status event that occurred |
| `Exception` | `Exception` | Get only | An associated exception, if any |
---
### `DbStatusArg.EventTypes`
**Signature:** `public enum EventTypes`
Defines the possible database operation outcomes.
| Value | Implied Meaning |
|-------|-----------------|
| `FailedToConnectToRemote` | Connection to remote database failed |
| `FailedToBackupLocal` | Local database backup operation failed |
| `FailedToCopy` | Copy operation failed |
| `FailedToRestoreLocal` | Local database restore operation failed |
| `FailedToBackupLocalFileNotFound` | Backup failed due to missing file |
| `Complete` | Operation completed successfully |
| `LegacyStatus` | Unclear from source alone |
---
## 3. Invariants
- **Immutability:** `DbStatusArg` instances are immutable after construction. The `Status` and `Exception` properties have no setters.
- **Non-null Status:** The `Status` property is always assigned via the constructor; it cannot be null since `EventTypes` is a value type enum.
- **Event payload type:** `DbStatusEvent` always carries `DbStatusArg` as its payload type, enforced by the generic base class.
---
## 4. Dependencies
**This module depends on:**
- `System` (standard .NET namespace for `Exception` type)
- `Microsoft.Practices.Prism.Events` (provides `CompositePresentationEvent<T>` for event aggregation)
**What depends on this module:**
- Cannot be

View File

@@ -0,0 +1,66 @@
---
source_files:
- Common/DTS.CommonCore/Events/Diagnostics/CheckDataToDownloadEvent.cs
generated_at: "2026-04-17T16:39:24.594402+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "93563fd63be87aa2"
---
# Documentation: CheckDataToDownloadEvent.cs
## 1. Purpose
This module defines a Prism-based event for diagnostic purposes, specifically to signal when data should be checked prior to downloading. It provides a mechanism for components to communicate about download validation, with an option to bypass the check entirely. The event carries contextual information about the producer that raised it, allowing subscribers to make informed decisions about whether to proceed with or skip validation logic.
---
## 2. Public Interface
### `CheckDataToDownloadEvent`
A typed event class that inherits from `CompositePresentationEvent<CheckDataToDownloadEventArgs>`. This class has no additional members; it serves as a strongly-typed event definition for the Prism event aggregation system.
**Signature:**
```csharp
public class CheckDataToDownloadEvent : CompositePresentationEvent<CheckDataToDownloadEventArgs>
```
### `CheckDataToDownloadEventArgs`
An immutable payload class carrying event data.
**Constructor:**
```csharp
public CheckDataToDownloadEventArgs(bool bypassCheck, object o)
```
**Properties:**
| Property | Type | Access | Description |
|----------|------|--------|-------------|
| `BypassCheck` | `bool` | Public getter, private setter | Indicates whether the data check should be skipped |
| `Producer` | `object` | Public getter, private setter | Reference to the object that raised the event |
---
## 3. Invariants
- **Immutability**: Both `BypassCheck` and `Producer` properties are set exclusively via the constructor and cannot be modified after instantiation (private setters).
- **Nullability**: The `Producer` property accepts any `object` reference, including `null`. No null-checking is enforced by the constructor.
- **Type constraint**: The event is strongly typed to carry `CheckDataToDownloadEventArgs` via the generic base class `CompositePresentationEvent<T>`.
---
## 4. Dependencies
### This module depends on:
- `Microsoft.Practices.Prism.Events` — Provides `CompositePresentationEvent<T>`, the base class for Prism's event aggregation pattern.
### What depends on this module:
- **Unknown from source alone.** Consumers would subscribe to or publish `CheckDataToDownloadEvent` via a Prism `IEventAggregator`, but no subscribers or publishers are visible in this file.
---
## 5. Gotchas
- **Weak type safety on `Producer`**: The `Producer` property is typed as `object`, requiring subscribers to cast if they need type-specific behavior. This design trades type safety for flexibility across heterogeneous producers.
- **No validation in constructor**: The constructor does not validate the `Producer` argument; `null` values are permitted and will propagate silently.
- **Empty event class**: `CheckDataTo

View File

@@ -0,0 +1,69 @@
---
source_files:
- Common/DTS.CommonCore/Events/GroupTemplates/CustomChannels/CustomChannelExportFileSetEvent.cs
- Common/DTS.CommonCore/Events/GroupTemplates/CustomChannels/CustomChannelImportEvent.cs
generated_at: "2026-04-17T16:37:05.967278+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "a3c4db7c7bb964f4"
---
# Documentation: Custom Channel Events
## 1. Purpose
This module provides event definitions for coordinating custom channel import and export operations within a group templates feature. It leverages the Prism Event Aggregation pattern to enable loosely-coupled communication between application components, allowing publishers and subscribers to interact without direct references. The events facilitate signaling export file set operations and import status notifications.
---
## 2. Public Interface
### `CustomChannelExportFileSetEvent`
**Signature:** `public class CustomChannelExportFileSetEvent : CompositePresentationEvent<string>`
An event that publishes a `string` payload. According to the source comments, it informs the application that it should mark itself busy or available.
### `CustomChannelImportEvent`
**Signature:** `public class CustomChannelImportEvent : CompositePresentationEvent<CustomChannelImportEventArgs>`
An event that publishes `CustomChannelImportEventArgs` to inform subscribers of custom channel import status.
### `CustomChannelImportEventArgs`
**Signature:** `public class CustomChannelImportEventArgs`
A payload class containing import status information.
| Member | Type | Description |
|--------|------|-------------|
| `Status` | `enum` | Nested enum with a single value: `Done` |
| `ImportStatus` | `Status` | Read-only property containing the import status |
**Constructor:** `CustomChannelImportEventArgs(Status status)` — Initializes the instance with the specified status.
---
## 3. Invariants
- `CustomChannelImportEventArgs.ImportStatus` is immutable after construction (read-only property with no setter).
- `CustomChannelImportEventArgs.Status` enum currently defines only the `Done` value; any other status values are undefined.
- Both event classes inherit from `CompositePresentationEvent<T>` from Prism, implying they must be used with an `IEventAggregator` instance.
---
## 4. Dependencies
### This module depends on:
- `Microsoft.Practices.Prism.Events` — Specifically the `CompositePresentationEvent<T>` base class for event aggregation.
### What depends on this module:
- **Cannot be determined from source alone.** Consumers would be any component that publishes or subscribes to these events via an `IEventAggregator`.
---
## 5. Gotchas
1. **Ambiguous string payload:** `CustomChannelExportFileSetEvent` uses a `string` payload, but the source does not define what this string represents (e.g., a file path, identifier, or status message). The comment mentions "mark itself busy or available," but the relationship between the string value and busy/available state is unclear.
2. **Incomplete status enum:** `CustomChannelImportEventArgs.Status` only defines `Done`. There are no intermediate states (e.g., `Started`, `InProgress`, `Failed`) visible in the source, which may indicate either a simplified implementation or missing status values.
3. **No null validation:** `CustomChannelImportEventArgs` does not validate the

View File

@@ -0,0 +1,48 @@
---
source_files:
- Common/DTS.CommonCore/Events/GroupTemplates/GroupTemplateList/GroupTemplateListGroupDoubleClickEvent.cs
- Common/DTS.CommonCore/Events/GroupTemplates/GroupTemplateList/GroupTemplateListGroupTemplateSelectedEvent.cs
generated_at: "2026-04-17T16:37:06.219792+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "e80d59b89c12e842"
---
# Documentation: GroupTemplateList Events
## 1. Purpose
This module defines two event types used within the GroupTemplateList feature, implementing the Prism event aggregation pattern. These events enable loosely-coupled publish/subscribe communication between components when user interactions occur with group templates—specifically when a template is selected or double-clicked. Both events inherit from Prism's `CompositePresentationEvent<T>` base class, allowing them to be transmitted through an event aggregator.
## 2. Public Interface
### `GroupTemplateListGroupDoubleClickEvent`
- **Signature:** `public class GroupTemplateListGroupDoubleClickEvent : CompositePresentationEvent<string>`
- **Behavior:** Raised when a group template is double-clicked. Carries a single `string` payload (presumably a template identifier or name).
### `GroupTemplateListGroupTemplateSelectedEvent`
- **Signature:** `public class GroupTemplateListGroupTemplateSelectedEvent : CompositePresentationEvent<string[]>`
- **Behavior:** Raised when a group template is selected. Carries a `string[]` array payload (contents and structure of the array are not documented in source).
## 3. Invariants
- Both event classes are sealed by the compiler (no explicit inheritance modifiers, but they have no derived classes in this module).
- `GroupTemplateListGroupDoubleClickEvent` always carries a `string` payload, never null at the point of subscription dispatch (enforced by Prism framework).
- `GroupTemplateListGroupTemplateSelectedEvent` always carries a `string[]` payload, never null at the point of subscription dispatch (enforced by Prism framework).
- Both events must be published and subscribed through a Prism `IEventAggregator` instance.
## 4. Dependencies
**This module depends on:**
- `Microsoft.Practices.Prism.Events` — Provides `CompositePresentationEvent<T>` base class for event aggregation.
**Consumers (inferred):**
- Unknown from source alone. These events are published by GroupTemplateList UI components and subscribed to by handlers responding to template selection/double-click actions.
## 5. Gotchas
1. **Documentation copy-paste error:** The XML summary in `GroupTemplateListGroupDoubleClickEvent.cs` incorrectly states "The GroupTemplateListGroupTemplateSelectedEvent event" instead of referencing the correct class name. This is a documentation bug.
2. **Payload type inconsistency:** The `GroupTemplateListGroupDoubleClickEvent` uses `string` while `GroupTemplateListGroupTemplateSelectedEvent` uses `string[]`. The rationale for this difference is not explained in the source—developers should verify expected payload structure with consuming code.
3. **Vague remarks:** Both events share the identical

View File

@@ -0,0 +1,71 @@
---
source_files:
- Common/DTS.CommonCore/Events/GroupTemplates/TemplateChannelList/TemplateChannelListOrderChangedEvent.cs
- Common/DTS.CommonCore/Events/GroupTemplates/TemplateChannelList/TemplateChannelListSelectionChangedEvent.cs
- Common/DTS.CommonCore/Events/GroupTemplates/TemplateChannelList/TemplateChannelListRequiredChangedEvent.cs
generated_at: "2026-04-17T16:35:32.859295+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "fb9700a29609067e"
---
# Documentation: TemplateChannelList Events
## 1. Purpose
This module defines three event types within the `DTS.Common.Events.GroupTemplates.TemplateChannelList` namespace for publishing and subscribing to changes related to template channel lists. These events facilitate loose coupling between components in a group template management system, allowing subscribers to react to order changes, selection changes, and required-state changes for channels. The events leverage the Prism event aggregation pattern via `CompositePresentationEvent<T>`.
---
## 2. Public Interface
### `TemplateChannelListOrderChangedEvent`
**Signature:** `public class TemplateChannelListOrderChangedEvent : CompositePresentationEvent<IGroupTemplateChannel>`
An event that publishes `IGroupTemplateChannel` payloads when the order of items in a template channel list has changed. Subscribers receive the affected `IGroupTemplateChannel` instance.
---
### `TemplateChannelListSelectionChangedEvent`
**Signature:** `public class TemplateChannelListSelectionChangedEvent : CompositePresentationEvent<IGroupTemplateChannel>`
An event that publishes `IGroupTemplateChannel` payloads when the selection state of an item in a template channel list has changed. Subscribers receive the `IGroupTemplateChannel` instance whose selection changed.
---
### `TemplateChannelListRequiredChangedEvent`
**Signature:** `public class TemplateChannelListRequiredChangedEvent : CompositePresentationEvent<TemplateChannelListRequiredChangeEventArgs>`
An event that publishes `TemplateChannelListRequiredChangeEventArgs` payloads when the "required" state of channel(s) has changed. Subscribers receive an event args object containing both the consumer and the affected channels.
---
### `TemplateChannelListRequiredChangeEventArgs`
**Signature:** `public class TemplateChannelListRequiredChangeEventArgs`
A payload class carrying context for required-state changes.
| Property | Type | Description |
|----------|------|-------------|
| `Consumer` | `object` | The consumer object associated with the required change. |
| `Channels` | `IGroupTemplateChannel[]` | Array of channels affected by the required-state change. |
**Constructor:** `TemplateChannelListRequiredChangeEventArgs(object o, IGroupTemplateChannel[] channels)`
---
## 3. Invariants
- All three event classes inherit from `CompositePresentationEvent<T>` from the Prism framework, ensuring they follow the event aggregation pattern.
- `TemplateChannelListOrderChangedEvent` and `TemplateChannelListSelectionChangedEvent` always carry a single `IGroupTemplateChannel` instance as their payload.
- `TemplateChannelListRequiredChangedEvent` always carries a `TemplateChannelListRequiredChangeEventArgs` instance, which contains a non-null `Consumer` object and a `Channels` array (the array may be empty but is never null per constructor assignment).
- All events are reference types and must be published/subscribed through a Prism `IEventAggregator`.
---
## 4. Dependencies
### This module depends on:
- `DTS.Common.Interface.GroupTemplate` — Provides the `IGroupTemplateChannel` interface used as payload type.
- `Microsoft.Practices.Prism.Events` — Provides `CompositePresentationEvent<T>` base class for event aggregation.

View File

@@ -0,0 +1,90 @@
---
source_files:
- Common/DTS.CommonCore/Events/Groups/GroupChannelList/GroupChannelDeleteRequestEvent.cs
- Common/DTS.CommonCore/Events/Groups/GroupChannelList/GroupChannelsChangedEvent.cs
- Common/DTS.CommonCore/Events/Groups/GroupChannelList/GroupUpdatedEvent.cs
generated_at: "2026-04-17T16:35:33.113253+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "62b1d67b4fec52ab"
---
# Documentation: DTS.Common.Events.Groups.GroupChannelList
## 1. Purpose
This module defines three Prism-based events for managing group channel lifecycle operations within the DTS system. It provides a pub/sub mechanism for coordinating channel deletion requests, channel collection changes, and group update status notifications across loosely-coupled components. The events follow the `CompositePresentationEvent<T>` pattern from Microsoft.Practices.Prism, enabling decoupled communication between UI components and business logic handlers.
---
## 2. Public Interface
### `GroupChannelDeleteRequestEvent`
**Signature:** `public class GroupChannelDeleteRequestEvent : CompositePresentationEvent<GroupChannelDeleteRequestEventArgs>`
An event raised to request deletion of a group channel. Subscribers handle the actual deletion logic; publishers initiate the request.
---
### `GroupChannelDeleteRequestEventArgs`
**Signature:** `public class GroupChannelDeleteRequestEventArgs`
| Property | Type | Description |
|----------|------|-------------|
| `Page` | `object` | The page/context initiating the delete request. Read-only. |
| `Channel` | `IGroupChannel` | The channel targeted for deletion. Read-only. |
**Constructor:** `GroupChannelDeleteRequestEventArgs(object page, IGroupChannel channel)`
---
### `GroupChannelsChangedEvent`
**Signature:** `public class GroupChannelsChangedEvent : CompositePresentationEvent<GroupChannelsChangedEventArgs>`
An event raised when the collection of channels within a group has changed.
---
### `GroupChannelsChangedEventArgs`
**Signature:** `public class GroupChannelsChangedEventArgs`
| Property | Type | Description |
|----------|------|-------------|
| `Group` | `object` | The group whose channels changed. Read-only. |
| `ChannelCount` | `int` | The updated count of channels in the group. Read-only. |
**Constructor:** `GroupChannelsChangedEventArgs(object group, int channelCount)`
---
### `GroupUpdatedEvent`
**Signature:** `public class GroupUpdatedEvent : CompositePresentationEvent<GroupUpdatedEventArgs>`
An event raised when a group has been updated, with specific status indicating the type of update.
---
### `GroupUpdatedEventArgs`
**Signature:** `public class GroupUpdatedEventArgs`
| Property | Type | Description |
|----------|------|-------------|
| `Page` | `object` | The page/context initiating the update. Read-only. |
| `UpdateStatus` | `Status` | The status indicating what type of update occurred. Read-only. |
**Constructor:** `GroupUpdatedEventArgs(object page, Status status)`
**Nested Enum:**
```csharp
public enum Status
{
ChannelsInserted,
AssignmentsMade
}
```
---
## 3. Invariants
- All event argument classes are immutable after construction; properties are get-only and set exclusively

View File

@@ -0,0 +1,64 @@
---
source_files:
- Common/DTS.CommonCore/Events/Groups/GroupsList/GroupListEditGroupEvent.cs
- Common/DTS.CommonCore/Events/Groups/GroupsList/GroupListGroupSelectedEvent.cs
generated_at: "2026-04-17T16:37:08.634284+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "891bc058cc39fcbc"
---
# Documentation: DTS.Common.Events.Groups.GroupList
## 1. Purpose
This module defines event types for group list operations within a Prism-based event aggregation system. It provides strongly-typed event classes that enable decoupled publish/subscribe communication between components when users interact with groups in a list view—specifically when editing a group or selecting one or more groups. These events carry group identifiers as payloads and are intended to be used with Prism's `IEventAggregator` mechanism.
---
## 2. Public Interface
### `GroupListEditGroupEvent`
**Signature:**
```csharp
public class GroupListEditGroupEvent : CompositePresentationEvent<int> { }
```
**Behavior:** An event that publishes an `int` payload representing a single group ID. Subscribers receive this event when a group is being edited from a group list context.
---
### `GroupListGroupSelectedEvent`
**Signature:**
```csharp
public class GroupListGroupSelectedEvent : CompositePresentationEvent<int[]> { }
```
**Behavior:** An event that publishes an `int[]` payload representing one or more group IDs. Subscribers receive this event when group selection changes in a group list context.
---
## 3. Invariants
- `GroupListEditGroupEvent` always carries a single `int` payload (a group identifier).
- `GroupListGroupSelectedEvent` always carries an `int[]` payload (an array of group identifiers, which may contain zero, one, or multiple elements).
- Both classes inherit from `CompositePresentationEvent<T>` from the Prism framework, ensuring they integrate with Prism's `IEventAggregator` for thread-safe publish/subscribe patterns.
---
## 4. Dependencies
**This module depends on:**
- `Microsoft.Practices.Prism.Events` — Provides the `CompositePresentationEvent<T>` base class for Prism event aggregation.
**Consumers (inferred):**
- Components that publish or subscribe to group list events via Prism's `IEventAggregator`. Specific consumers cannot be determined from these source files alone.
---
## 5. Gotchas
- **Stale XML documentation:** Both classes contain copy-pasted XML comments that reference `GroupTemplateListGroupTemplateSelectedEvent` and state "called when a template is selected." These comments do not match the actual class names or their intended purpose (group operations, not template operations). The documentation should be updated to reflect the correct class names and behaviors.
- **Payload type difference:** Note that `GroupListEditGroupEvent` uses `int` while `GroupListGroupSelectedEvent` uses `int[]`. Subscribers must handle the appropriate payload type for each event.

View File

@@ -0,0 +1,23 @@
---
source_files:
- Common/DTS.CommonCore/Events/Hardware/HardwareList/HardwareListShowCompactEvent.cs
- Common/DTS.CommonCore/Events/Hardware/HardwareList/HardwareListEditHardwareEvent.cs
- Common/DTS.CommonCore/Events/Hardware/HardwareList/HardwareListHardwareSelectedEvent.cs
- Common/DTS.CommonCore/Events/Hardware/HardwareList/HardwareReplaceEvent.cs
- Common/DTS.CommonCore/Events/Hardware/HardwareList/HardwareSavedEvent.cs
- Common/DTS.CommonCore/Events/Hardware/HardwareList/HardwareListHardwareIncludedEvent.cs
- Common/DTS.CommonCore/Events/Hardware/HardwareList/HardwareListHardwareTestPTPDomainIDEvent.cs
- Common/DTS.CommonCore/Events/Hardware/HardwareList/HardwareListHardwareTestSampleRateEvent.cs
- Common/DTS.CommonCore/Events/Hardware/HardwareList/HardwareListHardwareTestClockMasterEvent.cs
- Common/DTS.CommonCore/Events/Hardware/HardwareList/HardwareListHardwareTestAAFilterRateEvent.cs
generated_at: "2026-04-17T16:34:19.298855+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "e4b0fd2ea0282a1d"
---
# Hardware List Events Module Documentation
## 1. Purpose
This module defines a collection of Prism-based event classes for coordinating hardware list operations within the DTS (Data Acquisition System) application. These events facilitate loosely-coupled communication between components regarding hardware selection, configuration changes (sample rate, clock master status, PTP domain ID, AA filter rate), inclusion state, replacement requests, and persistence operations. All events inherit from `CompositePresentation

View File

@@ -0,0 +1,63 @@
---
source_files:
- Common/DTS.CommonCore/Events/ISO/ExtraPropertiesChangedEvent.cs
generated_at: "2026-04-17T16:39:23.058616+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "c9e635756f4d2d11"
---
# Documentation: ExtraPropertiesChangedEvent.cs
## 1. Purpose
This module defines a Prism-based event mechanism for broadcasting changes to "extra properties" within the ISO-related subsystem. It enables decoupled pub/sub communication between components, allowing a producer to notify consumers when a collection of `IExtraProperty` objects has changed. The event follows the Prism CompositePresentationEvent pattern for loosely-coupled messaging.
---
## 2. Public Interface
### `ExtraPropertiesChangedEvent`
A class that inherits from `CompositePresentationEvent<ExtraPropertiesChangedEventArgs>`. It serves as the event definition used with Prism's `IEventAggregator` for publishing and subscribing to extra property change notifications.
**Signature:**
```csharp
public class ExtraPropertiesChangedEvent : CompositePresentationEvent<ExtraPropertiesChangedEventArgs> { }
```
---
### `ExtraPropertiesChangedEventArgs`
A payload class carrying information about the property change event.
**Constructor:**
```csharp
public ExtraPropertiesChangedEventArgs(IList<IExtraProperty> extraProperties, object producer, object consumer)
```
**Properties:**
| Property | Type | Access | Description |
|----------|------|--------|-------------|
| `ExtraProperties` | `IList<IExtraProperty>` | Public get, private set | The collection of extra properties that changed |
| `Producer` | `object` | Public get, private set | The object that produced/owns the extra properties |
| `Consumer` | `object` | Public get, private set | The intended consumer of the extra properties |
---
## 3. Invariants
- **Immutability**: All properties on `ExtraPropertiesChangedEventArgs` are read-only after construction (private setters).
- **Required parameters**: The constructor requires all three parameters (`extraProperties`, `producer`, `consumer`) to be provided—no parameterless constructor exists.
- **No null validation**: The constructor does not perform null checks on any parameters; null values will be stored as-is.
---
## 4. Dependencies
### This module depends on:
- `DTS.Common.Interface.ISO.ExtraProperties` — Provides the `IExtraProperty` interface used in the `ExtraProperties` collection
- `Microsoft.Practices.Prism.Events` — Provides `CompositePresentationEvent<T>` base class for the event pattern
### What depends on this module:
- **Unknown from source alone** — Consumers would subscribe to or publish this event via Prism's `IEventAggregator`, but

View File

@@ -0,0 +1,13 @@
---
source_files:
- Common/DTS.CommonCore/Events/Realtime/RealtimeChannelSelectedEvent.cs
generated_at: "2026-04-17T16:09:12.333467+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "f812fcd3ad848fda"
---
# Realtime
### Purpose
This module defines the `RealtimeChannelSelectedEvent`, which is an event payload class designed to notify the system when a specific realtime channel has been selected. It

View File

@@ -0,0 +1,54 @@
---
source_files:
- Common/DTS.CommonCore/Events/RegionOfInterest/RegionOfInterestChangedEvent.cs
generated_at: "2026-04-17T16:39:19.158808+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "e442143e0642d03f"
---
# Documentation: RegionOfInterestChangedEvent
## 1. Purpose
This module defines `RegionOfInterestChangedEvent`, a typed event class for use with the Prism Event Aggregator pattern. It enables loosely-coupled publication and subscription of region-of-interest change notifications across the application. The event carries an `IRegionOfInterest` payload, allowing subscribers to react to changes in the active or selected region without direct coupling to the publisher.
---
## 2. Public Interface
### `RegionOfInterestChangedEvent`
**Signature:**
```csharp
public class RegionOfInterestChangedEvent : CompositePresentationEvent<IRegionOfInterest> { }
```
**Description:**
An empty class that inherits from `CompositePresentationEvent<IRegionOfInterest>`. It serves as a type identifier for the Prism Event Aggregator, defining an event that publishes/subscribes to `IRegionOfInterest` instances. No additional members are defined; all functionality is inherited from the base class.
---
## 3. Invariants
- The event payload type is fixed to `IRegionOfInterest`; subscribers will receive objects implementing this interface.
- The class must remain instantiable (it is not `static` or `abstract`), allowing the Event Aggregator to create instances as needed.
- Inheritance from `CompositePresentationEvent<T>` is required for integration with Prism's `IEventAggregator`.
---
## 4. Dependencies
### This module depends on:
- `DTS.Common.Interface.RegionOfInterest.IRegionOfInterest` — the interface defining the event payload contract.
- `Microsoft.Practices.Prism.Events.CompositePresentationEvent<T>` — the Prism base class for typed events.
### What depends on this module:
- **Unknown from source alone.** Consumers would typically be modules that publish or subscribe to region-of-interest changes via the Event Aggregator.
---
## 5. Gotchas
- **Older Prism namespace:** The import `Microsoft.Practices.Prism.Events` indicates use of an older version of Prism (pre-.NET Core/NET5+). Modern Prism uses `Prism.Events`. This may affect migration or cross-version compatibility.
- **Empty class by design:** The class body is intentionally empty. It relies entirely on the base class for functionality. Do not add instance members; thread-safe subscription options are provided by the base `CompositePresentationEvent<T>`.

View File

@@ -0,0 +1,63 @@
---
source_files:
- Common/DTS.CommonCore/Events/RegionOfInterest/RegionOfInterestChannels/RegionOfInterestChannelsSelectedEvent.cs
generated_at: "2026-04-17T16:39:26.691835+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "0a76b98d36f3be87"
---
# Documentation: RegionOfInterestChannelsSelectedEvent
## 1. Purpose
This module defines a Prism event aggregation event used to broadcast when Region of Interest (ROI) channels are selected within the system. It follows the Prism `CompositePresentationEvent<T>` pattern, allowing loosely coupled publish/subscribe communication between components. The event carries payload data including the ROI suffix identifier, an array of selected channel names, and a reference to the consumer object that initiated or handles the selection.
## 2. Public Interface
### `RegionOfInterestChannelsSelectedEvent`
**Signature:** `public class RegionOfInterestChannelsSelectedEvent : CompositePresentationEvent<RegionOfInterestChannelsSelectedEventArgs>`
An empty class that inherits from `CompositePresentationEvent<RegionOfInterestChannelsSelectedEventArgs>`. This class serves as the event type definition for Prism's Event Aggregator, enabling type-safe event publication and subscription with `RegionOfInterestChannelsSelectedEventArgs` as the payload.
---
### `RegionOfInterestChannelsSelectedEventArgs`
**Signature:** `public class RegionOfInterestChannelsSelectedEventArgs`
The payload class carrying event data. All properties are read-only (private setters) and are set exclusively through the constructor.
**Properties:**
| Property | Type | Access | Description |
|----------|------|--------|-------------|
| `RegionOfInterestSuffix` | `string` | Public getter, private setter | Identifier suffix for the Region of Interest |
| `ChannelNames` | `string[]` | Public getter, private setter | Array of selected channel names |
| `Consumer` | `object` | Public getter, private setter | Reference to the consumer object associated with this selection |
**Constructor:**
```csharp
public RegionOfInterestChannelsSelectedEventArgs(string roiSuffix, string[] selectedChannelNames, object o)
```
Initializes a new instance with the specified ROI suffix, channel names array, and consumer object reference.
## 3. Invariants
- **Immutability:** All properties of `RegionOfInterestChannelsSelectedEventArgs` are immutable after construction (private setters only).
- **No null validation:** The constructor does not perform null checks on any parameters. Callers may pass null values for `roiSuffix`, `selectedChannelNames`, or `o`.
- **Array reference:** The `ChannelNames` property stores the array reference directly without copying; modifications to the original array after construction will be reflected in the event args.
## 4. Dependencies
**This module depends on:**
- `Microsoft.Practices.Prism.Events` - Provides `CompositePresentationEvent<T>` base class for event aggregation
- `Microsoft.Practices.Prism.Regions` - Imported but **not referenced** in the code body (appears to be an unused import)
**What depends on this module:**
- Cannot be determined from source alone. Consumers would subscribe to or publish this event via Prism's `IEventAggregator`.
## 5. Gotchas
-

View File

@@ -0,0 +1,30 @@
---
source_files:
- Common/DTS.CommonCore/Events/Sensors/CalibrationBehaviorSettingChangedEvent.cs
- Common/DTS.CommonCore/Events/Sensors/SensorFilterTypeChangedEvent.cs
generated_at: "2026-04-17T16:24:58.470778+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "30f6514a87a4c903"
---
# Sensors
### Purpose
This module defines Prism-based pub/sub events for sensor calibration and filtering operations within the DTS system. It provides strongly-typed event payloads for communicating changes to calibration behavior settings and sensor filter configurations across loosely-coupled components.
### Public Interface
**CalibrationBehaviorSettingChangedEvent**
- Signature: `class CalibrationBehaviorSettingChangedEvent : CompositePresentationEvent<DTS.Common.Enums.Sensors.CalibrationBehaviors>`
- Description: A generic event container that broadcasts changes to calibration behavior settings. The payload is a `CalibrationBehaviors` enum value.
**SensorFilterTypeChangedEvent**
- Signature: `class SensorFilterTypeChangedEvent : CompositePresentationEvent<SensorFilterTypeChangedEventArgs>`
- Description: Notifies subscribers that either an ISO code filter character or a filter class type has changed for a sensor.
**SensorFilterTypeChangedEventArgs**
- Signature: `class SensorFilterTypeChangedEventArgs`
- Constructors:
- `SensorFilterTypeChangedEventArgs(char code, ISensorData sensor, ISensorCalibration sensorCalibration, bool useISOCodeFilterMapping, bool bUseZeroForUnfiltered)` — Sets `EventType` to `ISOCodeChar`.
- `SensorFilterTypeChangedEventArgs(FilterClassType filterClassType, ISensorData sensor

View File

@@ -0,0 +1,34 @@
---
source_files:
- Common/DTS.CommonCore/Events/Sensors/SensorsList/SensorsListSensorSelectedEvent.cs
- Common/DTS.CommonCore/Events/Sensors/SensorsList/SensorChangedEvent.cs
generated_at: "2026-04-17T16:37:05.880781+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "77c00296fefdcc69"
---
# Documentation: DTS.Common.Events.Sensors.SensorsList
## 1. Purpose
This module defines event types for sensor-related operations within the DTS system, using the Prism event aggregation pattern. It provides a mechanism for loosely-coupled communication between components regarding sensor selection, persistence, and configuration changes. These events enable subscribers to react to sensor state changes without direct references to the publishing components.
## 2. Public Interface
### Events
| Event Name | Base Type | Payload Type | Description |
|------------|-----------|--------------|-------------|
| `SensorsListSensorSelectedEvent` | `CompositePresentationEvent<string[]>` | `string[]` | Published when a sensor is selected from the sensors list. |
| `SensorSavedEvent` | `CompositePresentationEvent<double>` | `double` | Published to notify the save function when a new sensor has been added in the settings menu (FB 13120). |
| `SensorUpdatedEvent` | `CompositePresentationEvent<bool>` | `bool` | Published when adding or deleting a sensor, used for selecting the default filter in filter list (FB 13120). |
| `SensorChangedEvent` | `CompositePresentationEvent<SensorChangedArgs>` | `SensorChangedArgs` | Published when a sensor's configuration changes (e.g., sensitivity, excitation, proportionality). |
### SensorChangedArgs Class
A data transfer object encapsulating details about what aspects of a sensor changed.
**Properties (all read-only):**
| Property | Type | Description |

View File

@@ -0,0 +1,79 @@
---
source_files:
- Common/DTS.CommonCore/Events/TSRAIRGo/NavigateToDashboard.cs
- Common/DTS.CommonCore/Events/TSRAIRGo/NavigateFromTSRAIRGoToDataPRO.cs
- Common/DTS.CommonCore/Events/TSRAIRGo/GlobalStatus.cs
- Common/DTS.CommonCore/Events/TSRAIRGo/Trigger.cs
- Common/DTS.CommonCore/Events/TSRAIRGo/Arm.cs
generated_at: "2026-04-17T16:34:18.337527+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "a74b4acea8a13d28"
---
# Documentation: DTS.Common.Events.TSRAIRGo
## 1. Purpose
This module defines a set of Prism event types for the TSRAIRGo subsystem, enabling loosely-coupled publish/subscribe communication between components. These events facilitate navigation control (navigating to dashboards or between applications), global status messaging, and hardware state signaling (arming and triggering). The module exists to decouple event publishers from subscribers via the Prism Event Aggregation pattern.
---
## 2. Public Interface
### NavigateToDashboardEvent
**Signature:** `public class NavigateToDashboardEvent : CompositePresentationEvent<NavigateToDashboardArg>`
**Description:** A Prism event used to signal navigation to a dashboard view. Takes no payload data.
**Payload:** `NavigateToDashboardArg` — An empty argument class with no properties.
---
### NavigateFromTSRAIRGoToDataPROEvent
**Signature:** `public class NavigateFromTSRAIRGoToDataPROEvent : CompositePresentationEvent<NavigateFromTSRAIRGoToDataPROArg>`
**Description:** A Prism event used to signal navigation from the TSRAIRGo application to the DataPRO application. Takes no payload data.
**Payload:** `NavigateFromTSRAIRGoToDataPROArg` — An empty argument class with no properties.
---
### GlobalStatusEvent
**Signature:** `public class GlobalStatusEvent : CompositePresentationEvent<GlobalStatusArg>`
**Description:** A Prism event used to broadcast global status messages within the TSRAIRGo subsystem.
**Payload:** `GlobalStatusArg`
| Property | Type | Description |
|----------|------|-------------|
| `Message` | `string` | A status message to be broadcast. |
---
### TriggerEvent
**Signature:** `public class TriggerEvent : CompositePresentationEvent<TriggerArg>`
**Description:** A Prism event used to signal a trigger action. Takes no payload data.
**Payload:** `TriggerArg` — An empty argument class with no properties.
---
### ArmEvent
**Signature:** `public class ArmEvent : CompositePresentationEvent<ArmArg>`
**Description:** A Prism event used to signal arming or disarming state changes.
**Payload:** `ArmArg`
| Property | Type | Description |
|----------|------|-------------|
| `Arm` | `bool` | `true` to arm, `false` to disarm. |
---
## 3. Invariants
- All event classes inherit from `CompositePresentationEvent<T>` where `T` is the corresponding argument type.
- Each event class has exactly one associated argument class following the naming convention `[EventName]Arg`.
- All types are public and can be subscribed to or published via the Prism `IEventAggregator`.

View File

@@ -0,0 +1,39 @@
---
source_files:
- Common/DTS.CommonCore/Events/TTSImport/TTSImportSavedChangesStatusEvent.cs
- Common/DTS.CommonCore/Events/TTSImport/StatusAndProgressBarEvent.cs
- Common/DTS.CommonCore/Events/TTSImport/TTSImportSummaryRunTestEvent.cs
- Common/DTS.CommonCore/Events/TTSImport/TTSImportTestSetupChangedEvent.cs
- Common/DTS.CommonCore/Events/TTSImport/AssignedChannelsChangedEvent.cs
- Common/DTS.CommonCore/Events/TTSImport/TTSImportHardwareScanRunEvent.cs
- Common/DTS.CommonCore/Events/TTSImport/TTSImportSummaryImportEvent.cs
- Common/DTS.CommonCore/Events/TTSImport/TTSImportReadFileFinishedEvent.cs
- Common/DTS.CommonCore/Events/TTSImport/TTSImportArmedRunTestEvent.cs
- Common/DTS.CommonCore/Events/TTSImport/TTSImportHardwareScanFinishedEvent.cs
- Common/DTS.CommonCore/Events/TTSImport/EIDMappingEvent.cs
- Common/DTS.CommonCore/Events/TTSImport/TTSImportReadFileStatusEvent.cs
- Common/DTS.CommonCore/Events/TTSImport/TTSImportReadXMLFileEvent.cs
generated_at: "2026-04-17T15:29:37.215009+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "5421793e04822b3b"
---
# TTS Import Events Module Documentation
## 1. Purpose
This module defines the event types used for inter-component communication within the TTS (Test Setup) Import workflow. It leverages the Prism Event Aggregation pattern (`CompositePresentationEvent<T>`) to enable loose coupling between the various steps of the import wizard (Read File, Hardware Scan, Summary, etc.) and the main page/view models. These events facilitate coordination for operations such as file reading, hardware scanning, test execution, and UI state updates.
---
## 2. Public Interface
### Events
| Event Class | Payload Type | Description |
|-------------|--------------|-------------|
| `TTSImportSavedChangesStatusEvent` | `bool` | Communicates whether changes have been saved (`true`) or not (`false`). |
| `StatusAndProgressBarEvent` | `StatusAndProgressBarEventArgs` | Updates the Status and/or Progress bars in the UI. |
| `TTSImportSummaryRunTestEvent` | `ITTSSetup` | Published by the Summary step to trigger a test run. |
| `TTSImportTestSetup

View File

@@ -0,0 +1,63 @@
---
source_files:
- Common/DTS.CommonCore/Events/TestSetups/TestSetupsList/CurrentTestIdChangedEvent.cs
- Common/DTS.CommonCore/Events/TestSetups/TestSetupsList/CurrentTestChangedEvent.cs
- Common/DTS.CommonCore/Events/TestSetups/TestSetupsList/TestSetupsListEditTestSetupEvent.cs
- Common/DTS.CommonCore/Events/TestSetups/TestSetupsList/TestSetupsListTestSetupSelectedEvent.cs
generated_at: "2026-04-17T16:34:44.784908+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "d96706f4d371f90e"
---
# Documentation: DTS.Common.Events.TestSetups.TestSetupsList
## 1. Purpose
This module defines a set of event types used for inter-component communication within the Test Setups List feature. These events leverage the Prism Event Aggregation pattern (via `CompositePresentationEvent<T>`) to enable loosely-coupled publish/subscribe messaging between components that need to react to changes in test setup state, selection, or editing requests. The events facilitate coordination between UI components and business logic without direct dependencies.
---
## 2. Public Interface
### `CurrentTestIdChangedEvent`
- **Signature:** `public class CurrentTestIdChangedEvent : CompositePresentationEvent<string>`
- **Payload Type:** `string`
- **Behavior:** Published when the current test's identifier changes. Subscribers receive the new test ID as a string payload.
### `CurrentTestChangedEvent`
- **Signature:** `public class CurrentTestChangedEvent : CompositePresentationEvent<string>`
- **Payload Type:** `string`
- **Behavior:** Published to signal that the current test setup has changed. Subscribers receive a string payload (content/meaning of payload not specified in source).
### `TestSetupsListEditTestSetupEvent`
- **Signature:** `public class TestSetupsListEditTestSetupEvent : CompositePresentationEvent<string>`
- **Payload Type:** `string`
- **Behavior:** Published when a test setup should be edited. Subscribers receive a string payload, presumably identifying the test setup to edit.
### `TestSetupsListTestSetupSelectedEvent`
- **Signature:** `public class TestSetupsListTestSetupSelectedEvent : CompositePresentationEvent<string[]>`
- **Payload Type:** `string[]` (array of strings)
- **Behavior:** Published when a test setup is selected. According to source remarks, this is used by the Summary step to indicate that the Import button was clicked. Subscribers receive a string array payload.
---
## 3. Invariants
- All event classes inherit from `CompositePresentationEvent<T>` and are sealed by implication of having no further derivation in source.
- Payload types are fixed per event type:
- `CurrentTestIdChangedEvent`: `string`
- `CurrentTestChangedEvent`: `string`
- `TestSetupsListEditTestSetupEvent`: `string`
- `TestSetupsListTestSetupSelectedEvent`: `string[]`
- All events are reference types that must be resolved through Prism's `IEventAggregator` service; they cannot be instantiated directly for pub/sub operations in typical usage patterns.
---
## 4. Dependencies
### External Dependencies
- **Microsoft.Practices.Prism.Events** — Provides `CompositePresentationEvent<T>`, the base class for all events in this module. This is part of the Prism library (legacy versions, pre-Prism 6).
### Downstream Dependencies
- **Unknown from source alone.** Consumers would typically be ViewModels,

View File

@@ -0,0 +1,67 @@
---
source_files:
- Common/DTS.CommonCore/Exceptions/OutOfDataException.cs
generated_at: "2026-04-17T16:38:13.290924+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "e17739ecd0d7bb21"
---
# Documentation: OutOfDataException
## 1. Purpose
`OutOfDataException` is a custom exception class within the `DTS.Common.Exceptions` namespace, designed to signal that a data-consuming operation has exhausted its available data. It extends the standard `System.Exception` class and adds an `Index` property to capture the position at which the out-of-data condition occurred, enabling more precise debugging and error reporting during data parsing, streaming, or iteration operations.
## 2. Public Interface
### Class: `OutOfDataException`
**Inherits from:** `System.Exception`
**Namespace:** `DTS.Common.Exceptions`
#### Constructor
```csharp
public OutOfDataException(string ex, long index)
```
Creates a new instance of `OutOfDataException` with the specified message and index position.
| Parameter | Type | Description |
|-----------|------|-------------|
| `ex` | `string` | The exception message passed to the base `Exception` class |
| `index` | `long` | The position/index at which the out-of-data condition occurred |
#### Properties
```csharp
public long Index { get; private set; }
```
A read-only property that stores the index position where the exception was raised. Set only at construction time via the constructor.
## 3. Invariants
- **Index Immutability**: Once set during construction, the `Index` property cannot be modified externally (private setter).
- **Index Requirement**: Every `OutOfDataException` instance must have an `Index` value; there is no parameterless constructor or constructor overload that omits the index.
- **Inheritance Contract**: All standard `System.Exception` behaviors and invariants apply (e.g., serializability, stack trace capture).
## 4. Dependencies
### This module depends on:
- `System` (specifically `System.Exception` as the base class)
### What depends on this module:
- Cannot be determined from this source file alone. Consumers would typically be data parsing, streaming, or collection iteration components within the `DTS.CommonCore` library or dependent projects.
## 5. Gotchas
- **Misleading Parameter Name**: The constructor parameter `ex` suggests it might accept an exception object, but it actually expects a `string` message. A more conventional name would be `message` or `msg`.
- **No Standard Exception Constructors**: Unlike typical custom exceptions, this class does not provide:
- A parameterless constructor
- A constructor accepting only a message
- A constructor for serialization (`SerializationInfo, StreamingContext`)
- A constructor accepting an inner exception
- **Serialization Concern**: The exception is not explicitly marked as `[Serializable]` and lacks the standard deserialization constructor, which may cause issues in scenarios requiring exception serialization (e.g., across AppDomain boundaries or in distributed systems).

View File

@@ -0,0 +1,89 @@
---
source_files:
- Common/DTS.CommonCore/Interface/ITabView.cs
- Common/DTS.CommonCore/Interface/IMainView.cs
- Common/DTS.CommonCore/Interface/IMenuView.cs
- Common/DTS.CommonCore/Interface/IShellView.cs
- Common/DTS.CommonCore/Interface/INavigationView.cs
- Common/DTS.CommonCore/Interface/IViewerShellView.cs
- Common/DTS.CommonCore/Interface/ITabViewModel.cs
- Common/DTS.CommonCore/Interface/IMenuViewModel.cs
- Common/DTS.CommonCore/Interface/INavigationViewModel.cs
- Common/DTS.CommonCore/Interface/IPluginComponent.cs
- Common/DTS.CommonCore/Interface/IShellViewModel.cs
- Common/DTS.CommonCore/Interface/IViewerShellViewModel.cs
- Common/DTS.CommonCore/Interface/IMainViewModel.cs
- Common/DTS.CommonCore/Interface/IAssemblyInfo.cs
- Common/DTS.CommonCore/Interface/IDataPROPage.cs
generated_at: "2026-04-17T15:28:55.402889+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "a72604fcb2f400f1"
---
# Documentation: DTS.Common.Interface
## 1. Purpose
This module defines the core view and view-model abstraction layer for a WPF-based application framework. It establishes contracts for UI components including shell views, navigation views, tab views, menu views, and main views, following a Model-View-ViewModel (MVVM) pattern. The module also provides plugin infrastructure via `IPluginComponent`, assembly metadata attributes for image and name registration, and a comprehensive `IDataPROPage` interface for implementing data-driven UI pages with navigation, validation, and lifecycle management capabilities.
---
## 2. Public Interface
### View Interfaces
#### `ITabView`
```csharp
public interface ITabView : IBaseView { }
```
Marker interface for tab views. Inherits from `IBaseView`.
#### `IMainView`
```csharp
public interface IMainView : IBaseView { }
```
Marker interface for main views. Inherits from `IBaseView`.
#### `IMenuView`
```csharp
public interface IMenuView : IBaseView { }
```
Marker interface for menu views. Inherits from `IBaseView`.
#### `INavigationView`
```csharp
public interface INavigationView : IBaseView { }
```
Marker interface for navigation views. Inherits from `IBaseView`.
#### `IViewerShellView`
```csharp
public interface IViewerShellView : IBaseView { }
```
Marker interface for viewer shell views. Inherits from `IBaseView`.
#### `IShellView`
```csharp
public interface IShellView : IBaseWindow { }
```
Marker interface for shell views. Inherits from `IBaseWindow` (not `IBaseView`).
---
### ViewModel Interfaces
#### `ITabViewModel`
```csharp
public interface ITabViewModel : IBaseViewModel
{
ITabView View { get; }
}
```
ViewModel contract for tab components. Provides access to the associated `ITabView`.
#### `IMenuViewModel`
```csharp
public interface IMenuViewModel : IBaseViewModel
{
IMenuView View {

View File

@@ -0,0 +1,39 @@
---
source_files:
- Common/DTS.CommonCore/Interface/BuildTestSetup/IBuildTestSetup.cs
generated_at: "2026-04-17T16:25:53.219851+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "8a0bd4f98bf0d795"
---
# BuildTestSetup
### Purpose
This module defines `IBuildTestSetup`, a comprehensive configuration interface for test setup in a Data Acquisition System (DAS). It encapsulates all aspects of test configuration including hardware identification (DAS serial number), recording parameters (sample rate, trigger settings), diagnostic checklist options, download behavior, and extensive export format preferences. The interface supports property change notification for UI binding.
### Public Interface
**`IBuildTestSetup`** (extends `INotifyPropertyChanged`)
**Identification & Metadata:**
- `string DASSerialNumber { get; set; }` - Serial number of the DAS unit.
- `string SetupName { get; set; }` - Name of the test setup.
- `string SetupDescription { get; set; }` - Description of the test setup.
- `string LastModified { get; set; }` - Timestamp of last modification.
- `string LastModifiedBy { get; set; }` - User who last modified the setup.
**Recording Configuration:**
- `string AutomaticMode { get; set; }`
- `string AutomaticModeDelay { get; set; }`
- `string RecordingMode { get; set; }`
- `string SamplesPerSecond { get; set; }`
- `string PreTriggerSeconds { get; set; }`
- `string PostTriggerSeconds { get; set; }`
- `string NumberOfEvents { get; set; }`
- `string WakeUpMotionTimeout { get; set; }`
- `string ExcitationWarmupTimeMS { get; set; }`
**Diagnostic & Checklist Options:**
- `string StrictDiagnostics { get; set; }`
- `string RequireConfirmationOn

View File

@@ -0,0 +1,74 @@
---
source_files:
- Common/DTS.CommonCore/Interface/Channels/IChannelSettingRecord.cs
- Common/DTS.CommonCore/Interface/Channels/IGroupChannelSettingRecord.cs
- Common/DTS.CommonCore/Interface/Channels/IChannelCode.cs
- Common/DTS.CommonCore/Interface/Channels/IChannelSetting.cs
- Common/DTS.CommonCore/Interface/Channels/IChannelDbRecord.cs
- Common/DTS.CommonCore/Interface/Channels/IGroupChannel.cs
generated_at: "2026-04-17T15:35:42.370595+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "fe273a540c2ecd1d"
---
# Documentation: DTS.Common.Interface.Channels
## 1. Purpose
This module defines the core interfaces for the channel management subsystem within DTS. It provides abstractions for channel configuration persistence (`IChannelDbRecord`), channel settings with type-agnostic value access (`IChannelSetting`, `IChannelSettingRecord`, `IGroupChannelSettingRecord`), channel code identification (`IChannelCode`), and the comprehensive `IGroupChannel` interface that orchestrates the relationship between hardware channels, sensors, calibration data, and test configuration. These interfaces serve as the contract between the data layer, business logic, and UI components for channel-related operations.
---
## 2. Public Interface
### IChannelSettingRecord
Defines a channel setting type definition with a default value.
| Member | Signature | Description |
|--------|-----------|-------------|
| `Id` | `int Id { get; set; }` | Unique identifier for the setting type. |
| `SettingName` | `string SettingName { get; set; }` | Name of the setting. |
| `DefaultValue` | `string DefaultValue { get; set; }` | Default value for this setting type. |
### IGroupChannelSettingRecord
Defines a specific setting value applied to a channel.
| Member | Signature | Description |
|--------|-----------|-------------|
| `ChannelId` | `long ChannelId { get; set; }` | ID of the channel this setting belongs to. |
| `SettingId` | `int SettingId { get; set; }` | ID referencing the setting type. |
| `SettingValue` | `string SettingValue { get; set; }` | The value applied to this channel. |
### IChannelCode
Defines a channel code with type classification.
| Member | Signature | Description |
|--------|-----------|-------------|
| `Id` | `int Id { get; }` | Unique identifier (read-only). |
| `Code` | `string Code { get; }` | The code string. |
| `Name` | `string Name { get; }` | Display name. |
| `CodeType` | `ChannelEnumsAndConstants.ChannelCodeType CodeType { get; }` | Type classification of the channel code. |
### IChannelSetting
Defines a channel setting with typed value accessors and cloning capability.
| Member | Signature | Description |
|--------|-----------|-------------|
| `ChannelId` | `long ChannelId { get; set; }` | ID of the associated channel. |
| `SettingTypeId` | `int SettingTypeId { get; }` | ID of the setting type (read-only). |
| `SettingName` | `string SettingName { get; }` | Name of the setting (read-only). |
| `DefaultValue` | `string DefaultValue { get; }` | Default value for this setting (read-only). |
| `Value` | `string Value { get; set; }` | Raw string value. |
| `IntValue` | `int IntValue { get; set; }` | Integer representation of the value. |
| `DoubleValue` | `double DoubleValue { get; set; }` | Double representation of the value. |
| `BoolValue` | `bool BoolValue { get; set; }` | Boolean representation of the value. |
| `Clone` | `IChannelSetting Clone()` | Creates a copy of this setting instance. |
### IChannelDbRecord
Defines the database schema for a channel record with Entity Framework attributes.
| Member | Signature | Description |
|--------|-----------|-------------|
| `Id` | `long Id { get; set; }` | Primary key, mapped to column "Id". |
| `GroupId` | `int GroupId

View File

@@ -0,0 +1,60 @@
---
source_files:
- Common/DTS.CommonCore/Interface/Channels/ChannelCodes/IChannelCodesListView.cs
- Common/DTS.CommonCore/Interface/Channels/ChannelCodes/IChannelCodesListViewModel.cs
- Common/DTS.CommonCore/Interface/Channels/ChannelCodes/IChannelCode.cs
generated_at: "2026-04-17T16:35:31.488668+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "c5ac64d4a1bfdb6b"
---
# Documentation: DTS.Common.Interface.Channels.ChannelCodes
## 1. Purpose
This module defines the contract for a channel code management UI component within the DTS system. It provides interfaces for displaying, editing, and validating both ISO-standard and user-defined channel codes through a list-based view. The module separates concerns between the view (`IChannelCodesListView`), the view model (`IChannelCodesListViewModel`), and the individual data items (`IChannelCode`), enabling a Model-View-ViewModel (MVVM) architecture for channel code configuration.
---
## 2. Public Interface
### `IChannelCodesListView`
**Signature:** `public interface IChannelCodesListView : IBaseView`
A marker interface extending `IBaseView` with no additional members. Represents the view abstraction for the channel codes list UI.
---
### `IChannelCodesListViewModel`
**Signature:** `public interface IChannelCodesListViewModel : IBaseViewModel`
The primary interface for managing channel code lists.
**Properties:**
| Property | Type | Description |
|----------|------|-------------|
| `View` | `IChannelCodesListView` | Gets or sets the associated view instance. |
| `ISOChannelCodes` | `ObservableCollection<IChannelCode>` | Collection of ISO channel codes displayed in the UI. |
| `UserChannelCodes` | `ObservableCollection<IChannelCode>` | Collection of user-defined channel codes displayed in the UI. |
| `ChannelCodesFunc` | `Func<IList<IChannelCode>>` | A function delegate that returns a list of channel codes. |
| `ShowISOStringBuilder` | `bool` | Controls visibility of the ISO string builder UI element. |
| `UniqueISOCodesRequired` | `bool` | Indicates whether ISO codes must be unique. |
| `ShowChannelCodeLookupHelper` | `bool` | Controls visibility of the channel code lookup helper UI element. |
| `IsReadOnly` | `bool` | Controls whether the UI is in read-only mode. |
| `SelectedCodes` | `IChannelCode[]` | Returns an array of currently selected channel codes. |
**Methods:**
| Method | Signature | Description |
|--------|-----------|-------------|
| `Unset` | `void Unset()` | Clears or resets the view model state. |
| `SetPage` | `void SetPage(object page)` | Associates a page object with the view model. |
| `OnSetActive` | `void OnSetActive()` | Called when the view becomes active. |
| `Save` | `bool Save()` | Persists changes; returns success status. |
| `Validate` | `bool Validate(bool bDisplayWindow)` | Validates the current state; `bDisplayWindow` controls whether validation errors are shown in a UI window. |
| `CopySelected` | `void CopySelected()` | Copies the currently selected channel codes. |
| `DeleteSelected` | `void DeleteSelected()` | Deletes the currently selected channel codes. |
| `Filter` | `void Filter(object columnTag, string searchTerm)` | Filters the displayed items based on a column tag and search term. |
| `Sort` |

View File

@@ -0,0 +1,61 @@
---
source_files:
- Common/DTS.CommonCore/Interface/CheckChannels/ICheckChannelsView.cs
- Common/DTS.CommonCore/Interface/CheckChannels/ICheckChannelsViewModel.cs
- Common/DTS.CommonCore/Interface/CheckChannels/ICheckChannelsMenuView.cs
- Common/DTS.CommonCore/Interface/CheckChannels/ICheckChannelsMenuViewModel.cs
generated_at: "2026-04-17T16:34:43.911097+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "3147d34744b82543"
---
# Documentation: CheckChannels Interfaces
## 1. Purpose
This module defines four marker interfaces for the CheckChannels feature within the DTS application, following the Model-View-ViewModel (MVVM) architectural pattern. These interfaces establish contracts for View and ViewModel components, separating the main CheckChannels view from its Ribbon-based menu interface. They serve as extension points for type identification, dependency injection, and navigation registration within the broader system.
---
## 2. Public Interface
### `ICheckChannelsView`
- **Namespace:** `DTS.Common.Interface`
- **Inherits from:** `DTS.Common.Base.IBaseView`
- **Signature:** `public interface ICheckChannelsView : IBaseView { }`
- **Description:** Marker interface for the primary CheckChannels view. Defines no additional members beyond its base interface.
### `ICheckChannelsViewModel`
- **Namespace:** `DTS.Common.Interface`
- **Inherits from:** `DTS.Common.Base.IBaseViewModel`
- **Signature:** `public interface ICheckChannelsViewModel : IBaseViewModel { }`
- **Description:** Marker interface for the CheckChannels ViewModel. Defines no additional members beyond its base interface.
### `ICheckChannelsMenuView`
- **Namespace:** `DTS.Common.Interface`
- **Inherits from:** `DTS.Common.RibbonControl.IRibbonView`
- **Signature:** `public interface ICheckChannelsMenuView : IRibbonView { }`
- **Description:** Marker interface for the CheckChannels Ribbon menu view. Defines no additional members beyond its base interface.
### `ICheckChannelsMenuViewModel`
- **Namespace:** `DTS.Common.Interface`
- **Inherits from:** `DTS.Common.RibbonControl.IRibbonViewModel`
- **Signature:** `public interface ICheckChannelsMenuViewModel : IRibbonViewModel { }`
- **Description:** Marker interface for the CheckChannels Ribbon menu ViewModel. Defines no additional members beyond its base interface.
---
## 3. Invariants
- All four interfaces are marker interfaces with no additional members; any invariants must be defined by their respective base interfaces (`IBaseView`, `IBaseViewModel`, `IRibbonView`, `IRibbonViewModel`).
- The View/ViewModel pairing convention implies that `ICheckChannelsView` should be paired with `ICheckChannelsViewModel`, and `ICheckChannelsMenuView` should be paired with `ICheckChannelsMenuViewModel`.
- The separation of "Menu" interfaces suggests a distinction between the main view and a Ribbon-specific menu view, but specific behavioral constraints are not defined in these interfaces.
---
## 4. Dependencies
### This module depends on:
- `DTS.Common.Base` — provides `IBaseView` and `IBaseViewModel` base interfaces
- `DTS.Common.RibbonControl` — provides `IRibbonView` and `IRibbonViewModel`

View File

@@ -0,0 +1,47 @@
---
source_files:
- Common/DTS.CommonCore/Interface/CheckTrigger/ICheckTriggerView.cs
- Common/DTS.CommonCore/Interface/CheckTrigger/ICheckTriggerViewModel.cs
generated_at: "2026-04-17T16:36:18.184208+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "a2e651bebe370a84"
---
# Documentation: ICheckTriggerView and ICheckTriggerViewModel
## 1. Purpose
This module defines two marker interfaces—`ICheckTriggerView` and `ICheckTriggerViewModel`—that establish the View and ViewModel contracts for a "CheckTrigger" feature within an MVVM (Model-View-ViewModel) architecture. These interfaces serve as type identifiers, inheriting from base framework interfaces (`IBaseView` and `IBaseViewModel` respectively) without adding additional members. They exist to enable type-safe binding, dependency injection, or navigation registration within the DTS.CommonCore system.
## 2. Public Interface
### `ICheckTriggerView`
- **Signature:** `public interface ICheckTriggerView : IBaseView { }`
- **Namespace:** `DTS.Common.Interface`
- **Behavior:** Empty marker interface extending `IBaseView`. Provides no additional members beyond those inherited from `IBaseView`. Intended to be implemented by View components associated with CheckTrigger functionality.
### `ICheckTriggerViewModel`
- **Signature:** `public interface ICheckTriggerViewModel : IBaseViewModel { }`
- **Namespace:** `DTS.Common.Interface`
- **Behavior:** Empty marker interface extending `IBaseViewModel`. Provides no additional members beyond those inherited from `IBaseViewModel`. Intended to be implemented by ViewModel components associated with CheckTrigger functionality.
## 3. Invariants
- Any class implementing `ICheckTriggerView` must also satisfy the contract of `IBaseView` (defined in `DTS.Common.Base`).
- Any class implementing `ICheckTriggerViewModel` must also satisfy the contract of `IBaseViewModel` (defined in `DTS.Common.Base`).
- The actual member requirements for these interfaces are determined entirely by their base interfaces, which are not shown in the provided source.
## 4. Dependencies
### This module depends on:
- `DTS.Common.Base` — Provides `IBaseView` and `IBaseViewModel` base interfaces.
### What depends on this module:
- **Unclear from source alone.** Consumers would include any View or ViewModel classes implementing these interfaces, as well as any navigation, routing, or dependency injection infrastructure that registers or resolves these types.
## 5. Gotchas
- **Marker interfaces with no members:** Neither interface defines any properties, methods, or events. All contractual behavior is inherited from `IBaseView` and `IBaseViewModel`. Developers implementing these interfaces must consult the base interface definitions to understand required members.
- **Naming convention:** The "CheckTrigger" naming suggests a specific feature domain, but the purpose and behavior of this feature cannot be determined from these interface definitions alone.
- **No explicit View-ViewModel pairing:** While the naming suggests these interfaces are paired (View/ViewModel), there is no compile-time enforcement of this relationship in the source.

View File

@@ -0,0 +1,57 @@
---
source_files:
- Common/DTS.CommonCore/Interface/Communication/ICommunicationReport.cs
- Common/DTS.CommonCore/Interface/Communication/IDASConnectedDevice.cs
- Common/DTS.CommonCore/Interface/Communication/ICommunication_DASInfo.cs
generated_at: "2026-04-17T16:35:08.973224+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "2d2df26efcd514a6"
---
# Documentation: DTS.Common.Interface.Communication
## 1. Purpose
This module defines three interfaces for communication-related data structures within the DTS system. `ICommunicationReport` provides a standard contract for communication operation results, encapsulating status, result codes, and payload data. `IDASConnectedDevice` describes hardware devices connected to a Data Acquisition System (DAS), capturing physical and logical identification properties. `ICommunication_DASInfo` aggregates information about a DAS unit itself, including its connected devices, serial numbers, firmware versions, and feature support flags. These interfaces support the auto-discovery and monitoring of DAS hardware status.
---
## 2. Public Interface
### `ICommunicationReport`
A data transfer interface for reporting communication operation outcomes.
| Member | Signature | Description |
|--------|-----------|-------------|
| `UserState` | `object { get; set; }` | Arbitrary user state associated with the communication operation. |
| `Result` | `CommunicationConstantsAndEnums.CommunicationResult { get; set; }` | The result status of the communication operation. |
| `Data` | `byte[] { get; set; }` | Raw byte payload from the communication operation. |
---
### `IDASConnectedDevice`
Describes a device physically connected to a DAS unit (e.g., an S6 connected to an S6DB).
| Member | Signature | Description |
|--------|-----------|-------------|
| `DeviceType` | `HardwareTypes { get; }` | The hardware type classification of the connected device. |
| `Port` | `int { get; }` | The port index on the DAS where the device is connected (0-based). |
| `SpotOnPort` | `int { get; }` | The position in the daisy chain on the given port (0-based). |
| `PhysicalAddress` | `PhysicalAddress { get; }` | The MAC address or physical address of the device. |
| `IPAddress` | `string { get; }` | The IP address of the device. |
| `SerialNumber` | `string { get; }` | The serial number of the device. |
| `Location` | `string { get; }` | The physical location descriptor of the device. |
| `Version` | `string { get; }` | The firmware/hardware version string of the device. |
---
### `ICommunication_DASInfo`
Aggregates metadata and connected device information for a DAS unit.
| Member | Signature | Description |
|--------|-----------|-------------|
| `ConnectedDevices` | `IDASConnectedDevice[] { get; }` | Array of devices currently connected to this D

View File

@@ -0,0 +1,71 @@
---
source_files:
- Common/DTS.CommonCore/Interface/Components/IAssemblyView.cs
- Common/DTS.CommonCore/Interface/Components/IAssemblyListView.cs
- Common/DTS.CommonCore/Interface/Components/ITileView.cs
- Common/DTS.CommonCore/Interface/Components/IGroupView.cs
- Common/DTS.CommonCore/Interface/Components/ITileListView.cs
- Common/DTS.CommonCore/Interface/Components/IGroupListView.cs
- Common/DTS.CommonCore/Interface/Components/IAssemblyViewModel.cs
- Common/DTS.CommonCore/Interface/Components/IAssemblyListViewModel.cs
- Common/DTS.CommonCore/Interface/Components/ITileViewModel.cs
- Common/DTS.CommonCore/Interface/Components/IGroupViewModel.cs
- Common/DTS.CommonCore/Interface/Components/ITileListViewModel.cs
- Common/DTS.CommonCore/Interface/Components/IGroupListViewModel.cs
generated_at: "2026-04-17T16:34:19.310098+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "e1c9470d04b176fb"
---
# Documentation: View/ViewModel Component Interfaces
## 1. Purpose
This module defines a set of interfaces for a Model-View-ViewModel (MVVM) architecture used to display and manage grouped assembly information in a UI. It provides interfaces for both individual item views (`IAssemblyView`, `ITileView`, `IGroupView`) and collection views (`IAssemblyListView`, `ITileListView`, `IGroupListView`), along with their corresponding ViewModel contracts. The module appears to support multiple presentation modes (Assembly, Tile, Group) for displaying assembly data with associated images.
---
## 2. Public Interface
### View Interfaces
| Interface | Namespace | Base | Description |
|-----------|-----------|------|-------------|
| `IAssemblyView` | `DTS.Common.Interface` | `IBaseView` | Marker interface for an assembly item view. No members defined. |
| `IAssemblyListView` | `DTS.Common.Interface` | `IBaseView` | Marker interface for a collection view of assemblies. No members defined. |
| `ITileView` | `DataPro.Common.Interface` | `IBaseView` | Marker interface for a tile item view. No members defined. |
| `IGroupView` | `DataPro.Common.Interface` | `IBaseView` | Marker interface for a group item view. No members defined. |
| `ITileListView` | `DataPro.Common.Interface` | `IBaseView` | Marker interface for a collection view of tiles. No members defined. |
| `IGroupListView` | `DataPro.Common.Interface` | `IBaseView` | Marker interface for a collection view of groups. No members defined. |
### ViewModel Interfaces
#### `IAssemblyViewModel` (`DTS.Common.Interface`)
```csharp
public interface IAssemblyViewModel : IBaseViewModel
{
IAssemblyView View { get; set; }
string GroupName { get; set; }
List<AssemblyNameImage> AssemblyList { get; set; }
}
```
Defines the contract for a ViewModel that manages a single assembly group display, including the associated view reference, group name, and list of assembly name/image pairs.
#### `IAssemblyListViewModel` (`DTS.Common.Interface`)
```csharp
public interface IAssemblyListViewModel : IBaseViewModel
{
IMainViewModel Parent { get; set; }
IAssemblyListView View { get; set; }
List<IAssemblyView> GroupList { get; set; }
}
```
Defines the contract for a ViewModel that manages a collection of assembly views, with a reference to a parent `IMainViewModel`.
#### `ITileViewModel` (`DataPro.Common.Interface`)
```csharp
public interface ITileViewModel : IBaseViewModel
{
ITileView View { get; set; }
string Group

View File

@@ -0,0 +1,42 @@
---
source_files:
- Common/DTS.CommonCore/Interface/Connection/IConnection.cs
generated_at: "2026-04-17T16:08:23.342605+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "c423b632187ca2f1"
---
# Connection
### Purpose
This module defines the `IConnection` interface, which provides an abstraction layer for network socket connections. It supports both synchronous and asynchronous communication patterns, connection lifecycle management (including a "soft disconnect" state for temporary disconnections with reconnection intent), and server-side operations like binding and listening. The interface extends `IDisposable` to ensure proper resource cleanup.
### Public Interface
**Interface: `IConnection`** (extends `IDisposable`)
| Member | Signature | Description |
|--------|-----------|-------------|
| `SendAsync` | `Task<int> SendAsync(byte[] sendBuffer, int bufferStartOffset, int bufferSizeToSend)` | Asynchronously sends data from the buffer. Returns the number of bytes sent. |
| `IsSoftDisconnected` | `bool IsSoftDisconnected { get; }` | Returns `true` if the unit is soft disconnected (voluntarily disconnected with expectation of reconnecting). |
| `SoftDisconnect` | `void SoftDisconnect()` | Performs a soft disconnect (voluntary disconnect with intention to reconnect later). |
| `SoftConnect` | `void SoftConnect()` | Reconnects a soft disconnected unit. |
| `Flags` | `System.Net.Sockets.SocketFlags Flags { get; set; }` | Gets or sets socket flags for send/receive operations. |
| `OnDisconnected` | `event EventHandler OnDisconnected` | Event raised when the connection is disconnected. |
| `KeepAliveErrorReceived` | `void KeepAliveErrorReceived()` | Called to indicate the device has not received a timely response to keep-alive. |
| `ConnectString` | `string ConnectString { get; }` | Gets the connection string for this connection. |
| `Connected` | `bool Connected { get; }` | Gets whether the connection is currently active. |
| `Create` | `void Create(string connectString)` | Initializes the connection with a connection string. |
| `Create` | `void Create(string connectString, string hostIPAddress)` | Initializes the connection with a connection string and specific host IP address. |
| `GetConnectionData` | `string GetConnectionData()` | Retrieves connection data as a string. |
| `BeginConnect` | `IAsyncResult BeginConnect(AsyncCallback callback, object callbackObject)` | Begins an asynchronous connection attempt. |
| `EndConnect` | `void EndConnect(IAsyncResult ar)` | Completes an asynchronous connection attempt. |
| `BeginDisconnect` | `IAsyncResult BeginDisconnect(bool reuseSocket, AsyncCallback callback, object state)` | Begins an asynchronous disconnection. |
| `EndDisconnect` | `void EndDisconnect(IAsyncResult asyncResult)` | Completes an asynchronous disconnection. |
| `BeginAccept` | `IAsyncResult BeginAccept(AsyncCallback callback, object state)` | Begins an asynchronous operation to accept an incoming connection. |
| `EndAccept` | `IConnection EndAccept(IAsyncResult asyncResult)` | Completes an accept operation and returns the accepted `IConnection`. |
| `Bind` | `void Bind(int port)` | Binds the connection to a specific local port. |
| `Listen` | `void Listen(int backlog)` | Places the connection in a listening state with specified backlog. |
| `BeginSend` | `IAsyncResult BeginSend(byte[] sendBuffer, int bufferStartOffset, int bufferSizeToSend, AsyncCallback callback, object callbackObject)` | Begins an asynchronous send operation. |
| `End

View File

@@ -0,0 +1,35 @@
---
source_files:
- Common/DTS.CommonCore/Interface/CustomChannels/ICustomChannelsView.cs
- Common/DTS.CommonCore/Interface/CustomChannels/ICustomChannelsExportView.cs
- Common/DTS.CommonCore/Interface/CustomChannels/ICustomChannelsImportView.cs
- Common/DTS.CommonCore/Interface/CustomChannels/ICustomChannelModel.cs
- Common/DTS.CommonCore/Interface/CustomChannels/ICustomChannelsViewModel.cs
generated_at: "2026-04-17T16:02:06.150178+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "f946b77217c5883d"
---
# CustomChannels
### Purpose
This module defines the interfaces for a Custom Channels feature, supporting import and export functionality. It follows a Model-View-ViewModel (MVVM) pattern with separate interfaces for views, view models, and models. The interfaces enable selection and management of custom channel configurations that can be imported from or exported to files.
### Public Interface
**ICustomChannelsView** (interface, inherits `IBaseView`)
- Marker interface for the main custom channels view. No additional members beyond `IBaseView`.
**ICustomChannelsExportView** (interface, inherits `IBaseView`)
- Marker interface for the export view. No additional members beyond `IBaseView`.
**ICustomChannelsImportView** (interface, inherits `IBaseView`)
- Marker interface for the import view. No additional members beyond `IBaseView`.
**ICustomChannelModel** (interface)
- `string Name { get; }` - Read-only name of the custom channel.
- `bool Included { get; set; }` - Gets or sets whether this channel is included in the selection.
**ICustomChannelsViewModel** (interface, inherits `IBaseViewModel`)
- `ICustom

View File

@@ -0,0 +1,67 @@
---
source_files:
- Common/DTS.CommonCore/Interface/CustomerDetails/ICustomerDetailsView.cs
- Common/DTS.CommonCore/Interface/CustomerDetails/ICustomerDetailsViewModel.cs
generated_at: "2026-04-17T16:36:39.753469+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "68517ff654ee10bc"
---
# Documentation: Customer Details Interfaces
## 1. Purpose
This module defines two marker interfaces, `ICustomerDetailsView` and `ICustomerDetailsViewModel`, which establish the View and ViewModel contracts for a Customer Details feature within an MVVM (Model-View-ViewModel) architecture. These interfaces extend base framework types (`IBaseView` and `IBaseViewModel`) without adding additional members, serving primarily as type identifiers for dependency injection, navigation, or view-binding purposes within the DTS.CommonCore system.
---
## 2. Public Interface
### `ICustomerDetailsView`
**Namespace:** `DTS.Common.Interface`
**Declaration:**
```csharp
public interface ICustomerDetailsView : IBaseView { }
```
**Description:** A marker interface representing the View component for customer details. Inherits from `IBaseView` (defined in `DTS.Common.Base`). Declares no additional members beyond its base interface.
---
### `ICustomerDetailsViewModel`
**Namespace:** `DTS.Common.Interface`
**Declaration:**
```csharp
public interface ICustomerDetailsViewModel : IBaseViewModel { }
```
**Description:** A marker interface representing the ViewModel component for customer details. Inherits from `IBaseViewModel` (defined in `DTS.Common.Base`). Declares no additional members beyond its base interface.
---
## 3. Invariants
- Both interfaces are empty marker interfaces; any invariants are inherited from their respective base interfaces (`IBaseView` and `IBaseViewModel`).
- **Unclear from source:** The specific contracts, properties, or methods guaranteed by `IBaseView` and `IBaseViewModel` are not defined in the provided source files.
---
## 4. Dependencies
### This module depends on:
- `DTS.Common.Base` namespace
- `IBaseView` — base interface for `ICustomerDetailsView`
- `IBaseViewModel` — base interface for `ICustomerDetailsViewModel`
### What depends on this module:
- **Unclear from source alone.** Consumers would typically include:
- Concrete View implementations (e.g., WPF windows, pages, or user controls implementing `ICustomerDetailsView`)
- Concrete ViewModel implementations implementing `ICustomerDetailsViewModel`
- DI container registrations or navigation service configurations
---
## 5. Gotchas
- **Empty marker interfaces:** Neither interface defines any members. All functionality must come from the base interfaces (`IBaseView`, `IBaseViewModel`) or be added via extension methods elsewhere in the codebase.
- **No explicit contract:** Without visibility into `IBaseView` and `IBaseViewModel`, the actual capabilities and requirements of these interfaces cannot be determined from the provided source.
- **Naming convention:** The interfaces follow a strict naming pattern (`ICustomerDetailsView` / `ICustomerDetailsViewModel`) suggesting a paired relationship, but this pairing is not enforced at the type level.

View File

@@ -0,0 +1,296 @@
---
source_files:
- Common/DTS.CommonCore/Interface/DASFactory/IAutoArmed.cs
- Common/DTS.CommonCore/Interface/DASFactory/ITiltSensorCalAware.cs
- Common/DTS.CommonCore/Interface/DASFactory/IRangeBandwidthLimited.cs
- Common/DTS.CommonCore/Interface/DASFactory/IAutoArmStatus.cs
- Common/DTS.CommonCore/Interface/DASFactory/ITimeSynchronization.cs
- Common/DTS.CommonCore/Interface/DASFactory/IConnectedEthernetDevice.cs
- Common/DTS.CommonCore/Interface/DASFactory/IDASConfigurationArg.cs
- Common/DTS.CommonCore/Interface/DASFactory/IRealtime.cs
- Common/DTS.CommonCore/Interface/DASFactory/IUDPQATSEntry.cs
- Common/DTS.CommonCore/Interface/DASFactory/IDASFactory.cs
- Common/DTS.CommonCore/Interface/DASFactory/ICommunication.cs
- Common/DTS.CommonCore/Interface/DASFactory/IDiscoveredDevice.cs
- Common/DTS.CommonCore/Interface/DASFactory/IAnalogInputDASChannel.cs
- Common/DTS.CommonCore/Interface/DASFactory/IDASCommunication.cs
generated_at: "2026-04-17T15:30:14.944547+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "4752ac593e608823"
---
# DTS.Common.Interface.DASFactory Module Documentation
## 1. Purpose
This module defines the core abstraction layer for Data Acquisition System (DAS) hardware communication, discovery, configuration, and control. It provides interfaces for managing DAS devices (SLICE, TDAS, and related hardware), handling real-time data streaming, configuring analog input channels, and coordinating device discovery and ownership. The module serves as the primary contract between the DTS application and physical data acquisition hardware, enabling hardware-agnostic operations through polymorphic interfaces.
---
## 2. Public Interface
### IAutoArmed
```csharp
public interface IAutoArmed
{
bool AutoArmed { get; set; }
}
```
Simple marker interface exposing an `AutoArmed` boolean property for devices supporting auto-arm functionality.
### ITiltSensorCalAware
```csharp
public interface ITiltSensorCalAware
{
double[] TiltSensorCals { get; }
}
```
Exposes read-only tilt sensor calibration values as a `double[]` array.
### IRangeBandwidthLimited
```csharp
public interface IRangeBandwidthLimited
{
bool RangeBandwidthLimited { get; }
}
```
Read-only property indicating whether the device has range bandwidth limitations.
### IAutoArmStatus
```csharp
public interface IAutoArmStatus
{
DFConstantsAndEnums.CommandStatus AutoArmStatus { get; set; }
}
```
Exposes the auto-arm command status using `DFConstantsAndEnums.CommandStatus` enum.
### ITimeSynchronization
```csharp
public interface ITimeSynchronization
{
bool SupportsTimeSynchronization { get; }
DateTime SystemBaseTime { get; }
}
```
Defines time synchronization capabilities and provides access to the system base time.
### IConnectedEthernetDevice
```csharp
public interface IConnectedEthernetDevice
{
string MACAddress { get; }
int Port { get; }
string SerialNumber { get; set; }
}
```
Represents an ethernet-connected device with MAC address, port, and serial number properties.
### IDASConfigurationArg
```csharp
public interface IDASConfigurationArg
{
IDASCommunication DAS { get; }
bool BlankConfigurationRead { get; }
bool ConfigurationFailedValidation { get; }
}
```
Describes arguments passed to configuration events. Used when performing emergency downloads with DAS units that have blank filestores (per comment reference 17872).
### IRealTime
```csharp
public interface IRealTime
{
List<int> RealtimeDASChannels { get; set; }
List<double> TiltAxisData { get; set; }
string UDPStreamAddress { get; }
}
```
Defines real-time data streaming capabilities including channel selection, tilt axis data (X, Y, Z in degrees), and UDP stream address.
### IUDPQATSEntry
```csharp
public interface IUDPQATSEntry
{
string ResponseHostMac { get; }
string ResponseClientMacAddress { get; }
string SerialNumber { get; }
byte ArmState { get; }
byte ArmMode { get; }
byte Started { get; }
byte Triggered { get; }
byte FaultFlags { get; }
uint SampleRate { get; }
ulong TotalSamples { get; }
ulong CurrentSample { get; }
ushort EventNumber { get; }
ulong FaultSampleNumber { get; }
ushort LegacyFaultFlags { get; }
float InputVoltage { get; }
float BackupVoltage { get; }
float BatterySOC { get; }
ulong EstimateMaxSamples { get; }
short TiltSensorCh1 { get; }
short TiltSensorCh2 { get; }
short TiltSensorCh3 { get; }
float SysTempC { get; }
byte SyncClockEnable { get; }
byte ADCExtClockSyncEnable { get; }
byte SyncClockStatus { get; }
byte ADCExtClockSyncStatus { get; }
ulong EventTriggerSample { get; }
float[] ChannelOffsetMV { get; }
float[] ShuntDeviationPercent { get; }
DateTime Timestamp { get; }
}
```
Comprehensive interface representing UDP QATS (Quick Acquisition/Transfer System) entry data, exposing hardware status including arm state, trigger state, sample rates, voltages, battery state, tilt sensor readings, temperature, clock synchronization status, and channel calibration data.
### IDASFactory
```csharp
public interface IDASFactory
{
bool PingAll();
string Language { get; set; }
void TakeOwnership();
bool AllowSDBCommandPort { get; set; }
double S6ConnectNewTimeout { get; set; }
string[] SliceDBHostNames { get; set; }
string[] GetConnectedDevices();
string[] TDASHostNames { get; set; }
string[] TDASSerialPortNames { get; set; }
string TDASSerialRackSerialNumber { get; set; }
List<IDASCommunication> GetDASList();
List<IDASCommunication> GetSortedDASList();
List<ICommunication> GetDevList();
void DetachAllDevices(bool detachUSB = false);
void Refresh(ActionCompleteDelegate action);
int MultiCastAutoDiscoveryDefaultTimeoutMS { get; set; }
SortableBindingList<IDiscoveredDevice> AutoDiscoverMulticast(bool discoverParents = true);
}
```
Factory interface for managing DAS device lifecycle: discovery, ownership, connection management, and device enumeration.
### ICommunication
```csharp
public interface ICommunication : IComparable<ICommunication>, IComparable<string>
{
IConnection Transport { get; set; }
void SetupReader();
int ReceiveBufferSize { get; set; }
string SerialNumber { get; set; }
string FirmwareVersion { get; set; }
byte ProtocolVersion { get; set; }
ICommunication_DASInfo DASInfo { get; set; }
Dictionary<DFConstantsAndEnums.ProtocolLimitedCommands, byte> MinimumProtocols { get; set; }
void InitMinProto();
bool IsCommandSupported(DFConstantsAndEnums.ProtocolLimitedCommands command);
byte GetMinProto(DFConstantsAndEnums.ProtocolLimitedCommands command);
event EventHandler OnDisconnected;
string ConnectString { get; }
bool Connected { get; }
void Connect(string ConnectString, CommunicationConstantsAndEnums.CommunicationCallback Callback, object CallbackObject, int CallbackTimeout, string ipAddress);
void Disconnect(bool reuseSocket, CommunicationConstantsAndEnums.CommunicationCallback Callback, object CallbackObject, int CallbackTimeout);
void Close(int Timeout);
void Flush(int Timeout);
bool ExecuteIsBusy { get; set; }
void Execute(byte[] byteData, CommunicationConstantsAndEnums.CommunicationCallback Callback, object CallbackObject, int CallbackTimeout);
void PseudoExecute(byte[] byteData, CommunicationConstantsAndEnums.CommunicationCallback Callback, object CallbackObject, int CallbackTimeout);
byte[] SyncExecute(byte[] byteData, int Timeout);
void Cancel();
void ForceCancel();
bool IsCanceled();
void ClearCancel();
ManualResetEvent CancelEvent { get; }
}
```
Core communication interface for hardware-level message exchange. Supports both asynchronous (callback-based) and synchronous execution patterns, with cancellation support via `ManualResetEvent`.
### IDiscoveredDevice
```csharp
public interface IDiscoveredDevice
{
string Serial { get; set; }
MultiCastDeviceClasses DevClass { get; set; }
string Mac { get; set; }
IDiscoveredDevice Parent { get; set; }
bool IsParent(IDiscoveredDevice possibleChild);
int GetPort(IDiscoveredDevice device);
int GetSlot(IDiscoveredDevice child, Dictionary<string, IDiscoveredDevice> lookup);
int GetSlotOnPort(IDiscoveredDevice child, Dictionary<string, IDiscoveredDevice> lookup);
bool IsModule { get; set; }
int Port { get; set; }
int PositionOnDistributor { get; set; }
int PositionOnChain { get; set; }
bool Dhcp { get; set; }
string Ip { get; set; }
string Subnet { get; set; }
string Gateway { get; set; }
string Dns { get; set; }
bool Connected { get; set; }
string ConnectedIp { get; set; }
string ConnectedHost { get; set; }
ushort SystemId { get; set; }
string Location { get; set; }
string FirmwareVersion { get; set; }
string BuildId { get; set; }
IConnectedEthernetDevice[] Connections { get; set; }
}
```
Represents a network-discovered device with full topology information including parent/child relationships, network configuration, and connection status.
### IAnalogInputDASChannel
```csharp
public interface IAnalogInputDASChannel
{
SensorConstants.BridgeType TypeOfBridge { get; set; }
int ShuntTargetADC { get; set; }
SensorConstants.BridgeType[] SupportedBridges { get; set; }
DigitalInputModes[] SupportedDigitalInputModes { get; set; }
SensorConstants.CouplingModes CouplingMode { get; set; }
double BridgeResistanceOhms { get; set; }
double ZeroPoint { get; set; }
double SensorCapacityEU { get; set; }
double SensorCapacity { get; set; }
string SensorPolarity { get; set; }
double DesiredRangeWithHeadroomEU { get; set; }
double SensitivityMilliVoltsPerEU { get; set; }
double SensitivityMilliVoltsPerEUNormalized { get; }
bool IsProportionalToExcitation { get; set; }
bool IsSupported(ExcitationVoltageOptions.ExcitationVoltageOption o);
bool IsInverted { get; set; }
string OriginalChannelName { get; set; }
string ChannelName2 { get; set; }
string ChannelId { get; set; }
string ChannelGroupName { get; set; }
string HardwareChannelName { get; set; }
string DIUnits { get; set; }
DigitalInputModes DigitalMode { get; set; }
DTS.Common.Classes.Sensors.LinearizationFormula LinearizationFormula { get; set; }
ExcitationVoltageOptions.ExcitationVoltageOption Excitation { get; set; }
ExcitationVoltageOptions.ExcitationVoltageOption[] SupportedExcitation { get; set; }
string EngineeringUnits { get; set; }
string SerialNumber { get; set; }
string Manufacturer { get; set; }
string Model { get; set; }
string Description { get; set; }
ZeroMethodType ZeroMethod { get; set; }
double ZeroAverageStartSeconds { get; set; }
double ZeroAverageStopSeconds { get; set; }
double InitialEU { get; set; }
string InitialOffset { get; set; }
bool Unipolar { get; set; }
bool ShuntIsEnabled { get; set; }
short ZeromVInADC { get; set; }
bool VoltageInsertionCheckEnabled { get; set; }
bool IEPEChannel { get; set; }
bool DigitalInputChannel { get; set; }
bool CalSignalIsEnabled { get; set; }
bool RemoveOffset { get; set; }
bool VerifyOffset { get; set; }
double OffsetToleranceLowMilliVolts { get; set; }
double OffsetToleranceHighMilliVolts { get; set; }
DateTime LastCalibrationDate { get; set; }
DateTime CalDueDate { get; set; }
string ISOCode { get;

View File

@@ -0,0 +1,65 @@
---
source_files:
- Common/DTS.CommonCore/Interface/DASFactory/ARM/IArmStatus.cs
- Common/DTS.CommonCore/Interface/DASFactory/ARM/IArmStatusData.cs
generated_at: "2026-04-17T16:37:00.691878+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "a74fab277087c73b"
---
# Documentation: DTS.CommonCore.Interface.DASFactory.ARM
## 1. Purpose
This module defines two interfaces—`IArmStatus` and `IArmStatusData`—that model the operational state of a DAS (Data Acquisition System) unit. `IArmStatus` provides the behavioral contract for transitioning a unit between Arm and Realtime modes, while `IArmStatusData` serves as a data transfer object capturing the complete status snapshot of a DAS unit, including armed/triggered/recording states, timing information, sample counts, voltage readings, and fault conditions. These interfaces abstract the ARM status management layer from concrete hardware implementations.
---
## 2. Public Interface
### `IArmStatus` (interface)
**Methods:**
| Signature | Description |
|-----------|-------------|
| `void SetInArm(bool WriteToDb)` | Marks the unit as being in Arm mode. Optionally persists state to database based on `WriteToDb` parameter. |
| `void SetInRealtime(bool WriteToDb, bool ExitRealtimeIfPossible)` | Marks the unit as being in Realtime mode. Optionally persists to database and conditionally exits realtime mode. |
| `bool GetIsInArm()` | Returns `true` if the unit is known to be in Arm. Does not query hardware—returns cached flag state only. |
| `bool GetIsInRealtime()` | Returns `true` if the unit is known to be in Realtime. Does not query hardware—returns cached flag state only. |
| `bool GetIsStreaming()` | Returns `true` if the unit is known to be streaming. Does not query hardware—returns cached flag state only. |
| `void SetDASArmStatus(IArmStatusData status, bool bSetInDb)` | Sets `DASArmStatus` property and optionally persists to database. |
| `void SetDASArmStatus()` | Persists current `DASArmStatus` to database (if connected). |
**Properties:**
| Property | Type | Description |
|----------|------|-------------|
| `DASArmStatus` | `IArmStatusData` | Gets or sets the current ARM status data object. |
---
### `IArmStatusData` (interface)
**State Flags (Boolean Properties):**
| Property | Description |
|----------|-------------|
| `ReceivedInvalidModeDuringSetup` | Indicates unit received `InvalidMode` response to query commands during initial setup. Used to detect streaming state (related to issue 15932). |
| `IsArmed` | Indicates whether the DAS is currently armed. |
| `IsTriggered` | Indicates whether the DAS has sensed a trigger. Set in multiple locations. |
| `IsTriggerShorted` | Indicates trigger was shorted. Only set during `TriggerCheck`. Distinct from `IsTriggered`. |
| `IsStartShorted` | Indicates start trigger was shorted. Only set during `TriggerCheck`. |
| `IsRecording` | Indicates whether the DAS is currently recording sample data. |
| `IsFaulted` | Indicates whether the DAS has faulted. |
| `IsInRealtime` | Indicates whether the DAS is in real-time mode. |
| `IsInFlashWrite` | Indicates whether the DAS is in flash write mode (G5-specific). |
| `IsUndefined` | Used when `TDAS ARM STAT READ` returns nothing. |
| `IsInPostTestDiagnostics` | Indicates whether the DAS is in post-test diagnostics. |
| `IsRearming` | Indicates whether the DAS is currently rearming. |
| `HasBeenRecording` | Indicates whether the DAS has been recording at some point. |
**Timing & Progress Properties:**
| Property | Type | Description |

View File

@@ -0,0 +1,149 @@
---
source_files:
- Common/DTS.CommonCore/Interface/DASFactory/Config/IEID.cs
- Common/DTS.CommonCore/Interface/DASFactory/Config/IVoltageInsertionEnabled.cs
- Common/DTS.CommonCore/Interface/DASFactory/Config/IInformation.cs
- Common/DTS.CommonCore/Interface/DASFactory/Config/IConfigurationData.cs
- Common/DTS.CommonCore/Interface/DASFactory/Config/IConfiguration.cs
- Common/DTS.CommonCore/Interface/DASFactory/Config/IInfoResultModule.cs
- Common/DTS.CommonCore/Interface/DASFactory/Config/IDASChannel.cs
- Common/DTS.CommonCore/Interface/DASFactory/Config/IInfoResult.cs
- Common/DTS.CommonCore/Interface/DASFactory/Config/IDASModule.cs
generated_at: "2026-04-17T15:32:19.088231+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "9d6b732bd258d118"
---
# DTS.Common.Interface.DASFactory.Config Documentation
## 1. Purpose
This module defines the core configuration interfaces for a Data Acquisition System (DAS). It provides abstractions for hardware configuration, module management, channel configuration, and device information retrieval. These interfaces enable the system to configure, serialize, and interact with DAS hardware components—including modules, channels, and EIDs (Electronic IDs)—in a hardware-agnostic manner, supporting operations such as test setup, recording configuration, channel mapping, and XML-based configuration persistence.
---
## 2. Public Interface
### IEID
**Namespace:** `DTS.Common.Interface.DASFactory.Config`
Represents an Electronic ID with validation capability.
| Member | Type | Description |
|--------|------|-------------|
| `ID` | `string` | Gets or sets the identifier string. |
| `Blob` | `byte[]` | Gets or sets the binary data associated with the EID. |
| `IsValid()` | `bool` | Validates the EID data. |
---
### IVoltageInsertionEnabled
**Namespace:** `DTS.Common.Interface.DASFactory.Config`
Indicates whether voltage insertion was detected as being enabled.
| Member | Type | Description |
|--------|------|-------------|
| `VoltageInsertionEnabled` | `bool` | Read-only property indicating voltage insertion status. |
---
### IInformation
**Namespace:** `DTS.Common.Interface.DASFactory.Config`
Provides information interface for an `IDASCommunication` object.
| Member | Type | Description |
|--------|------|-------------|
| `DASInfo` | `IInfoResult` | Gets or sets the DAS info populated from hardware values. |
| `SetDASInfo(IInfoResult dasInfo, bool bSetInDb = true)` | `void` | Sets the DAS info with optional database persistence. |
| `SetDASInfo()` | `void` | Sets the DAS info (overload without parameters). |
---
### IConfigurationData
**Namespace:** `DTS.Common.Interface.DASFactory.Config`
Contains the pre-test setup and configuration of all modules and channels in the DAS hardware.
| Member | Type | Description |
|--------|------|-------------|
| `Modules` | `IDASModule[]` | Array of Module objects in the DAS. |
| `IDs` | `IEID[]` | EIDs for the whole DAS. |
| `TestID` | `string` | ID of the current test/event. |
| `TestSetupUniqueId` | `string` | Unique ID for the test setup. |
| `Description` | `string` | Description of the current test/event. |
| `ClearSetup` | `bool` | Flag to clear setup. |
| `DisplayOrder` | `int[]` | Gets or sets the display order array. |
| `DasDisplayOrder` | `int` | Gets or sets the DAS display order. |
| `UDPReceiveAddress` | `string` | Address the DAS receives UDP information from (for OBR-DDR control). |
| `NumberOfConfiguredChannels()` | `int` | Returns count of channels where `IsConfigured` is `true`. |
| `NumberOfChannels()` | `int` | Returns total channel count regardless of configuration. |
| `NumberOfDownloadChannels()` | `int` | Returns count of downloadable channels (excludes UART and StreamOut). |
| `GetDisplayOrder(uint channelIdx)` | `int` | Gets display order for a specific channel index. |
| `WriteXml(XmlWriter writer)` | `void` | Serializes configuration to XML. |
| `ReadXml(XmlReader reader)` | `void` | Deserializes configuration from XML. |
| `GetSchema()` | `XmlSchema` | Returns the XML schema. |
---
### IConfiguration
**Namespace:** `DTS.Common.Interface.DASFactory.Config`
Main configuration interface for DAS device settings.
| Member | Type | Description |
|--------|------|-------------|
| `TestDirectory` | `string` | Path where the device stores test information. |
| `SupportsAutoDetect` | `bool` | Returns `true` if unit supports channel type auto-detection (bridge/IEPE). |
| `ConfigData` | `IConfigurationData` | Gets or sets the configuration data object. |
| `DASClockSyncProfile` | `ClockSyncProfile` | Gets or sets the clock sync profile for the hardware. |
| `QueryConnectedDevices()` | `void` | Directly queries if any devices are connected to this unit. |
| `GetDASDisplayOrder()` | `int` | Returns display order for this DAS (default: -1). |
| `GetChannelDisplayOrder()` | `int[]` | Returns display order array for channels. |
| `SetDASDisplayOrder(int order)` | `void` | Sets DAS display order (should only be called from FWTU). |
| `SetChannelDisplayOrder(int[] order)` | `void` | Sets channel display order (should only be called from FWTU). |
---
### IInfoResult
**Namespace:** `DTS.Common.Interface.DASFactory.Config`
Contains DAS information populated from hardware, including channel mapping utilities.
| Member | Type | Description |
|--------|------|-------------|
| `MACAddress` | `string` | MAC address of the DAS. |
| `Modules` | `IInfoResultModule[]` | Array of modules in this DAS. |
| `ActiveExternalTilts` | `List<ExternalTilt>` | List of active external tilt sensors. |
| `MaxNumberOfModules` | `uint` | Maximum number of modules supported. |
| `MaxEventStorageSpaceInBytes` | `ulong?` | Total sample storage bytes (null if per-module). |
| `NumberOfBytesPerSampleClock` | `uint?` | Bytes stored per sample clock (null if per-module). |
| `DeviceStreamingOnly` | `bool?` | Whether device is hardware-configured for streaming only (null if unsupported). |
| `NumberOfBridgeChannels` | `int` | Number of bridge channels. |
| `BatteryID` | `IEID` | EID for the battery. |
| `HasBattery` | `bool` | Returns `true` if a battery is present. |
| `CalibrationDate` | `DateTime?` | Returns calibration datetime (1970-01-01 indicates invalid/NA). |
| `MapDASChannelNumber2RealtimeChannelNumber(int channelNumber)` | `byte` | Maps DAS channel number to realtime channel number. |
| `MapDASChannelNumber2ModuleArrayIndex(int channelNumber)` | `byte` | Maps DAS channel (0..29) to module array index (0..9). |
| `MapDASChannelNumber2ModuleDeviceID(int channelNumber)` | `byte` | Maps DAS channel (0..29) to module device ID (1..10). |
| `MapDASChannelNumber2ModuleChannelNumber(int channelNumber)` | `byte` | Maps DAS channel (0..29) to module channel (0..2). |
| `MapModuleArrayIndexAndChannelNum2DASChannel(int moduleArrayIdx, int channelNumber)` | `byte` | Maps module index (0..9) and channel (0..2) to DAS channel (0..29). |
---
### IInfoResultModule
**Namespace:** `DTS.Common.Interface.DASFactory.Config`
Contains module-specific information retrieved from hardware.
| Member | Type | Description |
|--------|------|-------------|
| `SerialNumber` | `string` | Serial number of this module. |
| `FirmwareVersion` | `string` | Firmware version. |
| `ModuleArrayIndex` | `int` | Index of this module in an array (0-based). |
| `NumberOfChannels` | `uint` | Number of channels connected to this module. |
| `SupportedSampleRates` | `uint[]` | Supported sample rates in samples per second. |
| `SampleRate2AAFrequency` | `Dictionary<uint, float>` | Maps sample rates to anti-aliasing filter frequencies. |
| `MaxEventStorageSpaceInBytes` |

Some files were not shown because too many files have changed in this diff Show More