Exemplo n.º 1
0
        private static void RemoveCache(string tableName, string conn)
        {
            //清内存
            string key = Cache.CacheManage.GetKey(Cache.CacheKeyType.Schema, tableName, conn);

            Cache.CacheManage.LocalInstance.Remove(key);
            //清外置的表结构.tx:
            if (!string.IsNullOrEmpty(AppConfig.DB.SchemaMapPath))
            {
                string file = TableSchema.GetSchemaFile(key);
                IOHelper.Delete(file);
            }
            key = Cache.CacheManage.GetKey(Cache.CacheKeyType.AutoCache, tableName, conn);
            Cache.AutoCache.ReadyForRemove(key);
        }