Table of Contents

Class AppSettingsService

Namespace
McServerLauncher.Services
Assembly
McServerLauncher.dll

Loads and saves the global settings in %APPDATA%\McServerLauncher\settings.json.

public class AppSettingsService
Inheritance
AppSettingsService
Inherited Members

Constructors

AppSettingsService(string?)

Default constructor uses %APPDATA%; dataDir is for tests.

public AppSettingsService(string? dataDir = null)

Parameters

dataDir string

Properties

LastSaveCouldNotProtectKey

True when the last Save(AppSettings) could not encrypt the Playit key: the key was NOT written to disk (a secret is never persisted in plaintext) and keeps working only for this session. The failure is also recorded in the daily log; the UI shows a one-time warning.

public bool LastSaveCouldNotProtectKey { get; }

Property Value

bool

Methods

Load()

public AppSettings Load()

Returns

AppSettings

Save(AppSettings)

public void Save(AppSettings settings)

Parameters

settings AppSettings