Quantcast
Channel: Fluent Validation for .NET
Viewing all articles
Browse latest Browse all 1917

New Post: SetValidator() vs. SetCollectionValidator()

$
0
0
I'm new to Fluent Validation and just got the version 5.3 from nuGet yesterday. I'm trying to apply an existing validator to a collection property of a class. The documentation here says to use:
RuleFor(x => x.Orders).SetCollectionValidator(new OrderValidator());
However, the SetCollectionValidator() method is not available on the version I have. Instead, there is only SetValidator() which is marked as [deprecated]. What am I missing here?

Viewing all articles
Browse latest Browse all 1917

Trending Articles