Table of Contents

DuplicateKeyPolicy Enum

Definition

Namespace
Bodu.Text.Configuration
Assembly
Bodu.Text.Configuration.dll
Package
Bodu.Text.Configuration 1.0.0
Source
DuplicateKeyPolicy.cs

Specifies how the configuration parser resolves a key that appears more than once within the same section.

public enum DuplicateKeyPolicy
Extension Methods

Fields

LastWins = 0

The last occurrence of a duplicated key wins; earlier values are discarded. This is the default.

FirstWins = 1

The first occurrence of a duplicated key is retained; subsequent occurrences are silently ignored.

Disallowed = 2

Any duplicated key is rejected, surfacing as a ConfigurationParseException or a collected diagnostic depending on the active ConfigurationDiagnosticMode.

Applies to

ProductVersions
.NET8, 10