Interface IMessageFeatures
Provider-neutral feature collection for message metadata and extensions.
public interface IMessageFeatures
- Extension Methods
Methods
GetFeature<TFeature>()
Gets a feature instance of type TFeature if present; otherwise null.
TFeature? GetFeature<TFeature>() where TFeature : class
Returns
- TFeature
The feature instance or null if not present.
Type Parameters
TFeatureFeature contract type.
SetFeature<TFeature>(TFeature?)
Sets a feature instance for type TFeature.
void SetFeature<TFeature>(TFeature? instance) where TFeature : class
Parameters
instanceTFeatureInstance to associate; null removes the feature.
Type Parameters
TFeatureFeature contract type.