23,776
edits
mNo edit summary |
mNo edit summary |
||
Line 9: | Line 9: | ||
Sets the level at which messages will be logged. | Sets the level at which messages will be logged. | ||
The method header is: | The method header is: | ||
<syntaxhighlight lang=" | <syntaxhighlight lang="c"> | ||
/** | /** | ||
* @brief Sets the level for which the messages will be logged | * @brief Sets the level for which the messages will be logged | ||
Line 25: | Line 25: | ||
'''Use case''': | '''Use case''': | ||
<syntaxhighlight lang=" | <syntaxhighlight lang="c"> | ||
libmisb::LibMisb libmisb; | libmisb::LibMisb libmisb; | ||
libmisb.SetLogLevel(LIBMISB_DEBUG); | libmisb.SetLogLevel(LIBMISB_DEBUG); | ||
Line 86: | Line 86: | ||
The method header is: | The method header is: | ||
<syntaxhighlight lang=" | <syntaxhighlight lang="c"> | ||
/** | /** | ||
* @brief Set the Formatter object to convert between format to metadata | * @brief Set the Formatter object to convert between format to metadata | ||
Line 100: | Line 100: | ||
Remeber to include the formatter header in your code: | Remeber to include the formatter header in your code: | ||
<syntaxhighlight lang=" | <syntaxhighlight lang="c"> | ||
#include "libmisb/formatter/jsonformatter.hpp" | #include "libmisb/formatter/jsonformatter.hpp" | ||
</syntaxhighlight> | </syntaxhighlight> | ||
<syntaxhighlight lang=" | <syntaxhighlight lang="c"> | ||
libmisb::LibMisb libmisb; | libmisb::LibMisb libmisb; | ||
std::shared_ptr<libmisb::formatter::iFormatter> json_formatter = std::make_shared<libmisb::formatter::JsonFormatter>(); | std::shared_ptr<libmisb::formatter::iFormatter> json_formatter = std::make_shared<libmisb::formatter::JsonFormatter>(); | ||
Line 114: | Line 114: | ||
The method header is: | The method header is: | ||
<syntaxhighlight lang=" | <syntaxhighlight lang="c"> | ||
/** | /** | ||
* @brief Receive string metadata that will convert to KLV | * @brief Receive string metadata that will convert to KLV | ||
Line 136: | Line 136: | ||
'''Use case''': | '''Use case''': | ||
<syntaxhighlight lang=" | <syntaxhighlight lang="c"> | ||
libmisb::LibMisb libmisb; | libmisb::LibMisb libmisb; | ||
// Remember to set formatter | // Remember to set formatter | ||
Line 147: | Line 147: | ||
Performs decoding of the metadata found in a KLV byte packet. The decoding will depend on the MISB standard key found in the packet. Once decoded, it will return the data according to the configured format type. | Performs decoding of the metadata found in a KLV byte packet. The decoding will depend on the MISB standard key found in the packet. Once decoded, it will return the data according to the configured format type. | ||
The method header is: | The method header is: | ||
<syntaxhighlight lang=" | <syntaxhighlight lang="c"> | ||
/** | /** | ||
* @brief Receive packet encoded metadata that will convert to the formatter | * @brief Receive packet encoded metadata that will convert to the formatter | ||
Line 167: | Line 167: | ||
'''Use case''': | '''Use case''': | ||
<syntaxhighlight lang=" | <syntaxhighlight lang="c"> | ||
libmisb::LibMisb libmisb; | libmisb::LibMisb libmisb; | ||
// Remember to set formatter | // Remember to set formatter |