Module: Omnizip::Formats::Ole::Constants
- Included in:
- AllocationTable, Dirent, Header, Storage
- Defined in:
- lib/omnizip/formats/ole/constants.rb
Overview
OLE format constants
Constants for the OLE compound document format including magic bytes, special markers, and format-related values.
Constant Summary collapse
- MAGIC =
OLE magic signature (D0CF11E0A1B11AE1)
"\xd0\xcf\x11\xe0\xa1\xb1\x1a\xe1".b
- HEADER_SIZE =
Header size in bytes
76- HEADER_BLOCK_SIZE =
Header block size (always 512)
512- AVAIL =
Allocation table special markers
0xffffffff- EOC =
Free block
0xfffffffe- BAT =
End of chain
0xfffffffd- META_BAT =
Block stores BAT data
0xfffffffc- EOT =
End of tree marker for dirents
0xffffffff- DEFAULT_THRESHOLD =
Default threshold for small block vs big block (4096 bytes)
4096- BYTE_ORDER_LE =
Byte order marker for little-endian
"\xfe\xff".b
- DEFAULT_BIG_BLOCK_SHIFT =
Default block sizes
9- DEFAULT_SMALL_BLOCK_SHIFT =
512 bytes
6- DIRENT_TYPES =
Dirent types
{ 0 => :empty, 1 => :dir, 2 => :file, 5 => :root, }.freeze
- DIRENT_COLORS =
Dirent colors for red-black tree
{ 0 => :red, 1 => :black, }.freeze
- DIRENT_SIZE =
Dirent size in bytes
128- MAX_NAME_LENGTH =
Maximum name length in UTF-16 characters (including null terminator)
32