Retrieves the enum value for the given string name. The string name is the value obtained when calling to_string () on an enum value.
// Result: ``true``
MyEnum.FOO == Catalyst.EnumUtils.get_value_by_name<MyEnum> (MyEnum.FOO.to_string ());
It is an assertion error to provide a non-enum class as the type argument.
name |
the string name value |
the enum value |
Catalyst.EnumParseError |
if no enum value exists with the given name |