init
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
---
|
||||
source_files:
|
||||
- Common/DTS.Common.SerializationPlus/Control/Event/Module/ReviewableDasSerialNumberAttribute.cs
|
||||
- Common/DTS.Common.SerializationPlus/Control/Event/Module/ReviewableAttribute.cs
|
||||
- Common/DTS.Common.SerializationPlus/Control/Event/Module/ReviewableSampleRateAttribute.cs
|
||||
generated_at: "2026-04-17T15:38:06.771428+00:00"
|
||||
model: "zai-org/GLM-5-FP8"
|
||||
schema_version: 1
|
||||
sha256: "bfab31fefc0af181"
|
||||
---
|
||||
|
||||
# Documentation: DTS.Slice.Control.Event.Module Reviewable Attributes
|
||||
|
||||
## 1. Purpose
|
||||
|
||||
This module provides a framework for defining reviewable attributes attached to `Event.Module` instances within the DTS.Slice.Control namespace. It enables extraction and formatting of module metadata—such as serial numbers, sample rates, hardware filter settings, and test descriptions—through a standardized attribute system. The pattern allows concrete attribute classes to encapsulate both a display name and a value-retrieval delegate, facilitating consistent data presentation for review purposes.
|
||||
|
||||
---
|
||||
|
||||
## 2. Public Interface
|
||||
|
||||
### `Event.Module.ReviewableAttribute` (Abstract Base Class)
|
||||
|
||||
**Inheritance:** Inherits from `Slice.Control.ReviewableAttribute`
|
||||
|
||||
| Member | Signature | Description |
|
||||
|--------|-----------|-------------|
|
||||
| Constructor (public) | `ReviewableAttribute(Event.Module channel)` | **Throws
|
||||
@@ -0,0 +1,91 @@
|
||||
---
|
||||
source_files:
|
||||
- Common/DTS.Common.SerializationPlus/Control/Event/Module/AnalogInputChannel/ReviewableShuntDeflectionAttribute.cs
|
||||
- Common/DTS.Common.SerializationPlus/Control/Event/Module/AnalogInputChannel/ReviewableFilterFrequencyAttribute.cs
|
||||
- Common/DTS.Common.SerializationPlus/Control/Event/Module/AnalogInputChannel/ReviewableIsoCodeAttribute.cs
|
||||
- Common/DTS.Common.SerializationPlus/Control/Event/Module/AnalogInputChannel/ReviewableDescriptionAttribute.cs
|
||||
- Common/DTS.Common.SerializationPlus/Control/Event/Module/AnalogInputChannel/ReviewableSerialNumberAttribute.cs
|
||||
- Common/DTS.Common.SerializationPlus/Control/Event/Module/AnalogInputChannel/ReviewableUnitsAttribute.cs
|
||||
- Common/DTS.Common.SerializationPlus/Control/Event/Module/AnalogInputChannel/ReviewableMinMaxEuAttribute.cs
|
||||
- Common/DTS.Common.SerializationPlus/Control/Event/Module/AnalogInputChannel/ReviewableCfcAttribute.cs
|
||||
- Common/DTS.Common.SerializationPlus/Control/Event/Module/AnalogInputChannel/ReviewableTargetShuntDeflectionAttribute.cs
|
||||
- Common/DTS.Common.SerializationPlus/Control/Event/Module/AnalogInputChannel/ReviewableMeasuredShuntDeflectionAttribute.cs
|
||||
- Common/DTS.Common.SerializationPlus/Control/Event/Module/AnalogInputChannel/ReviewableShuntDeflectionPercentageAttribute.cs
|
||||
generated_at: "2026-04-17T15:31:05.691210+00:00"
|
||||
model: "zai-org/GLM-5-FP8"
|
||||
schema_version: 1
|
||||
sha256: "4f8edc6331324b2a"
|
||||
---
|
||||
|
||||
# Documentation: AnalogInputChannel Reviewable Attributes
|
||||
|
||||
## 1. Purpose
|
||||
|
||||
This module provides a collection of reviewable attribute classes nested within `DTS.Slice.Control.Event.Module.AnalogInputChannel`. These classes serve as adapters that extract, format, and present channel-specific metadata—such as calibration values, filter settings, engineering units, and measurement errors—for display or reporting purposes. Each attribute inherits from `Slice.Control.Event.Module.Channel.ReviewableAttribute` and uses a delegate-based approach to lazily retrieve values from the underlying channel object.
|
||||
|
||||
---
|
||||
|
||||
## 2. Public Interface
|
||||
|
||||
All classes are nested within the partial class hierarchy: `Event.Module.AnalogInputChannel`.
|
||||
|
||||
### ReviewableShuntDeflectionAttribute
|
||||
```csharp
|
||||
public ReviewableShuntDeflectionAttribute(Event.Module.Channel channel)
|
||||
```
|
||||
- **Label:** "Shunt Deflection (mV)"
|
||||
- **Behavior:** Returns `MeasuredShuntDeflectionMv` from `IShuntAware` interface, formatted to 1 decimal place.
|
||||
|
||||
---
|
||||
|
||||
### ReviewableFilterFrequencyAttribute
|
||||
```csharp
|
||||
public ReviewableFilterFrequencyAttribute(Event.Module.Channel channel)
|
||||
```
|
||||
- **Label:** "Filter Frequency"
|
||||
- **Behavior:** Returns `CutoffFrequencyHz` from `SaeJ211Filter`, cast to integer and formatted with thousands separator ("N").
|
||||
|
||||
---
|
||||
|
||||
### ReviewableIsoCodeAttribute
|
||||
```csharp
|
||||
public ReviewableIsoCodeAttribute(Event.Module.Channel channel)
|
||||
```
|
||||
- **Label:** "ISO Code"
|
||||
- **Behavior:** Returns `IsoCode` from `AnalogInputChannel` as string.
|
||||
|
||||
---
|
||||
|
||||
### ReviewableDescriptionAttribute
|
||||
```csharp
|
||||
public ReviewableDescriptionAttribute(Event.Module.Channel channel)
|
||||
```
|
||||
- **Label:** "Description"
|
||||
- **Behavior:** Returns `ChannelDescriptionString` from the channel.
|
||||
|
||||
---
|
||||
|
||||
### ReviewableSerialNumberAttribute
|
||||
```csharp
|
||||
public ReviewableSerialNumberAttribute(Event.Module.Channel channel)
|
||||
```
|
||||
- **Label:** "Serial Number"
|
||||
- **Behavior:** Returns `SerialNumber` from `AnalogInputChannel` as string.
|
||||
|
||||
---
|
||||
|
||||
### ReviewableUnitsAttribute
|
||||
```csharp
|
||||
public ReviewableUnitsAttribute(Event.Module.Channel channel)
|
||||
```
|
||||
- **Label:** "Units"
|
||||
- **Behavior:** Returns `EngineeringUnits` from `IEngineeringUnitAware` interface as string.
|
||||
|
||||
---
|
||||
|
||||
### ReviewableMinMaxEuAttribute
|
||||
```csharp
|
||||
public ReviewableMinMaxEuAttribute(Event.Module.Channel channel)
|
||||
```
|
||||
- **Label:** "Max/Min (EU)"
|
||||
- **Behavior:** Returns a combined string of `DataMaxFilteredEu` and `DataMinFilteredEu`, both formatted to
|
||||
@@ -0,0 +1,156 @@
|
||||
---
|
||||
source_files:
|
||||
- Common/DTS.Common.SerializationPlus/Control/Event/Module/Channel/ReviewableAttribute.NotApplicableException.cs
|
||||
- Common/DTS.Common.SerializationPlus/Control/Event/Module/Channel/DataValues.cs
|
||||
- Common/DTS.Common.SerializationPlus/Control/Event/Module/Channel/CalculatedChannel.cs
|
||||
generated_at: "2026-04-17T15:38:30.345685+00:00"
|
||||
model: "zai-org/GLM-5-FP8"
|
||||
schema_version: 1
|
||||
sha256: "7405548f6ed6f3f6"
|
||||
---
|
||||
|
||||
# Documentation: DTS.Slice.Control.Event.Module.Channel
|
||||
|
||||
## 1. Purpose
|
||||
|
||||
This module provides channel-related types within the `DTS.Slice.Control` namespace hierarchy. It defines exception types for attribute validation, data storage mechanisms for channel values (with optional memory-mapped file support), and an abstract class hierarchy for calculated channels that derive data from operations such as FFT, integration, differentiation, and vector mathematics. The module supports engineering unit-aware channels with various calculation types used in data acquisition and analysis workflows.
|
||||
|
||||
---
|
||||
|
||||
## 2. Public Interface
|
||||
|
||||
### `Event.Module.Channel.ReviewableAttribute.NotApplicableException`
|
||||
|
||||
**Namespace:** `DTS.Slice.Control`
|
||||
|
||||
A nested exception class representing attempts to use a channel attribute that is not applicable to the associated channel. Inherits from `ApplicationException`.
|
||||
|
||||
| Constructor | Signature | Description |
|
||||
|-------------|-----------|-------------|
|
||||
| Default | `public NotApplicableException()` | Initializes an instance with no message. |
|
||||
| With Message | `public NotApplicableException(string msg)` | Initializes with a custom message string. |
|
||||
| With Message and Inner | `public NotApplicableException(string msg, System.Exception innerEx)` | Initializes with a message and inner exception. |
|
||||
|
||||
---
|
||||
|
||||
### `Event.Module.Channel.DataValues`
|
||||
|
||||
**Namespace:** `DTS.Slice.Control`
|
||||
|
||||
Represents a channel's data storage. Inherits from `Exceptional`.
|
||||
|
||||
| Constructor | Signature | Description |
|
||||
|-------------|-----------|-------------|
|
||||
| Default | `public DataValues()` | Initializes with `useMemoryMappedFile = true`. |
|
||||
| Parameterized | `public DataValues(bool useMemoryMappedFile)` | Initializes with explicit memory-mapped file setting. |
|
||||
|
||||
| Property | Type | Access | Description |
|
||||
|----------|------|--------|-------------|
|
||||
| `UseMemoryMappedFile` | `bool` | get/set | Switch to use memory-mapped files instead of in-memory lists (for large data sets). |
|
||||
|
||||
---
|
||||
|
||||
### `Event.Module.Channel.CalculatedChannel` (Abstract)
|
||||
|
||||
**Namespace:** `DTS.Slice.Control`
|
||||
|
||||
Abstract base class for calculated channels. Inherits from `Channel` and implements `Common.DAS.Concepts.DAS.Channel.IEngineeringUnitAware`.
|
||||
|
||||
**Nested Enums:**
|
||||
|
||||
| Enum | Values |
|
||||
|------|--------|
|
||||
| `Operation` | `Integral`, `Derivative`, `HeadInjuryCriteria`, `FFT`, `ImportedCSV`, `Resultant`, `TSR`, `Scale`, `Offset`, `Sine`, `Cosine` |
|
||||
| `XUnits` | `msec`, `sec`, `Hz`, `samples` |
|
||||
|
||||
**Constructor:**
|
||||
```csharp
|
||||
public CalculatedChannel(
|
||||
string name,
|
||||
XUnits xAxis,
|
||||
string yAxis,
|
||||
double[] xValues,
|
||||
double[] yValues,
|
||||
Operation calcType,
|
||||
int number,
|
||||
Module parentModule
|
||||
)
|
||||
```
|
||||
|
||||
**Properties:**
|
||||
|
||||
| Property | Type | Access | Description |
|
||||
|----------|------|--------|-------------|
|
||||
| `CalculationType` | `Operation` | get | Returns the operation type for this channel. |
|
||||
| `X` | `double[]` | get | Returns X-axis values as array. |
|
||||
| `Y` | `double[]` | get | Returns Y-axis values as array. |
|
||||
| `XAxis` | `XUnits` | get | Returns the X-axis unit type. |
|
||||
| `XUnitsString` | `string` | get | Returns string representation ("Hz", "ms", "samples", "s", or "N/A"). |
|
||||
| `EngineeringUnits` | `string` | get/set | Gets or sets the Y-axis engineering units string. |
|
||||
| `SupportsADC` | `bool` | get | Always returns `false`. |
|
||||
| `SupportsEU` | `bool` | get | Always returns `true`. |
|
||||
| `SupportsmV` | `bool` | get | Always returns `false`. |
|
||||
| `ActualMaxRangeEu` | `double` | get | Returns `_y.Max()`. |
|
||||
| `ActualMinRangeEu` | `double` | get | Returns `_y.Min()`. |
|
||||
| `DataHalfRangeValueEu` | `double` | get | Returns midpoint of min/max Y values. |
|
||||
| `DataMaxEu` | `double` | get | Returns `_y.Max()`. |
|
||||
| `DataMinEu` | `double` | get | Returns `_y.Min()`. |
|
||||
| `DataRangeEu` | `double` | get | Returns max of absolute min/max Y values. |
|
||||
| `DataZeroLevelAdc` | `short` | get | Always returns `0`. |
|
||||
| `IsConfigured` | `bool` | get/set | Getter returns `true`; setter throws `NotSupportedException`. |
|
||||
|
||||
**Methods:**
|
||||
|
||||
| Method | Return Type | Behavior |
|
||||
|--------|-------------|----------|
|
||||
| `ToString()` | `string` | Returns `ChannelDescriptionString` or "N/A". |
|
||||
| `GetUnfilteredDataEu()` | `List<double>` | Returns a new `List<double>` copy of Y values. |
|
||||
| `FromDtsSerializationTestModuleChannel(Serialization.Test.Module.Channel)` | `void` | Throws `NotSupportedException`. |
|
||||
| `SetPropertyValuesFrom(DASLib.Service.DASChannel)` | `void` | Throws `NotSupportedException`. |
|
||||
| `SetPropertyValuesFrom(IDiagnosticResult)` | `void` | Throws `NotSupportedException`. |
|
||||
| `ToDtsSerializationTestModuleChannel(Serialization.Test.Module)` | `Serialization.Test.Module.Channel` | Throws `NotSupportedException`. |
|
||||
| `ActualMaxRangeMv` | `double` | Throws `NotSupportedException`. |
|
||||
| `ActualMinRangeMv` | `double` | Throws `NotImplementedException`. |
|
||||
| `GetUnfilteredDataMV()` | `List<double>` | Throws `NotImplementedException`. |
|
||||
| `SensorCapacityEU` | `double` | Throws `NotImplementedException`. |
|
||||
| `DesiredRangeEU` | `double` | Throws `NotImplementedException`. |
|
||||
|
||||
---
|
||||
|
||||
### Concrete Calculated Channel Classes
|
||||
|
||||
All inherit from `CalculatedChannel` and expose only constructors matching the base signature:
|
||||
|
||||
| Class | Additional Members |
|
||||
|-------|-------------------|
|
||||
| `IntegralCalculatedChannel` | None beyond base constructor. |
|
||||
| `DerivativeCalculatedChannel` | None beyond base constructor. |
|
||||
| `ScaleCalculatedChannel` | None beyond base constructor. |
|
||||
| `OffsetCalculatedChannel` | None beyond base constructor. |
|
||||
| `ResultantCalculatedChannel` | None beyond base constructor. |
|
||||
| `AdditiveVectorCalculatedChannel` | None beyond base constructor. |
|
||||
| `SineCalculatedChannel` | None beyond base constructor. |
|
||||
| `CosineCalculatedChannel` | None beyond base constructor. |
|
||||
|
||||
### `FFTCalculatedChannel`
|
||||
|
||||
Extends `CalculatedChannel` with FFT-specific data.
|
||||
|
||||
**Constructor:**
|
||||
```csharp
|
||||
public FFTCalculatedChannel(
|
||||
string name,
|
||||
XUnits xAxis,
|
||||
string yAxis,
|
||||
double[] xValues,
|
||||
double[] yValues,
|
||||
Operation calcType,
|
||||
int number,
|
||||
Module parentModule,
|
||||
double peakFrequency
|
||||
)
|
||||
```
|
||||
|
||||
| Property | Type | Access | Description |
|
||||
|----------|------|--------|-------------|
|
||||
| `PeakFrequency` | `double
|
||||
Reference in New Issue
Block a user