Class DummyConfiguration
Implementation of the IConfiguration interface for testing purposes. With this implementation we retrieve and store config values in memory.
Inheritance
Implements
Namespace: Celerik.NetCore.Services
Assembly: cs.temp.dll.dll
Syntax
public class DummyConfiguration : IConfiguration, IDisposable
Constructors
DummyConfiguration()
Initializes a new instance of the class.
Declaration
public DummyConfiguration()
Properties
Item[String]
Gets or sets a configuration value.
Declaration
public string this[string key] { get; set; }
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | key | The configuration key. |
Property Value
| Type | Description |
|---|---|
| System.String | The configuration value. |
Methods
Dispose()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
Declaration
public void Dispose()
Dispose(Boolean)
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
Declaration
protected virtual void Dispose(bool disposing)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Boolean | disposing | Indicates whether it is disposing. |
GetChildren()
Gets the immediate descendant configuration sub-sections.
Declaration
public IEnumerable<IConfigurationSection> GetChildren()
Returns
| Type | Description |
|---|---|
| System.Collections.Generic.IEnumerable<IConfigurationSection> | The configuration sub-sections. |
GetReloadToken()
Returns a Microsoft.Extensions.Primitives.IChangeToken that can be used to observe when this configuration is reloaded.
Declaration
public IChangeToken GetReloadToken()
Returns
| Type | Description |
|---|---|
| IChangeToken | A Microsoft.Extensions.Primitives.IChangeToken. |
GetSection(String)
Gets a configuration sub-section with the specified key.
Declaration
public IConfigurationSection GetSection(string key)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | key | The key of the configuration section. |
Returns
| Type | Description |
|---|---|
| IConfigurationSection | The Microsoft.Extensions.Configuration.IConfigurationSection. |