public static List <QueryExternalLocalizationField> Values() { QueryExternalLocalizationField localizationField = new QueryExternalLocalizationField(); List <QueryExternalLocalizationField> localizationFieldList = new List <QueryExternalLocalizationField>(); foreach (FieldInfo field in localizationField.GetType().GetFields()) { localizationFieldList.Add((QueryExternalLocalizationField)field.GetValue((object)localizationField)); } return(localizationFieldList); }
public static QueryExternalLocalizationField FromValue( string value) { foreach (QueryExternalLocalizationField localizationField in QueryExternalLocalizationField.Values()) { if (localizationField.Value().Equals(value)) { return(localizationField); } } throw new ArgumentException(value.ToString()); }