37 lines
887 B
C#
37 lines
887 B
C#
using Newtonsoft.Json;
|
|
using System.Collections.Generic;
|
|
using Sockeye.Biz;
|
|
|
|
namespace Sockeye.Api.ControllerHelpers
|
|
{
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
///
|
|
/// </summary>
|
|
public class ApiError
|
|
{
|
|
public string Code { get; }
|
|
|
|
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
|
|
public List<ApiDetailError> Details { get; internal set; }
|
|
|
|
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
|
|
public string Message { get; }
|
|
|
|
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
|
|
public string Target { get; }
|
|
|
|
public ApiError(ApiErrorCode apiCode, string message = null, string target = null)
|
|
{
|
|
Code = ((int)apiCode).ToString();
|
|
Target = target;
|
|
Message=message;
|
|
}
|
|
|
|
}//eoc
|
|
|
|
|
|
}//eons |