Expand description
AppleSingle and AppleDouble archive format reader and JSON exporter.
Syntactically, AppleSingle and AppleDouble share the same container format with distinct magic numbers:
- AppleSingle (
0x00051600): holds data fork, resource fork, and metadata. - AppleDouble (
0x00051607): holds resource fork and metadata in an auxiliary companion file (such as._<filename>), keeping the data fork in a separate plain file.
Structs§
- Apple
Archive - Decoded AppleSingle or AppleDouble archive.
- Apple
Archive Entry - Raw entry descriptor within the archive header table.
- Apple
Dates Info - Complete timestamps record for AppleSingle / AppleDouble file dates entry (ID 7).
- Apple
Extended Attribute - Extended attribute extracted from AppleDouble
ATTRblock. - Apple
RawEntry - Preserved raw unrecognized entry from AppleSingle or AppleDouble archive.
- Apple
Read Options - Options controlling which AppleSingle, AppleDouble, and Windows alternate data stream companion styles to detect and unpack on read.
- Extended
Finder Info - Extended Finder information (
FXInfo, 16 bytes). - Extended
Flags - Extended Finder boolean flags decoded from classic Mac OS 8-bit
xflags. - Finder
Flags - Decoded Finder flags boolean flags.
- Finder
Info - Complete Finder metadata (
FInfo+ optionalFXInfo).
Enums§
- Apple
Double Style - The storage style used for auxiliary AppleDouble companion files.
- Apple
Format - Archive format variant identified by the header magic.
- Apple
Single Extension - Extension convention for AppleSingle files.
- Entry
Type - Standard AppleSingle / AppleDouble entry identifier.
- Finder
Label - Decoded Finder label color and names.
Constants§
- APPLEDOUBLE_
MAGIC_ BE - AppleDouble magic number in big-endian byte order.
- APPLEDOUBLE_
MAGIC_ LE - AppleDouble magic number in little-endian byte order.
- APPLESINGLE_
MAGIC_ BE - AppleSingle magic number in big-endian byte order.
- APPLESINGLE_
MAGIC_ LE - AppleSingle magic number in little-endian byte order.
- ATTR_
MAGIC_ BE - Extended attributes magic “ATTR” in big-endian (
0x41545452). - SECONDS_
1970_ TO_ 2000 - Number of seconds between Unix epoch (1970-01-01) and Mac OS 2000 epoch (2000-01-01).
- TIMESTAMP_
UNSET_ SENTINEL - Sentinel value indicating an unset timestamp in AppleSingle v2 date records.
- VERSION_
1_ 0_ BE - Legacy format version 1.0.
- VERSION_
1_ 0_ LE - Legacy format version 1.0 in little-endian.
- VERSION_
2_ 0_ BE - Standard AppleSingle/AppleDouble format version 2.0.
- VERSION_
2_ 0_ LE - Standard AppleSingle/AppleDouble format version 2.0 in little-endian.
Functions§
- get_
apple_ single_ double_ data - Retrieves AppleSingle / AppleDouble test fixture data by path key.
- get_
companion_ path - Computes the path to an AppleDouble companion file according to
style. - is_
apple_ double_ file - Returns whether the file at
pathis a regular file starting with AppleDouble magic bytes. - is_
apple_ single_ file - Returns whether the file at
pathis a regular file starting with AppleSingle magic bytes. - read_
apple_ single_ double - Reads an AppleSingle or AppleDouble file from a raw byte slice.
- write_
apple_ single_ double - Serializes an
AppleArchiveto a raw byte buffer (AppleSingle or AppleDouble).
Type Aliases§
- Apple
Unrecognized Entry - Type alias reflecting that raw entries preserve unrecognized container records.