Releases: kolan72/ExpressValidator
Releases · kolan72/ExpressValidator
0.12.2
- Move the instance field
TypeValidatorBase._shouldBeComparedToNullto a static readonly field (renamed to_canBeNull) to cache the reflection result perTypeValidatorBase<T>type and eliminate redundant per-instance evaluations. - Remove the eagerly allocated
NotNullValidationMessageProviderduringExpressValidatorBuilderconfiguration, and instantiateNotNullValidationMessageProvider<object, T>only when the value is null.
DeprecateNotNullValidationMessageProvider.GetMessage(ValidationContext<T>). - Update to FluentValidation 12.1.0.
- Rename private
TypeValidatorBase.HasOnlyNullOrEmptyValidatorstoHasNonEmptyValidators(inverting the boolean logic) and remove the negation of this property in theShouldValidatemethod. - DRY refactor of null validation in
TypeValidatorBase<T>. - Add tests for null-tolerance validation in
QuickValidator. - Add test for validating a primitive type using
ExpressValidatorBuilder. - Add a unit test that verifies
ExpressValidatordoes not throw when members are null and no null-related validators are used. - Edit README.md and NuGet.md.
0.12.0
- Support .NET 8.0 and FluentValidation 12.0.0.
- Fix
ExpressPropertyValidator<TObj, T>to prevent callingFunc<TObj, T>propertyFunc twice when a success handler is present. - Fix NU1504: Duplicate 'PackageReference' found
- Update NUnit NuGet package to v4.4.0.
- Add test for
ValidateAsyncwith bothWithValidationandWithAsyncValidationinExpressValidatorBuilder. - Add test to ensure synchronous Validate throws
AsyncValidatorInvokedSynchronouslyExceptionif the builder has async rules. - Add a test for the
ValidateAsyncmethod with simulated external services. - Add 'Asynchronous Validation' README Chapter.
0.10.0
- Introduced the
QuickValidator.ValidateAsync<T>(T, Action<IRuleBuilderOptions<T, T>>, string, Action<T>, CancellationToken)extension method. - Introduced the
QuickValidator.ValidateAsync<T>(T, Action<IRuleBuilderOptions<T, T>>, PropertyNameMode, Action<T>, CancellationToken)extension method. - Split ExpressValidator.sln into two: the original and ExpressValidator.Extensions.DependencyInjection.sln.
- Edit 'Quick Validation' README Chapter.
- Edit 'Quick Validation' NuGet README Chapter.
0.9.0
- Added quick validation support via
QuickValidatorand itsValidate<T>overloads. - Improve performance by applying options in
ExpressValidator<TObj, TOptions>during theExpressValidatorBuilder<TObj, TOptions>.Buildcall instead of at validation time. - Introduce the
Unitreadonly struct. - Add 'Nuances Of Using The Library' README Chapter.
- Add 'Nuances Of Using The Library' NuGet README Chapter.
- Add 'Quick Validation' README Chapter.
- Add 'Quick Validation' NuGet README Chapter.
0.5.0
- Introduced the
IExpressValidatorBuilder<TObj, TOptions>.BuildAndValidate<TObj, TOptions>(TObj, TOptions)extension method. - Introduced the
IExpressValidatorBuilder<TObj, TOptions>.BuildAndValidateAsync<TObj, TOptions>(TObj, TOptions, CancellationToken)extension method. - Introduced an optional
Action<T>parameter inExpressValidatorBuilder.AddFuncfor handling successfulFuncresult validation. - Remove
ConfigureAwait(false)in the loop where items are asynchronously added toList<ValidationFailure>as a precaution. - Add 'Modifying FluentValidation Validator Parameters Using Options' chapter in README.
0.2.0
- Introduce
IExpressValidatorBuilder<TObj>.BuildAndValidate(TObj obj)extension method. - Introduce
IExpressValidatorBuilder<TObj>.BuildAndValidateAsync(TObj, CancellationToken)extension method. - Remove unused internal
ExpressValidatorBuilder<TObj, TOptions>.Optionsproperty. - Made the
TObjparameter of theIExpressPropertyValidator<TObj, T>,IExpressPropertyValidator<in TObj, TOptions, T>interfaces contravariant. - Add doc comments to the
IExpressValidatorBuilder<TObj>interface. - Add doc comments to the
IExpressValidatorBuilder<TObj, TOptions>andExpressValidatorBuilder<TObj, TOptions>. - Add doc comments to the
IBuilderWithPropValidator<TObj, TOptions, T>andBuilderWithPropValidator<TObj, TOptions, T>. - Add documentation for the full API.
- Add documentation README Chapter.
- Change logo.
0.1.0
- Update to FluentValidation 11.11.0.
- Made the TOptions parameter of the
IObjectValidator<TObj, TOptions>contravariant. - Made the TObj parameter of the IObjectValidator,
IObjectValidator<TObj, TOptions>interfaces contravariant. - ExpressValidator codebase size reduced by moving
PropertyInfoToFuncConverterclass to bench project. - Unreference the Benchmark.csproj project from reference to the 'ExpressValidator.csproj' project.
- Add the Rider-related .gitignore.
- Remove unused using directives.
- Update Benchmark.csproj nuget packages.
0.0.24
0.0.23
0.0.21
- Introduce the possibility to dynamically change the parameters of the 'FluentValidation' validators. (via
ExpressValidatorBuilder<TObj, TOptions>,ExpressValidator<TObj, TOptions>classes). - Do not compare a non-nullable value type to null during pre-validation.
- Refactor adding object member to validate by introducing
MemberInfoParser.ParseProperty,MemberInfoParser.ParseFieldmethods. - Slightly improve performance by using
PropertyInfo.GetGetMethodto get a property from an object. - Add benchmark to get the fastest way to get
FuncfromPropertyInfo. - Remove redundant overload of the
PropertyInfo.GetTypedValueextension method. - Remove redundant
MemberInfoParser.TryParsemethod overload. - Update to 'FluentValidation' 11.9.2.
- 'NUnit3TestAdapter' from 4.5.0 to 4.6.0.
- Move builder-related classes to the new 'ValidatorBuilders' folder.
- Update README.md and NuGet README.