IDatabaseModule.cs 574 B

1234567891011
  1. 
  2. namespace XGame.Framework.Database
  3. {
  4. public interface IDatabaseModule
  5. {
  6. TTable GetByKey<TTable, TRepository>(long key) where TTable : class, ITable where TRepository : TableRepository<TTable, TRepository>;
  7. TTable[] GetAll<TTable, TRepository>() where TTable : class, ITable where TRepository : TableRepository<TTable, TRepository>;
  8. IDatabaseAsync<TTable> LoadAsync<TTable, TRepository>(string tableName) where TTable : class, ITable where TRepository : TableRepository<TTable, TRepository>;
  9. void Unload(string tableName);
  10. }
  11. }