Пример #1
0
 public static T ToEnum <T>(string value)
 {
     if (!Enum.IsDefined(typeof(T), value))
     {
         Print.LogError($"{value} is not defined in enum {typeof(T)}.");
         return(default);