VLink 2.0.0
A high-performance communication middleware
Loading...
Searching...
No Matches
database_reader.h File Reference

Concrete BagReader implementation for the SQLite-backed VLink bag format. More...

#include <future>
#include <memory>
#include <string>
#include <vector>
#include "./bag_reader.h"
Include dependency graph for database_reader.h:

Go to the source code of this file.

Classes

 Concrete SQLite-backed bag file player. More...

Namespaces

Detailed Description

Concrete BagReader implementation for the SQLite-backed VLink bag format.

DatabaseReader reads bag files in the SQLite-backed .vdb format and inherits all playback, seeking, fix, and reindex capabilities from BagReader.

The .vdb format stores messages in a structured SQLite database, enabling efficient random-access queries, indexed playback, and in-place repair with fix().

Usage
auto reader = vlink::BagReader::create("/data/recording.vdb");
// or explicitly:
auto reader = std::make_shared<vlink::DatabaseReader>("/data/recording.vdb");
reader->register_output_callback([](int64_t ts, const std::string& url,
vlink::ActionType action, const vlink::Bytes& data) {
// process message
});
reader->async_run();
reader->play({});
See also
BagReader, McapReader