class Bakelite::Container::Reader

Overview

Parses standalone .bkl archives or appended executable volumes. Reads the 32-byte trailer at the end of the file, directly loads the file index, and constructs StoredItems that stream chunks from the container file on demand.

Defined in:

bakelite/container/reader.cr

Constructors

Class Method Summary

Instance Method Summary

Constructor Detail

def self.new(target_path : Path | String) #

Class Method Detail

def self.has_trailer?(file_path : Path | String) : Bool #

Checks whether the target file contains a valid Bakelite volume trailer.


def self.mount(registry : FS::Registry, archive_path : String | Path, volume_name : Symbol | String | Nil = nil, mount : String | Nil = nil, priority : Int32 = 0) : Volume | Nil #

High-level helper to mount volumes from an archive file into a registry.


Instance Method Detail

def read : Array(Volume) #

Parses the container and returns all extracted volumes.


def target_path : Path #

def trailer : Trailer | Nil #

def volumes : Array(Volume) #