Class ProductKindRegistry
Provides process-lifetime lookup access to logical product kinds.
public static class ProductKindRegistry
- Inheritance
-
ProductKindRegistry
- Inherited Members
Properties
All
Gets a read-only snapshot of all registered product kinds, ordered by identifier.
public static IReadOnlyCollection<ProductKind> All { get; }
Property Value
Methods
Get(string)
Gets a registered product kind by identifier.
public static ProductKind? Get(string id)
Parameters
idstringThe stable, namespaced product-kind identifier.
Returns
- ProductKind
The registered product kind, or null when the identifier is not registered.
Exceptions
- ArgumentNullException
Thrown when
idis null.- ArgumentException
Thrown when
idis empty or does not use the supported namespaced format.
TryGet(string, out ProductKind?)
Attempts to get a registered product kind by identifier.
public static bool TryGet(string id, out ProductKind? productKind)
Parameters
idstringThe stable, namespaced product-kind identifier.
productKindProductKindThe registered product kind when found; otherwise null.
Returns
Exceptions
- ArgumentNullException
Thrown when
idis null.- ArgumentException
Thrown when
idis empty or does not use the supported namespaced format.