Show / Hide Table of Contents

Class ValidationException

Represents an exception that is thrown when a validation check fails.

Inheritance
System.Object
ValidationException
Namespace: MediatorForge.CQRS.Exceptions
Assembly: MediatorForge.dll
Syntax
public class ValidationException : Exception

Constructors

| Improve this Doc View Source

ValidationException(IEnumerable<ValidationError>)

Initializes a new instance of the ValidationException class with a specified collection of validation errors.

Declaration
public ValidationException(IEnumerable<ValidationError> errors)
Parameters
Type Name Description
IEnumerable<ValidationError> errors

The collection of validation errors.

| Improve this Doc View Source

ValidationException(String, IEnumerable<ValidationError>)

Initializes a new instance of the ValidationException class with a specified error message and a collection of validation errors.

Declaration
public ValidationException(string message, IEnumerable<ValidationError> errors)
Parameters
Type Name Description
System.String message

The error message that explains the reason for the exception.

IEnumerable<ValidationError> errors

The collection of validation errors.

Properties

| Improve this Doc View Source

Errors

Gets the collection of validation errors.

Declaration
public IEnumerable<ValidationError> Errors { get; }
Property Value
Type Description
IEnumerable<ValidationError>

Methods

| Improve this Doc View Source

ToString()

Returns a string that represents the current object.

Declaration
public override string ToString()
Returns
Type Description
System.String

A string that represents the current object.

  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX