/// <summary> /// Convert Array to PairCollection /// </summary> /// <typeparam name="T"></typeparam> /// <param name="obj"></param> /// <returns></returns> public static PairCollection ToPairCollection <T>(this IEnumerable <T> obj) where T : class { var pp = new PairCollection(); foreach (var o in obj) { pp.Add(ToPair(o)); } return(pp); }
public static string PairModel(this DataTable dt) { using (PairCollection pc = new PairCollection(dt)) return(pc.Serialize()); }