AppStartSettings
StockSharp.Configuration
应用程序启动配置 。
属性
Language
public string Language { get; set; }
value = appStartSettings.Language
appStartSettings.Language = value
所选应用语言.
Online
public bool Online { get; set; }
value = appStartSettings.Online
appStartSettings.Online = value
在线模式.
TimeZone
public TimeZoneInfo TimeZone { get; set; }
value = appStartSettings.TimeZone
appStartSettings.TimeZone = value
首选应用时区.
方法
TryLoad
public static AppStartSettings TryLoad(IFileSystem fileSystem)
result = AppStartSettings.TryLoad(fileSystem)
如果配置文件存在, 尝试装入设置 。
TryLoadAsync
public static ValueTask<AppStartSettings> TryLoadAsync(IFileSystem fileSystem, CancellationToken cancellationToken)
result = AppStartSettings.TryLoadAsync(fileSystem, cancellationToken)
Try load settings, if config file exists.
- fileSystem
- File system.
- cancellationToken
- CancellationToken
返回值: The settings, or when there are none.
TrySave
public void TrySave(IFileSystem fileSystem)
appStartSettings.TrySave(fileSystem)
如果定义了, 设置将保存到 PlatformConfigurationFile 中 。
TrySaveAsync
public ValueTask TrySaveAsync(IFileSystem fileSystem, CancellationToken cancellationToken)
result = appStartSettings.TrySaveAsync(fileSystem, cancellationToken)
Save settings into PlatformConfigurationFile.
- fileSystem
- IFileSystem
- cancellationToken
- CancellationToken
返回值: ValueTask