Add currently-unused resource data base class

This commit is contained in:
Matt Nadareski
2026-02-12 13:09:44 -05:00
parent dc86ed1456
commit 2d969048e3
9 changed files with 15 additions and 7 deletions

View File

@@ -995,6 +995,7 @@ namespace SabreTools.Data.Extensions
/// </summary>
/// <param name="entry">Resource data entry to parse into a string table resource</param>
/// <returns>A filled string table resource on success, null on error</returns>
/// TODO: Create concrete type for this and inherit from ResourceDataType
public static Dictionary<int, string?>? AsStringTable(this Models.PortableExecutable.Resource.DataEntry? entry)
{
// If we have an invalid entry, just skip

View File

@@ -9,7 +9,7 @@ namespace SabreTools.Data.Models.PortableExecutable.Resource.Entries
/// by eight. Then your application can randomly access the individual fixed-length entries.
/// </summary>
/// <see href="https://learn.microsoft.com/en-us/windows/win32/menurc/acceltableentry"/>
public sealed class AcceleratorTable
public sealed class AcceleratorTable : ResourceDataType
{
/// <summary>
/// Accelerator table entries

View File

@@ -4,7 +4,7 @@ namespace SabreTools.Data.Models.PortableExecutable.Resource.Entries
{
/// <see href="https://learn.microsoft.com/en-us/windows/win32/sbscs/manifest-file-schema"/>
[XmlRoot(ElementName = "assembly", Namespace = "urn:schemas-microsoft-com:asm.v1")]
public sealed class AssemblyManifest
public sealed class AssemblyManifest : ResourceDataType
{
[XmlAttribute("manifestVersion")]
public string? ManifestVersion { get; set; }

View File

@@ -7,7 +7,7 @@
/// describe the format of extended dialog box resources.
/// </summary>
/// <see href="https://learn.microsoft.com/en-us/windows/win32/menurc/resource-file-formats"/>
public sealed class DialogBoxResource
public sealed class DialogBoxResource : ResourceDataType
{
#region Dialog template

View File

@@ -5,7 +5,7 @@
/// definition provided here is for explanation only; it is not present in any standard header file.
/// </summary>
/// <see href="https://learn.microsoft.com/en-us/windows/win32/menurc/fontgrouphdr"/>
public sealed class FontGroupHeader
public sealed class FontGroupHeader : ResourceDataType
{
/// <summary>
/// The number of individual fonts associated with this resource.

View File

@@ -7,7 +7,7 @@
/// describe the format of extended menu resources.
/// </summary>
/// <see href="https://learn.microsoft.com/en-us/windows/win32/menurc/resource-file-formats"/>
public sealed class MenuResource
public sealed class MenuResource : ResourceDataType
{
/// <summary>
/// Menu header structure

View File

@@ -7,7 +7,7 @@ namespace SabreTools.Data.Models.PortableExecutable.Resource.Entries
/// box in a message table resource.
/// </summary>
/// <see href="https://learn.microsoft.com/en-us/windows/win32/api/winnt/ns-winnt-message_resource_data"/>
public sealed class MessageResourceData
public sealed class MessageResourceData : ResourceDataType
{
/// <summary>
/// The number of MESSAGE_RESOURCE_BLOCK structures.

View File

@@ -0,0 +1,7 @@
namespace SabreTools.Data.Models.PortableExecutable.Resource.Entries
{
/// <summary>
/// Generic base class for resource data types
/// </summary>
public abstract class ResourceDataType { }
}

View File

@@ -5,7 +5,7 @@
/// structure that contains all other file-version information structures.
/// </summary>
/// <see href="https://learn.microsoft.com/en-us/windows/win32/menurc/vs-versioninfo"/>
public sealed class VersionInfo
public sealed class VersionInfo : ResourceDataType
{
/// <summary>
/// The length, in bytes, of the VS_VERSIONINFO structure. This length does not