Documentation
Table of Contents

Method AddSetting

Namespace
IntentSharp
Assembly
IntentSharp.dll

AddSetting(SettingDescriptor)

Declares a setting beyond the core settings, so files and code can set it and every check resolves it. Works with or without WithGuardrails(GuardrailOptions). The same descriptor (the same object, or one equal in every property) in Settings is counted once; another setting there with the same name makes Build() throw ArgumentException. Options with OnBuild receive it when the client is built, as a rule file source from the Guardrails package does.

public IntentClientBuilder AddSetting(SettingDescriptor descriptor)

Parameters

descriptor SettingDescriptor

The setting.

Returns

IntentClientBuilder

Exceptions

ArgumentNullException

descriptor is null.

ArgumentException

The setting has no name, a core setting or an earlier one has its name, it is a security setting with no fail-closed value, or its default or fail-closed value is one its own rules refuse.