Table of Contents

ConfigurationDiagnosticMode Enum

Definition

Namespace
Bodu.Text.Configuration
Assembly
Bodu.Text.Configuration.dll
Package
Bodu.Text.Configuration 1.3.0
Source
ConfigurationDiagnosticMode.cs

Controls how the reader reacts to recoverable diagnostics - either throwing immediately, gathering them on the resulting document, or silently ignoring them.

public enum ConfigurationDiagnosticMode
Extension Methods

Fields

Throw = 0

The first recoverable error throws a ConfigurationParseException whose Diagnostics contains the single offending diagnostic.

Collect = 1

The reader runs to completion, capturing diagnostics on the resulting parse result's diagnostics list, and never throws ConfigurationParseException. An I/O error from the source still propagates.

Ignore = 2

Diagnostics are not retained: errors are silently dropped, and ConfigurationParseException is never thrown. An I/O error from the source still propagates. Useful for production hot paths where diagnostics would only add allocations.

Applies to

ProductVersions
.NET8, 10