Table of Contents

Class Validator

Namespace
Admonish
Assembly
Admonish.dll

Creates ValidationResult objects.

public static class Validator
Inheritance
Validator
Inherited Members

Methods

Create()

Creates an object that allows to perform validation via a fluent interface.

public static ValidationResult Create()

Returns

ValidationResult

The created ValidationResult.

UnsafeConfigureException(Func<ValidationResult, Exception>)

Call this once at the application start to throw a custom exception for validation errors.

public static void UnsafeConfigureException(Func<ValidationResult, Exception> exceptionFactory)

Parameters

exceptionFactory Func<ValidationResult, Exception>

A callback that takes a ValidationResult as a parameter and creates a custom validation excepton.