Method Invalid
| Improve this Doc View SourceInvalid(ValidationResult)
Represents a validation error that prevents the underlying service from completing.
Declaration
public static Result Invalid(this ValidationResult result)
Parameters
Type | Name | Description |
---|---|---|
FluentValidation.Results.ValidationResult | result | The result of running a validator. |
Returns
Type | Description |
---|---|
Result | An instance of type Result that does not contain a value. |
Remarks
Used in situations where the consumer provides invalid data.
Invalid(ValidationResult, String)
Represents a validation error that prevents the underlying service from completing.
Declaration
public static Result Invalid(this ValidationResult result, string message)
Parameters
Type | Name | Description |
---|---|---|
FluentValidation.Results.ValidationResult | result | The result of running a validator. |
String | message | An error message. |
Returns
Type | Description |
---|---|
Result | An instance of type Result that does not contain a value. |
Remarks
Used in situations where the consumer provides invalid data.