Table of Contents

Interface IDiscoverableValidators

Namespace
Cratis.Applications.Validation
Assembly
Cratis.Applications.dll

Defines a service that can lookup FluentValidation.IValidator for a given model type.

public interface IDiscoverableValidators

Methods

TryGet(Type, out IValidator)

Try to get a validator for the given model type.

bool TryGet(Type modelType, out IValidator validator)

Parameters

modelType Type

Type of model to get a validator for.

validator IValidator

The FluentValidation.IValidator if found.

Returns

bool

True if a validator was found, false otherwise.