aGrUM 3.3.2
a C++ library for (probabilistic) graphical models
GumBinaryIO.h File Reference

Shared binary I/O helpers for GUM (jgum/bgum) serialization. More...

#include <cstdint>
#include <istream>
#include <ostream>
#include <stdexcept>
#include <vector>
#include <agrum/config.h>
#include <agrum/base/io/GumBinaryIO_inl.h>
Include dependency graph for GumBinaryIO.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

namespace  gum
 gum is the global namespace for all aGrUM entities

Functions

GUM_SHARED_PUBLIC std::vector< uint8_t > gum::_readVector_ (std::istream &is)
 Reads a length-prefixed byte vector from a binary stream (bgum format).
GUM_SHARED_PUBLIC void gum::_writeVector_ (std::ostream &os, const std::vector< uint8_t > &vec)
 Writes a length-prefixed byte vector to a binary stream (bgum format).
int gum::defaultJgumIndent ()
 The indentation used by the GUM writers (jgum text format) when none is given: the value of the key jgumIndent of section core in gum::Configuration.

Detailed Description

Shared binary I/O helpers for GUM (jgum/bgum) serialization.

Provides inline helpers to read/write a length-prefixed byte vector used by the msgpack binary format (.bgum) and the default indentation of the text format (.jgum). Defined here once to avoid duplication across GumBNReader/Writer, GumIDReader/Writer and GumMRFReader/Writer.

Author
Pierre-Henri WUILLEMIN(_at_LIP6)

Definition in file GumBinaryIO.h.