33 lines
772 B
C#
33 lines
772 B
C#
namespace MiaoYu.Core.CodeGenerator.Services;
|
|
|
|
/// <summary>
|
|
/// 表结构缓存接口
|
|
/// </summary>
|
|
public interface ITableSchemaCache : IScopedDependency
|
|
{
|
|
/// <summary>
|
|
/// 获取所有表信息(从缓存或数据库)
|
|
/// </summary>
|
|
/// <returns></returns>
|
|
List<DbTableInfo> GetAllTables();
|
|
|
|
/// <summary>
|
|
/// 刷新缓存
|
|
/// </summary>
|
|
void RefreshCache();
|
|
|
|
/// <summary>
|
|
/// 清除缓存
|
|
/// </summary>
|
|
void ClearCache();
|
|
|
|
/// <summary>
|
|
/// 根据数据库和表名获取表信息
|
|
/// </summary>
|
|
/// <param name="databaseKey">数据库标识</param>
|
|
/// <param name="tableName">表名</param>
|
|
/// <returns></returns>
|
|
DbTableInfo? GetTable(string databaseKey, string tableName);
|
|
}
|
|
|