using System;
|
using System.Collections.Generic;
|
using System.Linq;
|
using System.Text;
|
using System.Threading.Tasks;
|
|
namespace HMI.Core.Exceptions
|
{
|
public class FormValidateException : Exception
|
{
|
public readonly List<FormGroupValidateResult> Result;
|
public bool Success
|
{
|
get => Result == null || Result.Count == 0;
|
}
|
|
public FormValidateException()
|
{
|
Result = new List<FormGroupValidateResult>();
|
}
|
}
|
|
public class FormGroupValidateResult
|
{
|
public readonly string Message;
|
public readonly object Sender;
|
|
public FormGroupValidateResult(string message, object sender)
|
{
|
Message = message;
|
Sender = sender;
|
}
|
}
|
}
|