public List <ClrTypeStats> LoadTypeStat() { var list = new List <ClrTypeStats>(); SQLiteCommand cmd = new SQLiteCommand(); cmd.Connection = cxion; cmd.CommandText = "SELECT Id, Name, MethodTable, Count, TotalSize FROM Types"; SQLiteDataReader dr = cmd.ExecuteReader(); while (dr.Read()) { int id = dr.GetInt32(0); var name = dr.GetString(1); ulong methodTable = (ulong)dr.GetInt64(2); var count = dr.GetInt64(3); var totalSize = (ulong)dr.GetInt64(4); ClrType type = ClrDump.GetType(methodTable); if (type == null) { type = ClrDump.GetType(name); } if (type == null) { type = new ClrTypeError(name); } var clrTypeStats = new ClrTypeStats(id, type, count, totalSize); list.Add(clrTypeStats); } return(list); }