Files
SabreTools.Serialization/SabreTools.Data.Models/ZArchive/NameEntry.cs
Deterous 5bb8557555 ZArchive support (#75)
* ZArchive support

* Fix offset record format

* Simplfiy Extensions

* Delete unused writers and test data

* Rework reader

* Fix build
2026-04-02 02:18:47 -04:00

28 lines
975 B
C#

namespace SabreTools.Data.Models.ZArchive
{
/// <summary>
/// Filename entry in the NameTable
/// </summary>
/// <see href="https://github.com/Exzap/ZArchive/"/>
public class NameEntry
{
/// <summary>
/// Filename length, with MSB set to 0 for filenames less than 127 long
/// NodeLengthShort and NodeLengthLong fields are exclusive, and one must be present
/// </summary>
public byte? NodeLengthShort { get; set; }
/// <summary>
/// Filename length, with prefix byte's MSB set to 1 for filenames greater than 127 long
/// NodeLengthShort and NodeLengthLong fields are exclusive, and one must be present
/// </summary>
public ushort? NodeLengthLong { get; set; }
/// <summary>
/// UTF-8 encoded file name
/// </summary>
/// <remarks>Maximum length of 2^15 - 1 bytes</remarks>
public byte[] NodeName { get; set; } = [];
}
}