예제 #1
0
 public static QueryReferenceField FromValue(string value)
 {
     foreach (QueryReferenceField queryReferenceField in QueryReferenceField.Values())
     {
         if (queryReferenceField.Value().Equals(value))
         {
             return(queryReferenceField);
         }
     }
     throw new ArgumentException(value.ToString());
 }
예제 #2
0
        public static List <QueryReferenceField> Values()
        {
            QueryReferenceField        queryReferenceField     = new QueryReferenceField();
            List <QueryReferenceField> queryReferenceFieldList = new List <QueryReferenceField>();

            foreach (PropertyInfo property in typeof(QueryReferenceField).GetProperties())
            {
                queryReferenceFieldList.Add((QueryReferenceField)property.GetValue((object)queryReferenceField, (object[])null));
            }
            return(queryReferenceFieldList);
        }