Esempio n. 1
0
 public static IEnumerable <Tuple <string, object> > AsTuples <T>(this T anonymousObject)
     where T : class
 {
     return(AnonymousExtensions.anonymousAs <T, Tuple <string, object> >(anonymousObject, new Func <string, object, Tuple <string, object> >(Tuple.Create <string, object>)));
 }
Esempio n. 2
0
 public static IEnumerable <KeyValuePair <string, object> > AsKeyValuePairs <T>(this T anonymousObject)
     where T : class
 {
     return(AnonymousExtensions.anonymousAs <T, KeyValuePair <string, object> >(anonymousObject, (string propName, object val) => new KeyValuePair <string, object>(propName, val)));
 }