示例#1
0
 internal static List <T> ConvertDataTable <T>(string jsonString, bool ignore)
 {
     try
     {
         var _dataTable = ConvertToDatatable.JsonToDataTable(jsonString);
         var _list      = ConvertDataTable <T>(_dataTable, false);
         return(_list);
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
示例#2
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="json"></param>
        /// <returns></returns>
        public static DataTable ToDataTable(string json)
        {
            var _dataTable = ConvertToDatatable.JsonToDataTable(json);

            return(_dataTable);
        }
示例#3
0
        /// <summary>
        /// Convert Generic List into DataTable.
        /// </summary>
        /// <typeparam name="T">Genric type object.</typeparam>
        /// <param name="list">Genrtic list</param>
        /// <returns>DataTable</returns>
        public static DataTable ToDatatable <T>(List <T> list)
        {
            var _dataTable = ConvertToDatatable.ToDataTable <T>(list);

            return(_dataTable);
        }