PdfBytesResult
OfficeIMO.Pdf
Result returned by non-throwing in-memory PDF byte generation.
Inheritance
- object
- PdfBytesResult
Usage
Explore 2 API references to this type
This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.
Returned or exposed by 2
- Method PdfBytesResult.FromFailure
- Method PdfBytesResult.FromSuccess
Methods
public static PdfBytesResult FromFailure(Exception exception) #Creates a failed byte generation result from an exception captured by a wrapper or adapter.
Parameters
- exception System.Exception
Returns
PdfBytesResultpublic static PdfBytesResult FromSuccess(byte[] bytes) #Creates a successful byte generation result.
Parameters
- bytes byte[]
Returns
PdfBytesResultpublic byte[] RequireBytes() #Returns generated PDF bytes or throws with diagnostics when generation failed.
Returns
byte[]public byte[] RequireValue() #Returns the produced value or throws when the operation did not complete.
Returns
byte[]Inherited Methods
Properties
public byte[] Bytes { get; } #Generated PDF bytes when the operation completed; otherwise an empty array.
public byte[] Value { get; } #Gets the produced value, or null when the operation did not complete.
public long ByteCount { get; } #Number of generated bytes when the operation completed; otherwise 0.
public IReadOnlyList<string> Diagnostics { get; } #Human-readable diagnostics explaining why byte generation failed.
public Exception? Exception { get; } #Exception captured from the byte generation attempt, when available.
public IReadOnlyList<PdfTextEncodingDiagnostic> TextEncodingDiagnostics { get; } #Structured text encoding diagnostics captured from PDF generation failures.
public PdfConversionReport Report { get; } #Structured PDF output warnings captured for this byte-generation attempt.
public PdfPipelineReport Pipeline { get; } #End-to-end create/open, mutation, and byte-generation evidence.
public IReadOnlyList<PdfConversionWarning> Warnings { get; } #Structured PDF output warnings captured for this byte-generation attempt.