报告XP.ReportEngine基础类设计和接口开发。

This commit is contained in:
QI Mingxuan
2026-05-11 16:40:24 +08:00
parent 18111b8468
commit 1573a33a02
31 changed files with 2596 additions and 3 deletions
+22
View File
@@ -0,0 +1,22 @@
using System;
using System.IO;
namespace XP.ReportEngine.Models
{
/// <summary>
/// 报告生成结果 | Report generation result
/// </summary>
public class ReportResult
{
public bool IsSuccess { get; set; }
public MemoryStream PdfStream { get; set; }
public string ErrorMessage { get; set; }
public Exception Exception { get; set; }
public static ReportResult Success(MemoryStream stream)
=> new() { IsSuccess = true, PdfStream = stream };
public static ReportResult Failure(string message, Exception ex = null)
=> new() { IsSuccess = false, ErrorMessage = message, Exception = ex };
}
}