mirror of
https://github.com/SabreTools/SabreTools.Serialization.git
synced 2026-04-19 20:53:50 +00:00
This change looks dramatic, but it's just separating out the already-split namespaces into separate top-level folders. In theory, every single one could be built into their own Nuget package. `SabreTools.Serialization` still builds the normal Nuget package that is used by all other projects and includes all namespaces.
66 lines
2.1 KiB
C#
66 lines
2.1 KiB
C#
namespace SabreTools.Data.Models.SecuROM
|
|
{
|
|
public class MatroshkaEntry
|
|
{
|
|
/// <summary>
|
|
/// File entry path, either 256 or 512 bytes
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// Versions without a key prefix are 256 bytes.
|
|
/// Versions with key values either are 256 or 512 bytes.
|
|
/// Stored as a string as the rest of the 256/512 bytes are just padding.
|
|
/// </remarks>
|
|
public string Path { get; set; } = string.Empty;
|
|
|
|
/// <summary>
|
|
/// Type of the entry data
|
|
/// </summary>
|
|
public MatroshkaEntryType EntryType { get; set; }
|
|
|
|
/// <summary>
|
|
/// Data size
|
|
/// </summary>
|
|
public uint Size { get; set; }
|
|
|
|
/// <summary>
|
|
/// Data offset within the package
|
|
/// </summary>
|
|
public uint Offset { get; set; }
|
|
|
|
/// <summary>
|
|
/// Unknown value only seen in later versions
|
|
/// </summary>
|
|
/// <remarks>Does not indicate that the offset is or isn't a 64-bit value</remarks>
|
|
public uint? Unknown { get; set; }
|
|
|
|
/// <summary>
|
|
/// File modification time, stored in NTFS filetime.
|
|
/// </summary>
|
|
/// <see href="https://learn.microsoft.com/en-us/windows/win32/sysinfo/file-times"/>
|
|
public ulong ModifiedTime { get; set; }
|
|
|
|
/// <summary>
|
|
/// File creation time, stored in NTFS filetime.
|
|
/// </summary>
|
|
/// <see href="https://learn.microsoft.com/en-us/windows/win32/sysinfo/file-times"/>
|
|
public ulong CreatedTime { get; set; }
|
|
|
|
/// <summary>
|
|
/// File access time, stored in NTFS filetime.
|
|
/// </summary>
|
|
/// <see href="https://learn.microsoft.com/en-us/windows/win32/sysinfo/file-times"/>
|
|
public ulong AccessedTime { get; set; }
|
|
|
|
/// <summary>
|
|
/// MD5 hash of the data
|
|
/// </summary>
|
|
/// <remarks>16 bytes</remarks>
|
|
public byte[] MD5 { get; set; } = new byte[16];
|
|
|
|
/// <summary>
|
|
/// The file data, stored as a byte array
|
|
/// </summary>
|
|
public byte[] FileData { get; set; } = [];
|
|
}
|
|
}
|