New built-in plugin PEViewer

This commit is contained in:
ema
2024-12-15 10:05:35 +08:00
parent 883657f6d5
commit dc67ab0065
25 changed files with 2457 additions and 0 deletions

View File

@@ -0,0 +1,26 @@
using System;
namespace QuickLook.Plugin.PEViewer.PEImageParser;
/// <summary>
/// The exception that is thrown when parsing of a <see cref="PEImage" /> fails.
/// </summary>
public sealed class PEImageParseException : Exception
{
/// <summary>
/// Gets the offset within the image file at which parsing failed.
/// </summary>
public int Offset { get; private set; }
/// <summary>
/// Initializes a new instance of the <see cref="PEImageParseException" /> class.
/// </summary>
/// <param name="offset">The offset within the image file at which parsing failed.</param>
/// <param name="message">The message that describes the error.</param>
public PEImageParseException(int offset, string message) : base(message)
{
_ = message ?? throw new ArgumentNullException(nameof(message));
Offset = offset;
}
}