-
-
Notifications
You must be signed in to change notification settings - Fork 124
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
1b391a9
commit f5fa950
Showing
7 changed files
with
106 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
using System; | ||
namespace CTFServer.Services.Interface; | ||
|
||
public interface IConfigService | ||
{ | ||
/// <summary> | ||
/// 保存配置对象 | ||
/// </summary> | ||
/// <typeparam name="T">选项类型</typeparam> | ||
/// <param name="config">选项对象</param> | ||
/// <param name="token"></param> | ||
/// <returns></returns> | ||
public Task SaveConfig<T>(T config, CancellationToken token = default) where T : class; | ||
|
||
/// <summary> | ||
/// 保存配置对象 | ||
/// </summary> | ||
/// <param name="type">对象类型</param> | ||
/// <param name="value">对象值</param> | ||
/// <param name="token"></param> | ||
/// <returns></returns> | ||
public Task SaveConfig(Type type, object? value, CancellationToken token = default); | ||
} | ||
|