using System;using SystemCollectionsGeneric;using SystemText;using NewtonsoftJson;namespace ShenGoArchive summary 返回结果模型接口 summary public interface IResultModel summary
需要通过实例化实现IResultModel
// 假设返回结果为ResultModel<T>类型
var result = new ResultModel<string> { Successful = true, Data = "Hello World" };
if (result.Successful)
{
Console.WriteLine(result.Data); // 输出 "Hello World"
}
原文地址: https://www.cveoy.top/t/topic/fq6u 著作权归作者所有。请勿转载和采集!