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,82 @@
---
source_files:
- Common/DTS.CommonCore/Interface/Sensors/SensorSettingsModule/ISensorSettingsView.cs
- Common/DTS.CommonCore/Interface/Sensors/SensorSettingsModule/ICalibrationPolicy.cs
- Common/DTS.CommonCore/Interface/Sensors/SensorSettingsModule/ISensorSettingsViewModel.cs
generated_at: "2026-04-16T12:23:47.884836+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "1a993886a7ce02c0"
---
# Documentation: Sensor Settings Module Interfaces
## 1. Purpose
This module defines the core contracts for the Sensor Settings configuration UI within the DTS application. It establishes a Model-View-ViewModel (MVVM) architecture for managing sensor-related defaults, specifically handling calibration policies, digital I/O, squib settings, and analog/IEPE sensor configurations. The module provides the interface layer for persisting these settings to a database (associated with a specific user) and for importing/exporting calibration data via XML.
## 2. Public Interface
### `ISensorSettingsView`
* **Namespace:** `DTS.Common.Interface.Sensors.SensorSettingsModule`
* **Inheritance:** `DTS.Common.Base.IBaseView`
* **Description:** A marker interface representing the View in the MVVM pattern. It defines no specific members beyond those inherited from `IBaseView`.
### `ICalibrationPolicy`
* **Namespace:** `DTS.Common.Interface.Sensors.SensorSettingsModule`
* **Description:** Defines the contract for managing sensor calibration settings, including policy selection and XML serialization.
* **Properties:**
* `SensorConstants.SensorCalPolicy SelectedCalPolicy { get; set; }`: Gets or sets the currently active calibration policy.
* `SensorConstants.SensorCalPolicy[] AvailableSensorCalPolicies { get; }`: Gets an array of all valid calibration policies available for selection.
* `int WarningPeriod { get; set; }`: Gets or sets the warning period (in days) before calibration is due.
* `bool UseSensorFirstUseDate { get; set; }`: Gets or sets a flag indicating if the calibration interval starts from the first use date rather than the calibration date.
* **Methods:**
* `void ReadXML(System.Xml.XmlElement root)`: Imports calibration settings from an XML element.
* `void WriteXML(ref System.Xml.XmlWriter writer)`: Exports calibration settings using an XML writer.
### `ISensorSettingsViewModel`
* **Namespace:** `DTS.Common.Interface.Sensors.SensorSettingsModule`
* **Inheritance:** `DTS.Common.Base.IBaseViewModel`
* **Description:** Defines the behavior and state management for the Sensor Settings view, acting as the bridge between the UI and the data model.
* **Properties:**
* `string User { get; set; }`: The username context for saving/reading settings.
* `int UserID { get; set; }`: The user ID context for saving/reading settings.
* `ISensorSettingsView View { get; set; }`: The associated View instance.
* `ISquibSettingDefaults SquibSettings { get; set; }`: Accessor for squib setting defaults.
* `IDigitalOutDefaults DigitalOutSettings { get; set; }`: Accessor for digital output defaults.
* `IDigitalInputDefaults DigitalInputDefaults { get; set; }`: Accessor for digital input defaults.
* `IIEPESensorDefaults IEPESensorDefaults { get; set; }`: Accessor for IEPE sensor defaults.
* `ICalibrationPolicy SensorCalibrationDefaults { get; set; }`: Accessor for calibration policy defaults.
* `IAnalogDefaults AnalogDefaults { get; set; }`: Accessor for analog defaults (referenced as FB 13120).
* **Methods:**
* `void RestoreOriginalSettings()`: Reverts all settings to their original state.
* `void Unset()`: Uninitializes the display and frees resources.
* `void OnSetActive()`: Initializes the display when the view becomes active.
* `bool ValidateAndSave()`: Validates current settings and persists them if valid. Returns `true` if successful, `false` otherwise.
## 3. Invariants
* **Validation Guarantees:** The `ValidateAndSave()` method on `ISensorSettingsViewModel` must return `false` if settings are invalid, and it must *not* persist invalid settings.
* **Unit Consistency:** The `WarningPeriod` in `ICalibrationPolicy` is explicitly defined in **days**.
* **Lifecycle:** `OnSetActive()` is intended for initialization, while `Unset()` is intended for cleanup/resource freeing.
* **Context Requirement:** Database operations rely on `User` and `UserID` properties being set correctly within the `ISensorSettingsViewModel`.
## 4. Dependencies
### Internal Dependencies
* **`DTS.Common.Base`**: Required for `IBaseView` and `IBaseViewModel` interfaces.
* **`DTS.Common.Enums.Sensors`**: Required for the `SensorConstants.SensorCalPolicy` enum used in `ICalibrationPolicy`.
### External Dependencies
* **`System.Xml`**: Used for XML serialization features (`XmlElement`, `XmlWriter`) in `ICalibrationPolicy`.
### Referenced Types (Definitions not provided in source)
The following interfaces are referenced as properties in `ISensorSettingsViewModel` but their definitions are not included in the provided source files:
* `ISquibSettingDefaults`
* `IDigitalOutDefaults`
* `IDigitalInputDefaults`
* `IIEPESensorDefaults`
* `IAnalogDefaults`
## 5. Gotchas
* **`ref` keyword in `WriteXML`:** The `WriteXML` method in `ICalibrationPolicy` passes `System.Xml.XmlWriter` by reference (`ref`). This is unusual for a writer object (which is a reference type) and implies the method might replace the writer instance or is adhering to a legacy signature constraint.
* **Empty View Interface:** `ISensorSettingsView` defines no members. Developers should expect all specific view capabilities to be defined by the `IBaseView` parent or the concrete implementation.
* **Mixed Responsibilities in `ValidateAndSave`:** The `ValidateAndSave` method combines validation logic with persistence logic (side effects). Callers should be aware that calling this method triggers a database write operation upon success; it is not a pure validation check.

View File

@@ -0,0 +1,304 @@
---
source_files:
- Common/DTS.CommonCore/Interface/Sensors/SensorsList/ISensorsListOverdueView.cs
- Common/DTS.CommonCore/Interface/Sensors/SensorsList/ISensorTemplatesExportView.cs
- Common/DTS.CommonCore/Interface/Sensors/SensorsList/ISensorsTemplatesImportView.cs
- Common/DTS.CommonCore/Interface/Sensors/SensorsList/ISensorTemplatesViewModel.cs
- Common/DTS.CommonCore/Interface/Sensors/SensorsList/ISensorsListView.cs
- Common/DTS.CommonCore/Interface/Sensors/SensorsList/ISensorsListEditGroupView.cs
- Common/DTS.CommonCore/Interface/Sensors/SensorsList/IDragAndDropItem.cs
- Common/DTS.CommonCore/Interface/Sensors/SensorsList/ISquib.cs
- Common/DTS.CommonCore/Interface/Sensors/SensorsList/ISensorsListEditGroupViewModel.cs
- Common/DTS.CommonCore/Interface/Sensors/SensorsList/IStreamInputSetting.cs
- Common/DTS.CommonCore/Interface/Sensors/SensorsList/ISensorsListViewModel.cs
- Common/DTS.CommonCore/Interface/Sensors/SensorsList/IUartIOSetting.cs
- Common/DTS.CommonCore/Interface/Sensors/SensorsList/IDigitalInputSetting.cs
- Common/DTS.CommonCore/Interface/Sensors/SensorsList/IDigitalOutputSetting.cs
- Common/DTS.CommonCore/Interface/Sensors/SensorsList/IStreamOutputSetting.cs
- Common/DTS.CommonCore/Interface/Sensors/SensorsList/IAnalogSensor.cs
generated_at: "2026-04-16T12:25:06.358541+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "843b21a9981849bf"
---
# Documentation: DTS.Common.Interface.Sensors.SensorsList
## 1. Purpose
This module defines the contract layer for the sensor management subsystem within DTS. It provides interfaces for various sensor types (Analog, Squib, Digital I/O, UART, Stream I/O) used in UI presentation, along with View and ViewModel interfaces following an MVP/MVC pattern. The module enables sensor listing, editing, filtering, import/export functionality, and drag-and-drop operations between sensor lists. These abstractions decouple the presentation layer from concrete sensor implementations.
---
## 2. Public Interface
### View Interfaces
#### `ISensorsListView : IBaseView`
- `void HandleColumns(CalibrationBehaviors calibrationBehavior)` — Configures columns based on calibration behavior.
- `void SetIncludedVisible(bool bUsesIncludeColumn)` — Controls visibility of the "Included" column.
#### `ISensorsListEditGroupView : IBaseView`
- `void HandleColumns()` — Handles adding/removing columns before view display. (Reference: Case 13065 - Sensor "First Use" Date)
#### `ISensorsListOverdueView : IBaseView`
- Marker interface with no members.
#### `ISensorTemplatesExportView : IBaseView`
- Marker interface with no members.
#### `ISensorsTemplatesImportView : IBaseView`
- Marker interface with no members.
---
### ViewModel Interfaces
#### `ISensorsListViewModel : IBaseViewModel, IFilterableListView`
- **Properties:**
- `ISensorsListView View { get; set; }`
- `IAnalogSensor[] AnalogSensors { get; set; }`
- `ISquib[] Squibs { get; set; }`
- `IDigitalInputSetting[] DigitalInputSettings { get; set; }`
- `IDigitalOutputSetting[] DigitalOutputSettings { get; set; }`
- `IUartIOSetting[] UartIOSettings { get; set; }`
- `IStreamOutputSetting[] StreamOutputSettings { get; set; }`
- `CalibrationBehaviors CalibrationBehavior { get; set; }`
- `string CapacityFormat { get; set; }`
- `bool ShowOnlyTDCSensors { set; }`
- `bool ShowOnlySlicewareSensors { set; }`
- **Methods:**
- `void GetSensors(int sensorCalWarningPeriodDays, bool included)`
- `void GetSensors(int sensorCalWarningPeriodDays, int[] sensorsAllowed, IReadOnlyDictionary<int, ISensorData> sensors)` — Retrieves sensors matching allowed list.
- `void SetSelectedSerial(string serialNumber)`
- `void Sort(object sortBy, bool bColumnClick)`
- `void SortOverdue(object sortBy, bool bColumnClick)`
- `void Unset()`
- `void Filter(string currentFilter)`
- `void FilterSquib(object columnTag, string searchTerm)`
- `void FilterDigitalIn(object columnTag, string searchTerm)`
- `void FilterDigitalOut(object columnTag, string searchTerm)`
- `void FilterUartIO(object columnTag, string searchTerm)`
- `void FilterStreamIn(object columnTag, string searchTerm)`
- `void FilterStreamOut(object columnTag, string searchTerm)`
- `void SetCachedSensors(ISensorData[] cachedSensors)`
- `void SetCachedCalibrations(ISensorCalibration[] sensorCalibrations)`
- `void UseIncludedColumn(bool bUsesIncludedColumn)`
- `void SetIncludedAll(bool bIncluded)`
- `IDragAndDropItem[] GetIncludedSensors()` — Returns all sensors marked as included.
#### `ISensorsListEditGroupViewModel : IBaseViewModel, IFilterableListView`
- **Properties:**
- `ISensorsListEditGroupView View { get; set; }`
- `IAnalogSensor[] AnalogSensors { get; set; }`
- `ISquib[] Squibs { get; set; }`
- `IDigitalInputSetting[] DigitalInputSettings { get; set; }`
- `IDigitalOutputSetting[] DigitalOutputSettings { get; set; }`
- `IUartIOSetting[] UartSettings { get; set; }`
- `IStreamOutputSetting[] StreamOutputSettings { get; set; }`
- **Methods:**
- `void GetSensors(int sensorCalWarningPeriodDays, bool included)`
- `void SetCapacityFormat(string format)`
- `void Sort(object sortBy, bool bColumnClick)`
- `void Unset()`
- `void Filter(string currentFilter)`
- `void FilterSquib(object columnTag, string searchTerm)`
- `void FilterDigitalIn(object columnTag, string searchTerm)`
- `void FilterDigitalOut(object columnTag, string searchTerm)`
- `void FilterUartIO(object columnTag, string searchTerm)`
- `void FilterStreamOut(object columnTag, string searchTerm)`
- `void FilterStreamIn(object columnTag, string searchTerm)`
- `void SetShowAssigned(bool showAssigned, bool showUnassigned, IReadOnlyDictionary<string, bool> assignedSensors)`
- `void SetShowOnline(bool showOnline)`
- `void SetAssignedSensors(IReadOnlyDictionary<string, bool> serialNumbers)`
- `void SetOnline(Dictionary<string, bool> serialNumbersToOnline)`
- `bool IsSensorOnline(string serialNumber)`
- `void SetCachedSensors(ISensorData[] cachedSensors)`
- `void SetCachedCalibrations(ISensorCalibration[] calibrations)`
- `void SetActiveTab(PossibleFilters filter)` — Sets active tab to sensor type.
#### `ISensorTemplatesViewModel : IBaseViewModel`
- Marker interface with no members.
---
### Sensor Data Interfaces
#### `IAnalogSensor`
Represents analog sensors for UI display.
| Property | Type | Description |
|----------|------|-------------|
| `Bridge` | `SensorConstants.BridgeType` | Bridge mode of sensor |
| `IEPE` | `bool` | Integrated Electronics Piezo-Electric indicator |
| `DatabaseId` | `int` | Database ID (positive values valid) |
| `Included` | `bool` | Checkbox state in lists |
| `SerialNumber` | `string` | Sensor serial number |
| `Description` | `string` | Description/comment |
| `Manufacturer` | `string` | Sensor manufacturer |
| `Model` | `string` | Sensor model |
| `Capacity` | `double` | Maximum capacity or desired range in EU |
| `RangeHigh` | `double` | High range EU value |
| `RangeMedium` | `double` | Medium range EU value |
| `RangeLow` | `double` | Low range EU value |
| `Sensitivity` | `string` | User-friendly sensitivity string |
| `AddedSensitivity` | `string` | Second calibration for dual-sensitivity sensors |
| `Resistance` | `double` | Resistance in ohms |
| `Excitation` | `string` | Supported excitations display string |
| `Units` | `string` | Engineering units from calibration |
| `EID` | `string` | Electronic ID |
| `CalDate` | `DateTime` | Last calibration date |
| `CalDueDate` | `DateTime` | Calibration due date |
| `ModifiedBy` | `string` | Last modifying user |
| `LastModified` | `DateTime` | Last modification date |
| `Assigned` | `bool` | Channel assignment status |
| `Online` | `bool` | Online status |
| `ISOCode` | `string` | Default ISO code for new channel |
| `ISOChannelName` | `string` | Default ISO channel name |
| `UserCode` | `string` | Default user code |
| `UserChannelName` | `string` | Default user channel name |
| `CFC` | `FilterClassType` | Channel filter class |
| `Polarity` | `bool` | Output inversion flag |
| `NonLinearCalculationType` | `string` | Nonlinear calculation type (string) |
| `NonLinearCalculationTypeEnum` | `NonLinearStyles` | Nonlinear calculation type (enum) |
| `ZeroMethod` | `ZeroMethodType` | Software zero method |
| `ZeroMethodStart` | `double` | Zero method start time (if Average over Time) |
| `ZeroMethodEnd` | `double` | Zero method end time (if Average over Time) |
| `UserValue1/2/3` | `string` | User-defined values |
| `SensorCalibrationStatus` | `UIItemStatus` | Calibration status |
| `InitialOffsets` | `InitialOffset[]` | Initial offsets array |
| `FilterClass` | `IFilterClass` | Filter class definition (FB 13120) |
| `FirstUseDate` | `DateTime?` | First use date (nullable, Case 13065) |
| `LatestCalibrationId` | `int?` | Latest calibration ID (nullable) |
| `UsingLatestCalibration` | `bool` | Whether using latest calibration |
- `bool Filter(string term)` — Returns true if sensor matches filter criteria.
#### `ISquib`
Represents squib/pyrotechnic devices.
| Property | Type | Description |
|----------|------|-------------|
| `DatabaseId` | `int` | Database ID (>0 valid) |
| `Included` | `bool` | Checkbox state |
| `SerialNumber` | `string` | Serial/setting name |
| `Description` | `string` | Description |
| `ResistanceLow` | `double` | Low resistance value |
| `ResistanceHigh` | `double` | High resistance value |
| `ID` | `string` | Identifier |
| `SQMode` | `string` | Squib mode string |
| `SQDelay` | `double` | Delay value |
| `SQCurrent` | `double` | Current value |
| `SQDuration` | `double` | Duration value |
| `LimitDuration` | `bool` | Duration limit flag |
| `ModifiedBy` | `string` | Last modifying user |
| `LastModified` | `DateTime` | Last modification date |
| `Assigned` | `bool` | Channel assignment status |
| `Online` | `bool` | Online status |
| `ISOCode` | `string` | ISO code |
| `ISOChannelName` | `string` | ISO channel name |
| `UserCode` | `string` | User code |
| `UserChannelName` | `string` | User channel name |
| `Mode` | `SquibFireMode` | Fire mode enum |
| `Broken` | `bool` | Broken flag (excludes from selectable lists) |
| `DoNotUse` | `bool` | Do-not-use flag (excludes from selectable lists) |
- `bool Filter(string term)` — Returns true if squib matches filter criteria.
#### `IDigitalInputSetting`
Represents digital input configurations.
| Property | Type | Description |
|----------|------|-------------|
| `DatabaseId` | `int` | Database ID (positive valid) |
| `Included` | `bool` | Checkbox state |
| `SerialNumber` | `string` | Serial/setting name |
| `Description` | `string` | Description |
| `DIMode` | `string` | Digital Input Mode string |
| `ModifiedBy` | `string` | Last modifying user |
| `LastModified` | `DateTime` | Last modification date |
| `Assigned` | `bool` | Channel assignment status |
| `Online` | `bool` | Online status |
| `EID` | `string` | Electronic ID |
| `ISOCode` | `string` | ISO code |
| `ISOChannelName` | `string` | ISO channel name |
| `UserCode` | `string` | User code |
| `UserChannelName` | `string` | User channel name |
| `ActiveValue` | `string` | Display value for active state |
| `DefaultValue` | `string` | Display value for default/idle state |
| `Mode` | `DigitalInputModes` | DI mode enum |
| `Broken` | `bool` | Broken flag |
| `DoNotUse` | `bool` | Do-not-use flag |
- `bool Filter(string term)` — Returns true if matches filter criteria.
#### `IDigitalOutputSetting`
Represents digital output configurations.
| Property | Type | Description |
|----------|------|-------------|
| `DatabaseId` | `int` | Database ID (>0 valid) |
| `Included` | `bool` | Checkbox state |
| `SerialNumber` | `string` | Serial/setting name |
| `Description` | `string` | Description |
| `DODelay` | `double` | Delay before output (ms) |
| `DODuration` | `double` | Output duration (ms) |
| `ModifiedBy` | `string` | Last modifying user |
| `LastModified` | `DateTime` | Last modification date |
| `Assigned` | `bool` | Channel assignment status |
| `Online` | `bool` | Online status (note: no real detection method) |
| `ISOCode` | `string` | ISO code (limited usefulness) |
| `ISOChannelName` | `string` | ISO channel name (limited usefulness) |
| `UserCode` | `string` | User code (limited usefulness) |
| `UserChannelName` | `string` | User channel name (limited usefulness) |
| `LimitDuration` | `bool` | Duration limit flag |
| `DOMode` | `DigitalOutputModes` | Output mode enum |
| `Broken` | `bool` | Broken flag |
| `DoNotUse` | `bool` | Do-not-use flag |
- `bool Filter(string term)` — Returns true if matches filter criteria.
#### `IUartIOSetting`
Represents UART I/O configurations.
| Property | Type | Description |
|----------|------|-------------|
| `DatabaseId` | `int` | Database ID (positive valid) |
| `Included` | `bool` | Checkbox state |
| `SerialNumber` | `string` | Serial/setting name |
| `Description` | `string` | Description |
| `LastModifiedBy` | `string` | Last modifying user |
| `LastModified` | `DateTime` | Last modification date |
| `Assigned` | `bool` | Channel assignment status |
| `Online` | `bool` | Online status |
| `ISOCode` | `string` | ISO code |
| `ISOChannelName` | `string` | ISO channel name |
| `UserCode` | `string` | User code |
| `UserChannelName` | `string` | User channel name |
| `Broken` | `bool` | Broken flag |
| `DoNotUse` | `bool` | Do-not-use flag |
| `BaudRate` | `uint` | UART baud rate |
| `DataBits` | `uint` | UART data bits |
| `StopBits` | `StopBits` | UART stop bits |
| `Parity` | `Parity` | UART parity |
| `FlowControl` | `Handshake` | UART flow control (always NONE per FB 30486) |
| `DataFormat` | `UartDataFormat` | Incoming data format |
- `bool Filter(string term)` — Returns true if matches filter criteria.
#### `IStreamInputSetting`
Represents stream input configurations.
| Property | Type | Description |
|----------|------|-------------|
| `DatabaseId` | `int` | Database ID (positive valid) |
| `Included` | `bool` | Checkbox state |
| `SerialNumber` | `string` | Serial/setting name |
| `Description` | `string` | Description |
| `LastModifiedBy` | `string` | Last modifying user |
| `LastModified` | `DateTime` | Last modification date |
| `Assigned` | `bool` | Channel assignment status |
| `Online` | `bool` | Online status |
| `ISOCode` | `string` | ISO code |
| `ISOChannelName` | `string` | ISO channel name |
| `UserCode` | `string` |

View File

@@ -0,0 +1,70 @@
---
source_files:
- Common/DTS.CommonCore/Interface/Sensors/SoftwareFilters/ISoftwareFiltersView.cs
- Common/DTS.CommonCore/Interface/Sensors/SoftwareFilters/ISoftwareFiltersViewModel.cs
generated_at: "2026-04-16T12:23:58.149333+00:00"
model: "zai-org/GLM-5-FP8"
schema_version: 1
sha256: "c132999d4e5c3d51"
---
# Documentation: DTS.Common.Interface.Sensors.SoftwareFilters
## 1. Purpose
This module defines the core interfaces for the Software Filters subsystem within the DTS sensor framework. It establishes the contracts for the View and ViewModel in an MVVM (Model-View-ViewModel) architecture, enabling the management, sorting, and filtering of software filter configurations. Additionally, it defines `IFilterClass`, a contract for individual filter parameters (frequency and type), intended to support UI property grid editing and comparison operations.
## 2. Public Interface
### `ISoftwareFiltersView`
Inherits from: `DTS.Common.Base.IBaseView`
* **Description:** A marker interface defining the view contract for the Software Filters module. It imposes no specific members beyond those in `IBaseView`.
### `IFilterClass`
Inherits from: `System.IComparable`
Attributes: `System.ComponentModel.TypeConverter(typeof(System.ComponentModel.ExpandableObjectConverter))`
* **Description:** Defines a specific software filter configuration. The `ExpandableObjectConverter` attribute suggests this object is intended to be displayed and edited within a visual property grid.
* **Properties:**
* `string FilterName { get; }`: Gets the name of the filter.
* `DTS.Common.Enums.Sensors.FilterClassType FClass { get; set; }`: Gets or sets the classification type of the filter.
* `double Frequency { get; set; }`: Gets or sets the frequency value of the filter.
* **Methods:**
* `int GetFilterClassNumericValue()`: Returns a numeric representation of the filter class.
### `ISoftwareFiltersViewModel`
Inherits from: `DTS.Common.Base.IBaseViewModel`, `DTS.Common.Interface.Pagination.IFilterableListView`
* **Description:** Defines the behavior and state management for the Software Filters view.
* **Properties:**
* `ISoftwareFiltersView View { get; set; }`: Gets or sets the associated view instance.
* `System.Collections.ObjectModel.ObservableCollection<ISoftwareFilter> SoftwareFilters { get; set; }`: Gets or sets the bindable collection of software filters.
* `string CurrentUser { get; set; }`: Gets or sets the current user context.
* **Methods:**
* `void Sort(object sortBy, bool bColumnClick)`: Sorts the collection of software filters based on the provided criteria.
* `void Unset()`: Resets the state of the view model (specific implementation details not defined in interface).
* `void Filter(string currentFilter)`: Applies a string-based filter to the collection.
* `ISoftwareFilter[] GetSoftwareFilters()`: Retrieves the current software filters as an array.
* `void PopulateView()`: Initiates the loading or refreshing of data into the view.
* `bool ValidateAndSave()`: Validates the current state and persists changes; returns `true` if successful.
## 3. Invariants
* **Comparable Filter Classes:** Any implementation of `IFilterClass` must implement `IComparable`, guaranteeing that filter objects can be sorted or ordered relative to one another.
* **UI Compatibility:** `IFilterClass` implementations must be compatible with `System.ComponentModel.ExpandableObjectConverter`, implying they likely expose complex properties intended for expansion in a UI property browser.
* **Collection Type:** The `SoftwareFilters` property in `ISoftwareFiltersViewModel` must utilize `ObservableCollection<T>`, indicating the collection provides change notification events (likely for UI binding).
## 4. Dependencies
**Internal Dependencies (Referenced in Source):**
* `DTS.Common.Base`: Required for `IBaseView` and `IBaseViewModel`.
* `DTS.Common.Enums.Sensors`: Required for the `FilterClassType` enum used in `IFilterClass`.
* `DTS.Common.Interface.Pagination`: Required for `IFilterableListView` interface inheritance.
* `ISoftwareFilter`: Referenced as the generic type for collections in `ISoftwareFiltersViewModel`. **Note:** The definition for `ISoftwareFilter` is not present in the provided source files.
**External/System Dependencies:**
* `System`: For `IComparable` and basic types.
* `System.ComponentModel`: For `TypeConverter` and `ExpandableObjectConverter` attributes.
* `System.Collections.ObjectModel`: For `ObservableCollection`.
## 5. Gotchas
* **Missing Interface Definition:** The interface `ISoftwareFilter` is referenced as the primary data type within `ISoftwareFiltersViewModel` (in both the `ObservableCollection` and the return array of `GetSoftwareFilters`), but its definition is not included in the provided source files. The behavior of the ViewModel depends entirely on this missing contract.
* **Ambiguous `Unset` Behavior:** The method `Unset()` in `ISoftwareFiltersViewModel` has an unclear name. It is not immediately obvious if this clears the list, resets user selections, or disposes of resources without seeing the implementation.
* **Loosely Typed Sort:** The `Sort` method accepts `object sortBy`. This implies the implementation must perform runtime type checking or casting to determine the sort key, which could lead to runtime errors if an unexpected type is passed.
* **Historical Reference:** The `IFilterClass` interface contains a documentation comment referencing "FB 13120". This appears to be a reference to a bug tracking or feature request ticket (e.g., FogBugz), indicating historical context for the creation of this interface.