Files
SabreTools.Models/Compression/MSZIP/DeflateBlock.cs

35 lines
1.6 KiB
C#
Raw Normal View History

2023-09-22 11:54:48 -04:00
namespace SabreTools.Models.Compression.MSZIP
{
/// <summary>
/// Each MSZIP block is the result of a single deflate compression operation, as defined in [RFC1951].
/// The compressor that performs the compression operation MUST generate one or more RFC 1951
/// blocks, as defined in [RFC1951]. The number, deflation mode, and type of RFC 1951 blocks in each
/// MSZIP block is determined by the compressor, as defined in [RFC1951]. The last RFC 1951 block in
/// each MSZIP block MUST be marked as the "end" of the stream(1), as defined by [RFC1951]
/// section 3.2.3. Decoding trees MUST be discarded after each RFC 1951 block, but the history buffer
/// MUST be maintained.Each MSZIP block MUST represent no more than 32 KB of uncompressed data.
/// </summary>
/// <see href="https://interoperability.blob.core.windows.net/files/MS-MCI/%5bMS-MCI%5d.pdf"/>
2023-09-22 15:32:19 -04:00
public class DeflateBlock
2023-09-22 11:54:48 -04:00
{
2023-09-22 15:32:19 -04:00
/// <summary>
/// Deflate block (RFC-1951) header
/// </summary>
public DeflateBlockHeader? Header { get; set; }
/// <summary>
/// Compression-specific data header
/// </summary>
public DataHeader? DataHeader { get; set; }
2023-09-22 11:54:48 -04:00
/// <summary>
2023-09-22 15:37:49 -04:00
/// MSZIP data
2023-09-22 11:54:48 -04:00
/// </summary>
2023-09-22 15:37:49 -04:00
/// <remarks>
/// Depending on the implementation of these models, this property could either be
/// compressed or uncompressed data. Keep this in mind when using the built
/// versions of this model.
/// </remarks>
2023-09-22 11:54:48 -04:00
public byte[]? Data { get; set; }
}
}