Files
SabreTools.Models/PortableExecutable/VersionInfo.cs

62 lines
2.4 KiB
C#
Raw Normal View History

2023-09-04 00:12:49 -04:00
namespace SabreTools.Models.PortableExecutable
2023-09-04 00:11:04 -04:00
{
/// <summary>
/// Represents the organization of data in a file-version resource. It is the root
/// 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
{
/// <summary>
/// The length, in bytes, of the VS_VERSIONINFO structure. This length does not
/// include any padding that aligns any subsequent version resource data on a
/// 32-bit boundary.
/// </summary>
2023-09-10 21:24:10 -04:00
public ushort Length { get; set; }
2023-09-04 00:11:04 -04:00
/// <summary>
/// The length, in bytes, of the Value member. This value is zero if there is no
/// Value member associated with the current version structure.
/// </summary>
2023-09-10 21:24:10 -04:00
public ushort ValueLength { get; set; }
2023-09-04 00:11:04 -04:00
/// <summary>
/// The type of data in the version resource. This member is 1 if the version resource
/// contains text data and 0 if the version resource contains binary data.
/// </summary>
2023-09-10 21:24:10 -04:00
public VersionResourceType ResourceType { get; set; }
2023-09-04 00:11:04 -04:00
/// <summary>
/// The Unicode string L"VS_VERSION_INFO".
/// </summary>
2023-09-10 21:24:10 -04:00
public string? Key { get; set; }
2023-09-04 00:11:04 -04:00
/// <summary>
/// Contains as many zero words as necessary to align the Value member on a 32-bit boundary.
/// </summary>
2023-09-10 21:24:10 -04:00
public ushort Padding1 { get; set; }
2023-09-04 00:11:04 -04:00
/// <summary>
/// Arbitrary data associated with this VS_VERSIONINFO structure. The ValueLength member
/// specifies the length of this member; if ValueLength is zero, this member does not exist.
/// </summary>
2023-09-10 21:24:10 -04:00
public FixedFileInfo? Value { get; set; }
2023-09-04 00:11:04 -04:00
/// <summary>
/// As many zero words as necessary to align the Children member on a 32-bit boundary.
/// These bytes are not included in wValueLength. This member is optional.
/// </summary>
2023-09-10 21:24:10 -04:00
public ushort Padding2 { get; set; }
2023-09-04 00:11:04 -04:00
/// <summary>
/// The StringFileInfo structure to store user-defined string information data.
/// </summary>
2023-09-10 21:24:10 -04:00
public StringFileInfo? StringFileInfo { get; set; }
2023-09-04 00:11:04 -04:00
/// <summary>
/// The VarFileInfo structure to store language information data.
/// </summary>
2023-09-10 21:24:10 -04:00
public VarFileInfo? VarFileInfo { get; set; }
2023-09-04 00:11:04 -04:00
}
}