BililiveRecorder/BililiveRecorder.ToolBox/CommandResponse.cs

19 lines
463 B
C#
Raw Normal View History

2021-04-19 18:20:14 +08:00
using System;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
namespace BililiveRecorder.ToolBox
{
public class CommandResponse<TResponseData> where TResponseData : IResponseData
2021-04-19 18:20:14 +08:00
{
[JsonConverter(typeof(StringEnumConverter))]
public ResponseStatus Status { get; set; }
public TResponseData? Data { get; set; }
2021-04-19 18:20:14 +08:00
public string? ErrorMessage { get; set; }
public Exception? Exception { get; set; }
}
}