Skip to content
Documentation

IEnumerationPropertyProvider<TStruct> Interface

Provides additional properties mapped to specific values of enumeration-like structs (i.e. Flag, FunctionType, etc.).

public interface IEnumerationPropertyProvider<TStruct>
where TStruct : struct, HAKOM.TSM.Net.Api.IEnumeration<TStruct>, System.IEquatable<TStruct>, System.ValueType, System.ValueType

TStruct

The enumeration-like type for which this instance provides additional properties.

IEnumeration<TStruct> implementing types are used to represent data similarly to the way how an enum works, but with added functionality and sometimes even the ability to extend them via configuration. Under the hood, these types are still represented by a single value (i.e. System.Byte, System.Int32, etc.) to keep their memory footprint as small as possible. In order to add properties to these values without attaching them to each instance of the TStruct, implementations of this interface may be used to map TStruct values to additional information, for example a human-readable string representation, etc.

IEnumerationPropertyProvider<TStruct>.MappedProperties Property

Section titled “IEnumerationPropertyProvider<TStruct>.MappedProperties Property”

Gets all property values mapped to specific values of TStruct.

System.Collections.Generic.IReadOnlyDictionary<TStruct,object> MappedProperties { get; }

System.Collections.Generic.IReadOnlyDictionary<TStruct,System.Object>

IEnumerationPropertyProvider<TStruct>.PropertyName Property

Section titled “IEnumerationPropertyProvider<TStruct>.PropertyName Property”

The name of the property for which this instance provides values.

string PropertyName { get; }

System.String

IEnumerationPropertyProvider<TStruct>.TryGetProperty(IEnumeration<TStruct>, object) Method

Section titled “IEnumerationPropertyProvider<TStruct>.TryGetProperty(IEnumeration<TStruct>, object) Method”

Attempts to get the value of an additional property that has been mapped to a specific value of TStruct.

bool TryGetProperty(HAKOM.TSM.Net.Api.IEnumeration<TStruct> value, out object property);

value HAKOM.TSM.Net.Api.IEnumeration<TStruct>

The TStruct value to look up the property value for

property System.Object

The mapped property.

System.Boolean
true if there is a mapped property value for the given value of TStruct, false otherwise.

IEnumerationPropertyProvider<TStruct>.TryGetProperty(TStruct, object) Method

Section titled “IEnumerationPropertyProvider<TStruct>.TryGetProperty(TStruct, object) Method”

Attempts to get the value of an additional property that has been mapped to a specific value of TStruct.

bool TryGetProperty(TStruct value, out object property);

value TStruct

The TStruct value to look up the property value for

property System.Object

The mapped property.

System.Boolean
true if there is a mapped property value for the given value of TStruct, false otherwise.

© 2026 Volue.Version v0.6.38017 November 2026