Class ChunksWriter¶
Defined in File writer.h
Inheritance Relationships¶
Derived Type¶
public ouster::sdk::osf::StreamingLayoutCWClass StreamingLayoutCW
Class Documentation¶
-
class ChunksWriter¶
Chunks writing strategy that decides when and how exactly write chunks to a file.
See RFC 0018 for Standard and Streaming Layout description.
Subclassed by ouster::sdk::osf::StreamingLayoutCW
Public Functions
-
virtual void save_message(const uint32_t stream_id, const ts_t receive_ts, const ts_t sensor_ts, const std::vector<uint8_t> &buf, const std::string &type) = 0¶
Save a message to a specified stream.
- Parameters:
stream_id[in] The stream id to associate with the message.
receive_ts[in] The receive timestamp for the messages.
sensor_ts[in] The sensor timestamp for the messages.
buf[in] A vector of message buffers to record.
type[in] Message type string of the message being saved.
-
virtual void finish() = 0¶
Finish the process of saving messages and write out the stream stats.
-
virtual void flush(uint32_t stream_id) = 0¶
Flush the latest chunk on this stream to disk.
- Parameters:
stream_id[in] id of the stream to flush
-
virtual uint32_t chunk_size() const = 0¶
Get the chunksize.
- Returns:
the chunk size
-
virtual ~ChunksWriter() = default¶
Default deconstructor.
-
virtual void save_message(const uint32_t stream_id, const ts_t receive_ts, const ts_t sensor_ts, const std::vector<uint8_t> &buf, const std::string &type) = 0¶