Skip to content
docsv0.1.1

BackupManifest

A record of one completed backup: which run (`id`/`createdAt`), where the database dump and storage archive landed, and their sizes. {@see BackupManager} (Task 7) produces these; hosts persist/list them via `toArray()`/`fromArray()`.

BackupManifest::__construct()

public function __construct(string $id, string $createdAt, string $dbFile, string $storageFile, int $dbBytes, int $storageBytes):

Parameters

Parameters of __construct()
NameTypeDescription
$idstring
$createdAtstring
$dbFilestring
$storageFilestring
$dbBytesint
$storageBytesint

BackupManifest::toArray()

public function toArray(): array

El manifiesto como dato plano, listo para escribirse junto al respaldo.

BackupManifest::fromArray()

public static function fromArray(array $data): self

Reconstruye el manifiesto de un respaldo ya escrito. Es la mitad que permite restaurar: sin ella, un respaldo es un archivo que nadie sabe interpretar.

Parameters

Parameters of fromArray()
NameTypeDescription
$dataarray{id: string, createdAt: string, dbFile: string, storageFile: string, dbBytes: int, storageBytes: int}