Interface IConfigurationService
Namespace: Void.Proxy.Api.Configurations
Assembly: Void.Proxy.Api.dll
public interface IConfigurationService : IHostedServiceImplements
Methods
GetAsync<TConfiguration>(CancellationToken)
Retrieves a configuration instance of type TConfiguration.
The returned instance is fully self-managed: any changes made to the instance are automatically saved to disk,
and any changes from disk are automatically loaded into the instance.
ValueTask<TConfiguration> GetAsync<TConfiguration>(CancellationToken cancellationToken = default) where TConfiguration : notnullParameters
cancellationToken CancellationToken
A token used to signal the cancellation of the asynchronous operation.
Returns
ValueTask<TConfiguration>
A
Type Parameters
TConfiguration
The type of configuration being retrieved. It must not be null.
GetAsync<TConfiguration>(string, CancellationToken)
Retrieves a configuration instance of type TConfiguration.
The returned instance is fully self-managed: any changes made to the instance are automatically saved to disk,
and any changes from disk are automatically loaded into the instance.
ValueTask<TConfiguration> GetAsync<TConfiguration>(string key, CancellationToken cancellationToken = default) where TConfiguration : notnullParameters
key string
Specifies the identifier for the configuration value to be fetched.
cancellationToken CancellationToken
A token used to signal the cancellation of the asynchronous operation.
Returns
ValueTask<TConfiguration>
A
Type Parameters
TConfiguration
The type of configuration being retrieved. It must not be null.