3.9 KiB
3.9 KiB
source_files, generated_at, model, schema_version, sha256
| source_files | generated_at | model | schema_version | sha256 | |
|---|---|---|---|---|---|
|
2026-04-16T03:25:01.894095+00:00 | Qwen/Qwen3-Coder-Next-FP8 | 1 | 61eef1209c66c784 |
ISO
1. Purpose
This module defines event infrastructure for propagating changes to extra properties within the ISO domain layer of the DTS system. Specifically, it provides a Prism-based pub/sub event (ExtraPropertiesChangedEvent) and its associated argument container (ExtraPropertiesChangedEventArgs) to decouple producers and consumers of property updates—enabling reactive UI or business logic components to respond when a collection of IExtraProperty instances is modified, while preserving provenance via Producer and Consumer references.
2. Public Interface
-
ExtraPropertiesChangedEvent- Type:
classinheriting fromPubSubEvent<ExtraPropertiesChangedEventArgs> - Behavior: A Prism
PubSubEventused to publish and subscribe to notifications about changes to extra properties. Subscribers receive anExtraPropertiesChangedEventArgspayload.
- Type:
-
ExtraPropertiesChangedEventArgs- Type:
class - Constructor:
ExtraPropertiesChangedEventArgs(IList<IExtraProperty> extraProperties, object producer, object consumer) - Properties:
IList<IExtraProperty> ExtraProperties { get; }— The updated collection of extra properties.object Producer { get; }— The object instance that initiated or caused the change.object Consumer { get; }— The object instance that is the intended recipient or target of the change.
- Behavior: Encapsulates the data for an
ExtraPropertiesChangedEventpayload. All properties are read-only after construction.
- Type:
3. Invariants
ExtraPropertiesis non-null (enforced by constructor assignment; no null-check is present, so passingnullwill result in aNullReferenceExceptionat runtime).ProducerandConsumermay benull(no validation is enforced in the constructor).- The
ExtraPropertieslist reference is immutable in terms of property exposure (only a getter), but the contents of the list are not defensively copied—consumers must treat the list as potentially mutable if the producer retains a reference. - The event is strictly publish-once-per-change; no batching or deduplication semantics are implied.
4. Dependencies
- Dependencies on this module:
DTS.Common.Interface.ISO.ExtraProperties— Provides theIExtraPropertyinterface used inExtraPropertiesChangedEventArgs.ExtraProperties.Prism.Events— Provides thePubSubEvent<T>base class.System.Collections.Generic— ProvidesIList<T>.
- Dependencies of this module:
- This module is consumed by components that use Prism event aggregation (e.g., view models, services) to react to extra property changes in the ISO domain.
- No other modules in this file depend on it—this is a leaf event definition.
5. Gotchas
- No defensive copying: The
ExtraPropertieslist is assigned directly from the constructor argument; if the caller mutates the list after constructing the args object, subscribers may observe unexpected changes. - No validation on
Producer/Consumer: These may benull, and subscribers must handle this case explicitly. - No versioning or metadata: The event carries no timestamp, correlation ID, or change type (e.g., add/remove/replace), limiting traceability or differential processing.
- Assumes Prism event aggregator usage: The class is tightly coupled to Prism’s
PubSubEvent<T>—not usable in isolation without Prism infrastructure. - No documentation on semantics of
ProducervsConsumer: The distinction between the two is not clarified in the source—consumers must infer intent (e.g.,Producer= source of change,Consumer= target component).