BridgeStack.EnumHelpers.GetValue C# (CSharp) Метод

GetValue() публичный статический Метод

Checks for a EnumMemberAttribute decorating the value, and returns the actual string value for the provided member.
public static GetValue ( this member ) : string
member this The enum member.
Результат string
        public static string GetValue(this Enum member)
        {
            EnumMemberAttribute attribute = member.GetCustomAttribute<EnumMemberAttribute>();
            if (attribute != null && !attribute.Value.NullOrEmpty())
            {
                return attribute.Value;
            }
            return Enum.GetName(member.GetType(), member);
        }
EnumHelpers