NAME

Archive::CAR::v1 - CAR v1 archive format implementation

SYNOPSIS

use Archive::CAR::v1;

my $v1 = Archive::CAR::v1->new();
open my $fh, '<:raw', 'archive.car';
$v1->read($fh);

DESCRIPTION

Archive::CAR::v1 implements the reading and writing of Content Addressable Archive (CAR) version 1 files. It handles the concatenation of CID-prefixed data blocks.

METHODS

read($fh, [ $limit ])

Reads CAR v1 data from the given filehandle using standard buffered I/O.

write($fh, $roots, $blocks)

Writes CAR v1 data to the given filehandle using standard buffered I/O. $roots is an arrayref of CIDs, and $blocks is an arrayref of hashes containing cid and data.

SEE ALSO

https://ipld.io/specs/transport/car/carv1/, Archive::CAR, Archive::CAR::v2

AUTHOR

Sanko Robinson <sanko@cpan.org>

COPYRIGHT

Copyright (C) 2026 by Sanko Robinson.

This library is free software; you can redistribute it and/or modify it under the terms of the Artistic License 2.0.