24 lines
604 B
C#
24 lines
604 B
C#
namespace Activity.Data
|
|
{
|
|
/// <summary>
|
|
/// 活动数据统一存储接口 - 负责所有活动的数据持久化
|
|
/// </summary>
|
|
public interface IEventDataRepository
|
|
{
|
|
/// <summary>
|
|
/// 保存数据到持久化存储
|
|
/// </summary>
|
|
void Save<T>(T data) where T : IEventData;
|
|
|
|
/// <summary>
|
|
/// 从持久化存储加载数据
|
|
/// </summary>
|
|
T Load<T>() where T : IEventData, new();
|
|
|
|
/// <summary>
|
|
/// 检查数据是否存在
|
|
/// </summary>
|
|
bool Exists<T>() where T : IEventData;
|
|
}
|
|
}
|