Note

Access to this page requires authorization. You can try signing in or .

Access to this page requires authorization. You can try .

IniConfigurationProvider Class

Definition

Namespace:
Microsoft.Extensions.Configuration.Ini
Assembly:
Microsoft.Extensions.Configuration.Ini.dll
Package:
Microsoft.Extensions.Configuration.Ini v11.0.0-preview.5.26302.115
Source:
IniConfigurationProvider.cs
Source:
IniConfigurationProvider.cs
Source:
IniConfigurationProvider.cs
Source:
IniConfigurationProvider.cs

Important

Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.

Provides configuration key-value pairs that are obtained from an INI file.

public ref class IniConfigurationProvider : Microsoft::Extensions::Configuration::FileConfigurationProvider
public class IniConfigurationProvider : Microsoft.Extensions.Configuration.FileConfigurationProvider
type IniConfigurationProvider = class
 inherit FileConfigurationProvider
Public Class IniConfigurationProvider
Inherits FileConfigurationProvider
Inheritance

Remarks

INI files are simple line structures (INI files on Wikipedia).

The following is an example of an INI file:

[Section:Header]
key1=value1
key2 = " value2 "
; comment
# comment
/ comment

Constructors

Name Description
IniConfigurationProvider(IniConfigurationSource)

Initializes a new instance with the specified source.

Properties

Name Description
Data

Gets or sets the configuration key-value pairs for this provider.

(Inherited from ConfigurationProvider)
Source

Gets the source settings for this provider.

(Inherited from FileConfigurationProvider)

Methods

Name Description
Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

(Inherited from FileConfigurationProvider)
Dispose(Boolean)

Disposes the provider.

(Inherited from FileConfigurationProvider)
GetChildKeys(IEnumerable<String>, String)

Returns the list of keys that this provider has.

(Inherited from ConfigurationProvider)
GetReloadToken()

Returns a IChangeToken that can be used to listen when this provider is reloaded.

(Inherited from ConfigurationProvider)
Load()

Loads the contents of the file at Path.

(Inherited from FileConfigurationProvider)
Load(Stream)

Loads the INI data from a stream.

OnReload()

Triggers the reload change token and creates a new one.

(Inherited from ConfigurationProvider)
Set(String, String)

Sets a value for a given key.

(Inherited from ConfigurationProvider)
ToString()

Generates a string representing this provider name and relevant details.

(Inherited from FileConfigurationProvider)
TryGet(String, String)

Attempts to find a value with the given key.

(Inherited from ConfigurationProvider)

Applies to


Feedback

Was this page helpful?