Class McapWriter

Class Documentation

class McapWriter

An MCAP writer, used to log messages to an MCAP file.

Public Functions

FoxgloveError close()

Stops logging events and flushes buffered data.

McapWriter(McapWriter&&) = default

Default move constructor.

McapWriter &operator=(McapWriter&&) = default

Default move assignment.

~McapWriter() = default
McapWriter(const McapWriter&) = delete
McapWriter &operator=(const McapWriter&) = delete

Public Static Functions

static FoxgloveResult<McapWriter> create(const McapWriterOptions &options)

Create a new MCAP writer.

Note

Calls to create from multiple threads are safe, unless the same file path is given. Writing to an MCAP writer happens through channel logging, which is thread-safe.

Parameters:

options – The options for the MCAP writer.

Returns:

A new MCAP writer.