IRuleBuilder<T, TProperty>
Rule builder
Assembly: ServiceStack.dll
View Source
Declaration
public interface IRuleBuilder<T, out TProperty>
Methods
SetValidator(IPropertyValidator)
Associates a validator with this the property for this rule builder.
View Source
Declaration
IRuleBuilderOptions<T, TProperty> SetValidator(IPropertyValidator validator)
Returns
ServiceStack.FluentValidation.IRuleBuilderOptions<<T>,<TProperty>>
Parameters
Type | Name | Description |
---|---|---|
ServiceStack.FluentValidation.Validators.IPropertyValidator | validator | The validator to set |
|
SetValidator(IValidator<TProperty>, String[])
Associates an instance of IValidator with the current property rule.
View Source
Declaration
IRuleBuilderOptions<T, TProperty> SetValidator(IValidator<TProperty> validator, params string[] ruleSets)
Returns
ServiceStack.FluentValidation.IRuleBuilderOptions<<T>,<TProperty>>
Parameters
Type | Name | Description |
---|---|---|
ServiceStack.FluentValidation.IValidator<T> | validator | The validator to use |
|
| System.String[]
| ruleSets |
|
SetValidator<TValidator>(Func<T, TValidator>, String[])
Associates a validator provider with the current property rule.
View Source
Declaration
IRuleBuilderOptions<T, TProperty> SetValidator<TValidator>(Func<T, TValidator> validatorProvider, params string[] ruleSets)
where TValidator : IValidator<TProperty>
Returns
ServiceStack.FluentValidation.IRuleBuilderOptions<<T>,<TProperty>>
Parameters
Type | Name | Description |
---|---|---|
System.Func<<T>,<TValidator>> | validatorProvider | The validator provider to use |
|
| System.String[]
| ruleSets |
|
Type Parameters
TValidator
SetValidator<TValidator>(Func<T, TProperty, TValidator>, String[])
Associates a validator provider with the current property rule.
View Source
Declaration
IRuleBuilderOptions<T, TProperty> SetValidator<TValidator>(Func<T, TProperty, TValidator> validatorProvider, params string[] ruleSets)
where TValidator : IValidator<TProperty>
Returns
ServiceStack.FluentValidation.IRuleBuilderOptions<<T>,<TProperty>>
Parameters
Type | Name | Description |
---|---|---|
System.Func<<T>,<TProperty>,<TValidator>> | validatorProvider | The validator provider to use |
|
| System.String[]
| ruleSets |
|
Type Parameters
TValidator