Skip to content

Commit

Permalink
simple_writer: allow writeInfo() also in data section
Browse files Browse the repository at this point in the history
  • Loading branch information
bkueng committed Dec 21, 2023
1 parent 29c9b7b commit 52ec0c5
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions ulog_cpp/simple_writer.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,17 +36,14 @@ class SimpleWriter {
~SimpleWriter();

/**
* Write a key-value info to the header. Typically used for versioning information.
* Write a key-value info. Typically used for versioning information and written to the header.
* @tparam T one of std::string, int32_t, float
* @param key (unique) name, e.g. sys_name
* @param value
*/
template <typename T>
void writeInfo(const std::string& key, const T& value)
{
if (_header_complete) {
throw UsageException("Header already complete");
}
_writer->messageInfo(ulog_cpp::MessageInfo(key, value));
}

Expand Down

0 comments on commit 52ec0c5

Please sign in to comment.