Exemple #1
0
 static public void CreateTable(MonoSQLiteManager sqlManager)
 {
     foreach (System.Type table in Objects)
     {
         sqlManager.CreateTable(table);
     }
     sqlManager.CommandQueries();
 }
Exemple #2
0
        private void LoadTable <T>()
            where T : DBBaseTable, new()
        {
            MonoSQLiteManager dbManager = new MonoSQLiteManager(PATH + DBFILENAME);
            List <T>          table     = dbManager.GetTableData <T>();

            dbManager.Close();
            Dictionary <int, DBBaseTable> tableMap = new Dictionary <int, DBBaseTable>();

            foreach (T ar in table)
            {
                tableMap.Add(ar.id, ar);
            }
            _tables.Add(typeof(T), tableMap);
        }