3.4 KiB
source_files, generated_at, model, schema_version, sha256
| source_files | generated_at | model | schema_version | sha256 | |
|---|---|---|---|---|---|
|
2026-04-16T03:18:29.951703+00:00 | Qwen/Qwen3-Coder-Next-FP8 | 1 | 958951d2772f6a16 |
ExtraProperties
1. Purpose
TextPastedArgs is an immutable event argument class used to carry contextual data when a text-paste operation occurs on an extra property control within the ISO (likely Intelligent System Operator or similar domain) UI layer. It encapsulates the pasted text content, the originating extra property instance, a unique identifier for the operation, and an optional user-defined tag—enabling event subscribers to handle paste events with full context.
2. Public Interface
-
TextPastedArgs(string text, IExtraProperty extraProperty, string id, object tag)
Constructor initializing all properties. Validates none of the parameters are null-checked in the constructor body (per source), buttextandidare non-nullable reference types (C# 8+), implying callers must provide non-null values.text: The string content being pasted.extraProperty: TheIExtraPropertyinstance that triggered the event (assigned toSender).id: A string identifier for the paste operation (e.g., correlation ID, control ID).tag: An arbitrary object for caller-defined metadata.
-
string Text { get; }
Immutable property containing the pasted text. -
object Sender { get; }
Immutable property referencing theIExtraPropertyinstance passed into the constructor (i.e., the source control). -
string Id { get; }
Immutable property holding the operation identifier. -
object Tag { get; }
Immutable property for user-defined contextual data.
3. Invariants
- All properties are read-only (no setters); instances are fully immutable after construction.
TextandIdare expected to be non-null (as declared with non-nullable reference types), though the constructor does not enforce this at runtime.Senderis always the exactIExtraPropertyinstance passed as the second constructor parameter.Tagmay benull(no constraints specified).
4. Dependencies
- Depends on:
System(core types:string,object)DTS.Common.Events(namespace, likely contains event-related infrastructure)DTS.Common.Interface.ISO.ExtraProperties(specificallyIExtraPropertyinterface)
- Used by: Event handlers subscribed to paste events (e.g.,
ITextPastedEventArgsconsumers), likely in UI components managing extra property controls.
5. Gotchas
- No null-safety in constructor: While
TextandIdare non-nullable reference types, the constructor does not validate inputs—passingnulltotextoridwill compile (with warnings suppressed or ignored) but may cause runtime failures downstream. Senderis misnamed: The property is namedSenderbut storesextraProperty(not a generic UI sender like a control). This may confuse developers expectingsenderto be the UI element.- No validation of
iduniqueness: TheIdfield’s purpose is unclear without context—consumers must assume it is unique per operation or handle collisions. Tagsemantics undefined: The meaning ofTagis entirely caller-defined; no standard usage pattern is evident from this class alone.
None identified beyond the above.