Numerics Configuration.Use Operations<T> Method
Definition
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 10.10.0
public static void UseOperations<T>(
IOperations<T> operations
)
Parameters
- operations IOperations<T>
- The operations implementation to use for type T.
Type Parameters
- T
- The operand type.
Remarks
Configure operations before use. Registration is assignment; the library does not track a registration lifecycle. Complete configuration before starting or releasing worker threads through normal application synchronization. Reconfiguration after ordinary use and configuration racing use are unsupported; existing collections and previously obtained comparers need not change.
Intrinsic types and library-owned complex/nullable families have fixed semantics; use the canonical wrapper helpers instead. Explicit comparer arguments remain available.
Registration controls numerical operations, scalar copying, custom value-type missing values and sorting. Default storage, reference/null metadata and collection equality/hashing are independent. Concurrent configuration, including registration racing ordinary use, is unsupported. Ordinary concurrent first use may evaluate constructors or uncached getters more than once; they are not serialized. Getter exceptions propagate without being cached.
Native AOT requires explicit operations registration; operations attributes are a JIT compatibility feature. This method does not register wrapper types, providers or matrix factories. Use typed wrapper hooks for required combinations.
Exceptions
| Argument | operations is null. |
| Argument | The type has fixed intrinsic or wrapper semantics. |