Table of Contents

Interface IValidator<T>

Namespace
Visus.AddressValidation.Validation
Assembly
Visus.AddressValidation.dll

Defines a validator for a given type.

public interface IValidator<in T> where T : class

Type Parameters

T

The type of object to validate.

Methods

ExecuteAsync(T, CancellationToken)

Executes validation against the specified instance.

ValueTask<IValidationResult> ExecuteAsync(T instance, CancellationToken cancellationToken = default)

Parameters

instance T

The instance to validate.

cancellationToken CancellationToken

A token that cancels the operation.

Returns

ValueTask<IValidationResult>

An IValidationResult object containing any validation errors or warnings.