libDwm-0.9.45
Dwm::FileIO Class Reference

This class contains a collection of static functions for reading and writing simple types, in network byte order (MSB first). More...

#include <DwmFileIO.hh>

Static Public Member Functions

static size_t Read (FILE *f, char &c)
 Reads c from f.
 
static size_t Write (FILE *f, char c)
 Writes c to f.
 
static size_t Read (FILE *f, uint8_t &c)
 Reads c from f.
 
static size_t Write (FILE *f, uint8_t c)
 Writes c to f.
 
static size_t Read (FILE *f, bool &b)
 Reads b from f.
 
static size_t Write (FILE *f, bool b)
 Writes b to f.
 
static size_t Read (FILE *f, int16_t &val)
 Reads val from f, in network byte order (MSB first).
 
static size_t Write (FILE *f, int16_t val)
 Writes val to f, in network byte order (MSB first).
 
static size_t Read (FILE *f, uint16_t &val)
 Reads val from f, in network byte order (MSB first).
 
static size_t Write (FILE *f, uint16_t val)
 Writes val to f, in network byte order (MSB first).
 
static size_t Read (FILE *f, int32_t &val)
 Reads val from f, in network byte order (MSB first).
 
static size_t Write (FILE *f, int32_t val)
 Writes val to f, in network byte order (MSB first).
 
static size_t Read (FILE *f, uint32_t &val)
 Reads val from f, in network byte order (MSB first).
 
static size_t Write (FILE *f, uint32_t val)
 Writes val to f, in network byte order (MSB first).
 
static size_t Read (FILE *f, int64_t &val)
 Reads val from f, in network byte order (MSB first).
 
static size_t Write (FILE *f, const int64_t &val)
 Writes val to f, in network byte order (MSB first).
 
static size_t Read (FILE *f, uint64_t &val)
 Reads val from f, in network byte order (MSB first).
 
static size_t Write (FILE *f, const uint64_t &val)
 Writes val to f, in network byte order (MSB first).
 
static size_t Read (FILE *f, float &val)
 Reads val from f, in IEEE format (see RFC 1832 and/or ANSI/IEEE Standard 754-1985).
 
static size_t Write (FILE *f, float val)
 Writes val to f, in IEEE format (see RFC 1832 and/or ANSI/IEEE Standard 754-1985).
 
static size_t Read (FILE *f, double &val)
 Reads val from f, in IEEE format (see RFC 1832 and/or ANSI/IEEE Standard 754-1985).
 
static size_t Write (FILE *f, const double &val)
 Writes val to f, in IEEE format (see RFC 1832 and/or ANSI/IEEE Standard 754-1985).
 
static size_t Read (FILE *f, std::string &s)
 Reads s from f.
 
static size_t Write (FILE *f, const std::string &s)
 Writes s to f.
 
static size_t Read (FILE *f, FileReadable &val)
 Wrapper function to read a FileReadable object from a FILE.
 
static size_t Read (FILE *f, HasFileRead auto &val)
 Reads val from FILE f, where val meets the requirements of the HasFileRead concept.
 
static size_t Write (FILE *f, const FileWritable &val)
 Wrapper function to write a FileWritable object to a FILE.
 
static size_t Write (FILE *f, const HasFileWrite auto &val)
 Writes val to FILE f, where val meets the requirements of the HasFileWrite concept.
 
template<typename _firstT , typename _secondT >
static size_t Read (FILE *f, std::pair< _firstT, _secondT > &p)
 Reads a pair<_firstT,_secondT> from a FILE.
 
template<typename _firstT , typename _secondT >
static size_t Write (FILE *f, const std::pair< _firstT, _secondT > &p)
 Writes a pair<_firstT,_secondT> to a FILE.
 
template<typename _keyT , typename _valueT , typename _Compare , typename _Alloc >
static size_t Read (FILE *f, std::map< _keyT, _valueT, _Compare, _Alloc > &m)
 Reads a map<_keyT,_valueT> from a FILE.
 
template<typename _keyT , typename _valueT , typename _Compare , typename _Alloc >
static size_t Write (FILE *f, const std::map< _keyT, _valueT, _Compare, _Alloc > &m)
 Writes a map<_keyT,_valueT> to a FILE.
 
template<typename _keyT , typename _valueT , typename _Compare , typename _Alloc >
static size_t Read (FILE *f, std::multimap< _keyT, _valueT, _Compare, _Alloc > &m)
 Reads a multimap<_keyT,_valueT> from a FILE.
 
template<typename _keyT , typename _valueT , typename _Compare , typename _Alloc >
static size_t Write (FILE *f, const std::multimap< _keyT, _valueT, _Compare, _Alloc > &m)
 Writes a multimap<_keyT,_valueT> to a FILE.
 
template<typename _valueT , size_t N>
static size_t Read (FILE *f, std::array< _valueT, N > &a)
 Reads an array<_valueT,N> from a FILE.
 
template<typename _valueT , size_t N>
static size_t Write (FILE *f, const std::array< _valueT, N > &a)
 Writes an array<_valueT,N> to a FILE.
 
template<typename _valueT , typename _Alloc >
static size_t Read (FILE *f, std::vector< _valueT, _Alloc > &v)
 Reads a vector<_valueT> from a FILE.
 
template<typename _valueT , typename _Alloc >
static size_t Write (FILE *f, const std::vector< _valueT, _Alloc > &v)
 Writes a vector<_valueT> to a FILE.
 
template<typename _valueT , typename _Alloc >
static size_t Read (FILE *f, std::deque< _valueT, _Alloc > &d)
 Reads a deque<_valueT> from a FILE.
 
template<typename _valueT , typename _Alloc >
static size_t Write (FILE *f, const std::deque< _valueT, _Alloc > &d)
 Writes a deque<_valueT> to a FILE.
 
template<typename _valueT , typename _Alloc >
static size_t Read (FILE *f, std::list< _valueT, _Alloc > &l)
 Reads a list<_valueT> from a FILE.
 
template<typename _valueT , typename _Alloc >
static size_t Write (FILE *f, const std::list< _valueT, _Alloc > &l)
 Writes a list<_valueT> to a FILE.
 
template<typename _valueT , typename _Compare , typename _Alloc >
static size_t Read (FILE *f, std::set< _valueT, _Compare, _Alloc > &l)
 Reads a set<_valueT> from a FILE.
 
template<typename _valueT , typename _Compare , typename _Alloc >
static size_t Write (FILE *f, const std::set< _valueT, _Compare, _Alloc > &l)
 Writes a set<_valueT> to a FILE.
 
template<typename _valueT , typename _Compare , typename _Alloc >
static size_t Read (FILE *f, std::multiset< _valueT, _Compare, _Alloc > &l)
 Reads a multiset<_valueT> from a FILE.
 
template<typename _valueT , typename _Compare , typename _Alloc >
static size_t Write (FILE *f, const std::multiset< _valueT, _Compare, _Alloc > &l)
 Writes a multiset<_valueT> to a FILE.
 
template<typename... Args>
static size_t Read (FILE *f, std::tuple< Args... > &t)
 Reads a tuple from a FILE. Returns 1 on success, 0 on failure.
 
template<typename... Args>
static size_t Write (FILE *f, const std::tuple< Args... > &t)
 Writes a tuple to a FILE. Returns 1 on success, 0 on failure.
 
static size_t Read (FILE *fp, std::monostate &sm)
 Just a dummy helper function for std::variant instances that hold a std::monostate.
 
static size_t Write (FILE *fp, const std::monostate &sm)
 Just a dummy helper function for std::variant instances that hold a std::monostate.
 
template<typename... Ts>
static size_t Read (FILE *fp, std::variant< Ts... > &v)
 Reads a variant from a FILE. Returns 1 on success, 0 on failure.
 
template<typename... Ts>
static size_t Write (FILE *fp, const std::variant< Ts... > &v)
 Writes a variant to a FILE. Returns 1 on success, 0 on failure.
 
template<typename _keyT , typename _valueT , typename _Hash , typename _Pred , typename _Alloc >
static size_t Read (FILE *f, std::unordered_map< _keyT, _valueT, _Hash, _Pred, _Alloc > &hm)
 Reads an unordered_map from a FILE.
 
template<typename _keyT , typename _valueT , typename _Hash , typename _Pred , typename _Alloc >
static size_t Write (FILE *f, const std::unordered_map< _keyT, _valueT, _Hash, _Pred, _Alloc > &hm)
 Writes an unordered_map to a FILE.
 
template<typename _keyT , typename _valueT , typename _Hash , typename _Pred , typename _Alloc >
static size_t Read (FILE *f, std::unordered_multimap< _keyT, _valueT, _Hash, _Pred, _Alloc > &hm)
 Reads an unordered_multimap from a FILE.
 
template<typename _keyT , typename _valueT , typename _Hash , typename _Pred , typename _Alloc >
static size_t Write (FILE *f, const std::unordered_multimap< _keyT, _valueT, _Hash, _Pred, _Alloc > &hm)
 Writes an unordered_multimap to a FILE.
 
template<typename _valueT , typename _Hash , typename _Pred , typename _Alloc >
static size_t Read (FILE *f, std::unordered_set< _valueT, _Hash, _Pred, _Alloc > &hm)
 Reads an unordered_set from a FILE.
 
template<typename _valueT , typename _Hash , typename _Pred , typename _Alloc >
static size_t Write (FILE *f, const std::unordered_set< _valueT, _Hash, _Pred, _Alloc > &hm)
 Writes an unordered_set to a FILE.
 
template<typename _valueT , typename _Hash , typename _Pred , typename _Alloc >
static size_t Read (FILE *f, std::unordered_multiset< _valueT, _Hash, _Pred, _Alloc > &hm)
 Reads an unordered_multiset from a FILE.
 
template<typename _valueT , typename _Hash , typename _Pred , typename _Alloc >
static size_t Write (FILE *f, const std::unordered_multiset< _valueT, _Hash, _Pred, _Alloc > &hm)
 Writes an unordered_multiset to a FILE.
 
template<typename... Args>
static size_t ReadV (FILE *f, Args &...args)
 Reads multiple objects from a FILE.
 
template<typename... Args>
static size_t WriteV (FILE *f, const Args &...args)
 Writes multiple objects to a FILE.
 

Detailed Description

This class contains a collection of static functions for reading and writing simple types, in network byte order (MSB first).

It also contains functions to read and write strings. It also contains function templates to read and write STL deques, lists, vectors, maps, multimaps, sets, multisets, unordered_maps, unordered_multimaps, unordered_sets, unordered_multisets, tuples and variants. We use our member functions to handle reading and writing simple types in the containers, and function templates to handle reading and writing other class types. For a user-defined class, the class must implement the FileReadable and FileWritable interfaces, since our function templates simply call out to them. Since templates are static polymorphism, you don't need to inherit from FileReadable and FileWritable, but you must implement the interfaces.

Member Function Documentation

◆ Read() [1/26]

static size_t Dwm::FileIO::Read ( FILE * f,
bool & b )
static

Reads b from f.

Returns the number of bytes read (1 on success).

◆ Read() [2/26]

static size_t Dwm::FileIO::Read ( FILE * f,
char & c )
static

Reads c from f.

Returns the number of bytes read (1 on success, 0 on failure).

◆ Read() [3/26]

static size_t Dwm::FileIO::Read ( FILE * f,
double & val )
static

Reads val from f, in IEEE format (see RFC 1832 and/or ANSI/IEEE Standard 754-1985).

Returns the number of bytes read (8 on success).

◆ Read() [4/26]

static size_t Dwm::FileIO::Read ( FILE * f,
float & val )
static

Reads val from f, in IEEE format (see RFC 1832 and/or ANSI/IEEE Standard 754-1985).

Returns the number of bytes read (4 on success).

◆ Read() [5/26]

static size_t Dwm::FileIO::Read ( FILE * f,
int16_t & val )
static

Reads val from f, in network byte order (MSB first).

Returns the number of bytes read (2 on success).

◆ Read() [6/26]

static size_t Dwm::FileIO::Read ( FILE * f,
int32_t & val )
static

Reads val from f, in network byte order (MSB first).

Returns the number of bytes read (4 on success).

◆ Read() [7/26]

static size_t Dwm::FileIO::Read ( FILE * f,
int64_t & val )
static

Reads val from f, in network byte order (MSB first).

Returns the number of bytes read (8 on success).

◆ Read() [8/26]

template<typename _valueT , size_t N>
static size_t Dwm::FileIO::Read ( FILE * f,
std::array< _valueT, N > & a )
inlinestatic

Reads an array<_valueT,N> from a FILE.

Returns 1 on success, 0 on failure.

Here is the call graph for this function:

◆ Read() [9/26]

template<typename _valueT , typename _Alloc >
static size_t Dwm::FileIO::Read ( FILE * f,
std::deque< _valueT, _Alloc > & d )
inlinestatic

Reads a deque<_valueT> from a FILE.

Returns 1 on success, 0 on failure.

◆ Read() [10/26]

template<typename _valueT , typename _Alloc >
static size_t Dwm::FileIO::Read ( FILE * f,
std::list< _valueT, _Alloc > & l )
inlinestatic

Reads a list<_valueT> from a FILE.

Returns 1 on success, 0 on failure.

◆ Read() [11/26]

template<typename _keyT , typename _valueT , typename _Compare , typename _Alloc >
static size_t Dwm::FileIO::Read ( FILE * f,
std::map< _keyT, _valueT, _Compare, _Alloc > & m )
inlinestatic

Reads a map<_keyT,_valueT> from a FILE.

Returns 1 on success, 0 on failure.

◆ Read() [12/26]

template<typename _keyT , typename _valueT , typename _Compare , typename _Alloc >
static size_t Dwm::FileIO::Read ( FILE * f,
std::multimap< _keyT, _valueT, _Compare, _Alloc > & m )
inlinestatic

Reads a multimap<_keyT,_valueT> from a FILE.

Returns 1 on success, 0 on failure.

◆ Read() [13/26]

template<typename _valueT , typename _Compare , typename _Alloc >
static size_t Dwm::FileIO::Read ( FILE * f,
std::multiset< _valueT, _Compare, _Alloc > & l )
inlinestatic

Reads a multiset<_valueT> from a FILE.

Returns 1 on success, 0 on failure.

◆ Read() [14/26]

template<typename _firstT , typename _secondT >
static size_t Dwm::FileIO::Read ( FILE * f,
std::pair< _firstT, _secondT > & p )
inlinestatic

Reads a pair<_firstT,_secondT> from a FILE.

Returns 1 on success, 0 on failure.

Here is the call graph for this function:

◆ Read() [15/26]

template<typename _valueT , typename _Compare , typename _Alloc >
static size_t Dwm::FileIO::Read ( FILE * f,
std::set< _valueT, _Compare, _Alloc > & l )
inlinestatic

Reads a set<_valueT> from a FILE.

Returns 1 on success, 0 on failure.

◆ Read() [16/26]

static size_t Dwm::FileIO::Read ( FILE * f,
std::string & s )
static

Reads s from f.

Since we write strings with a 64-bit length value preceding, and always write the terminating NULL, this function will always return a value of 9 or greater on success.

◆ Read() [17/26]

template<typename _keyT , typename _valueT , typename _Hash , typename _Pred , typename _Alloc >
static size_t Dwm::FileIO::Read ( FILE * f,
std::unordered_map< _keyT, _valueT, _Hash, _Pred, _Alloc > & hm )
inlinestatic

Reads an unordered_map from a FILE.

Returns 1 on success, 0 on failure.

◆ Read() [18/26]

template<typename _keyT , typename _valueT , typename _Hash , typename _Pred , typename _Alloc >
static size_t Dwm::FileIO::Read ( FILE * f,
std::unordered_multimap< _keyT, _valueT, _Hash, _Pred, _Alloc > & hm )
inlinestatic

Reads an unordered_multimap from a FILE.

Returns 1 on success, 0 on failure.

◆ Read() [19/26]

template<typename _valueT , typename _Hash , typename _Pred , typename _Alloc >
static size_t Dwm::FileIO::Read ( FILE * f,
std::unordered_multiset< _valueT, _Hash, _Pred, _Alloc > & hm )
inlinestatic

Reads an unordered_multiset from a FILE.

Returns 1 on success, 0 on failure.

◆ Read() [20/26]

template<typename _valueT , typename _Hash , typename _Pred , typename _Alloc >
static size_t Dwm::FileIO::Read ( FILE * f,
std::unordered_set< _valueT, _Hash, _Pred, _Alloc > & hm )
inlinestatic

Reads an unordered_set from a FILE.

Returns 1 on success, 0 on failure.

◆ Read() [21/26]

template<typename _valueT , typename _Alloc >
static size_t Dwm::FileIO::Read ( FILE * f,
std::vector< _valueT, _Alloc > & v )
inlinestatic

Reads a vector<_valueT> from a FILE.

Returns 1 on success, 0 on failure.

◆ Read() [22/26]

static size_t Dwm::FileIO::Read ( FILE * f,
uint16_t & val )
static

Reads val from f, in network byte order (MSB first).

Returns the number of bytes read (2 on success).

◆ Read() [23/26]

static size_t Dwm::FileIO::Read ( FILE * f,
uint32_t & val )
static

Reads val from f, in network byte order (MSB first).

Returns the number of bytes read (4 on success).

◆ Read() [24/26]

static size_t Dwm::FileIO::Read ( FILE * f,
uint64_t & val )
static

Reads val from f, in network byte order (MSB first).

Returns the number of bytes read (8 on success).

◆ Read() [25/26]

static size_t Dwm::FileIO::Read ( FILE * f,
uint8_t & c )
static

Reads c from f.

Returns the number of bytes read (1 on success).

◆ Read() [26/26]

static size_t Dwm::FileIO::Read ( FILE * fp,
std::monostate & sm )
inlinestatic

Just a dummy helper function for std::variant instances that hold a std::monostate.

This should only be called from our Read() for std::variant (via std::visit()), and does nothing. Returns 1.

◆ ReadV()

template<typename... Args>
static size_t Dwm::FileIO::ReadV ( FILE * f,
Args &... args )
inlinestatic

Reads multiple objects from a FILE.

Returns 1 on success, 0 on failure.

Here is the call graph for this function:

◆ Write() [1/26]

static size_t Dwm::FileIO::Write ( FILE * f,
bool b )
static

Writes b to f.

Returns the number of bytes written (1) on success.

◆ Write() [2/26]

static size_t Dwm::FileIO::Write ( FILE * f,
char c )
static

Writes c to f.

Returns the number of bytes written (1) on success.

◆ Write() [3/26]

static size_t Dwm::FileIO::Write ( FILE * f,
const double & val )
static

Writes val to f, in IEEE format (see RFC 1832 and/or ANSI/IEEE Standard 754-1985).

Returns the number of bytes written (8 on success).

◆ Write() [4/26]

static size_t Dwm::FileIO::Write ( FILE * f,
const int64_t & val )
static

Writes val to f, in network byte order (MSB first).

Returns the number of bytes written (8) on success.

◆ Write() [5/26]

template<typename _valueT , size_t N>
static size_t Dwm::FileIO::Write ( FILE * f,
const std::array< _valueT, N > & a )
inlinestatic

Writes an array<_valueT,N> to a FILE.

Returns 1 on success, 0 on failure.

Here is the call graph for this function:

◆ Write() [6/26]

template<typename _valueT , typename _Alloc >
static size_t Dwm::FileIO::Write ( FILE * f,
const std::deque< _valueT, _Alloc > & d )
inlinestatic

Writes a deque<_valueT> to a FILE.

Returns 1 on success, 0 on failure.

◆ Write() [7/26]

template<typename _valueT , typename _Alloc >
static size_t Dwm::FileIO::Write ( FILE * f,
const std::list< _valueT, _Alloc > & l )
inlinestatic

Writes a list<_valueT> to a FILE.

Returns 1 on success, 0 on failure.

◆ Write() [8/26]

template<typename _keyT , typename _valueT , typename _Compare , typename _Alloc >
static size_t Dwm::FileIO::Write ( FILE * f,
const std::map< _keyT, _valueT, _Compare, _Alloc > & m )
inlinestatic

Writes a map<_keyT,_valueT> to a FILE.

Returns 1 on success, 0 on failure.

◆ Write() [9/26]

template<typename _keyT , typename _valueT , typename _Compare , typename _Alloc >
static size_t Dwm::FileIO::Write ( FILE * f,
const std::multimap< _keyT, _valueT, _Compare, _Alloc > & m )
inlinestatic

Writes a multimap<_keyT,_valueT> to a FILE.

Returns 1 on success, 0 on failure.

◆ Write() [10/26]

template<typename _valueT , typename _Compare , typename _Alloc >
static size_t Dwm::FileIO::Write ( FILE * f,
const std::multiset< _valueT, _Compare, _Alloc > & l )
inlinestatic

Writes a multiset<_valueT> to a FILE.

Returns 1 on success, 0 on failure.

◆ Write() [11/26]

template<typename _firstT , typename _secondT >
static size_t Dwm::FileIO::Write ( FILE * f,
const std::pair< _firstT, _secondT > & p )
inlinestatic

Writes a pair<_firstT,_secondT> to a FILE.

Returns 1 on success, 0 on failure.

Here is the call graph for this function:

◆ Write() [12/26]

template<typename _valueT , typename _Compare , typename _Alloc >
static size_t Dwm::FileIO::Write ( FILE * f,
const std::set< _valueT, _Compare, _Alloc > & l )
inlinestatic

Writes a set<_valueT> to a FILE.

Returns 1 on success, 0 on failure.

◆ Write() [13/26]

static size_t Dwm::FileIO::Write ( FILE * f,
const std::string & s )
static

Writes s to f.

Returns the number of bytes written. Note that we first write a 64-bit length value, then the string itself (with terminating NULL). Hence a successful write will always return a value of 8 + s.length() + 1.

◆ Write() [14/26]

template<typename _keyT , typename _valueT , typename _Hash , typename _Pred , typename _Alloc >
static size_t Dwm::FileIO::Write ( FILE * f,
const std::unordered_map< _keyT, _valueT, _Hash, _Pred, _Alloc > & hm )
inlinestatic

Writes an unordered_map to a FILE.

Returns 1 on success, 0 on failure.

◆ Write() [15/26]

template<typename _keyT , typename _valueT , typename _Hash , typename _Pred , typename _Alloc >
static size_t Dwm::FileIO::Write ( FILE * f,
const std::unordered_multimap< _keyT, _valueT, _Hash, _Pred, _Alloc > & hm )
inlinestatic

Writes an unordered_multimap to a FILE.

Returns 1 on success, 0 on failure.

◆ Write() [16/26]

template<typename _valueT , typename _Hash , typename _Pred , typename _Alloc >
static size_t Dwm::FileIO::Write ( FILE * f,
const std::unordered_multiset< _valueT, _Hash, _Pred, _Alloc > & hm )
inlinestatic

Writes an unordered_multiset to a FILE.

Returns 1 on success, 0 on failure.

◆ Write() [17/26]

template<typename _valueT , typename _Hash , typename _Pred , typename _Alloc >
static size_t Dwm::FileIO::Write ( FILE * f,
const std::unordered_set< _valueT, _Hash, _Pred, _Alloc > & hm )
inlinestatic

Writes an unordered_set to a FILE.

Returns 1 on success, 0 on failure.

◆ Write() [18/26]

template<typename _valueT , typename _Alloc >
static size_t Dwm::FileIO::Write ( FILE * f,
const std::vector< _valueT, _Alloc > & v )
inlinestatic

Writes a vector<_valueT> to a FILE.

Returns 1 on success, 0 on failure.

◆ Write() [19/26]

static size_t Dwm::FileIO::Write ( FILE * f,
const uint64_t & val )
static

Writes val to f, in network byte order (MSB first).

Returns the number of bytes written (8) on success.

◆ Write() [20/26]

static size_t Dwm::FileIO::Write ( FILE * f,
float val )
static

Writes val to f, in IEEE format (see RFC 1832 and/or ANSI/IEEE Standard 754-1985).

Returns the number of bytes written (4 on success).

◆ Write() [21/26]

static size_t Dwm::FileIO::Write ( FILE * f,
int16_t val )
static

Writes val to f, in network byte order (MSB first).

Returns the number of bytes written (2) on success.

◆ Write() [22/26]

static size_t Dwm::FileIO::Write ( FILE * f,
int32_t val )
static

Writes val to f, in network byte order (MSB first).

Returns the number of bytes written (4) on success.

◆ Write() [23/26]

static size_t Dwm::FileIO::Write ( FILE * f,
uint16_t val )
static

Writes val to f, in network byte order (MSB first).

Returns the number of bytes written (2) on success.

◆ Write() [24/26]

static size_t Dwm::FileIO::Write ( FILE * f,
uint32_t val )
static

Writes val to f, in network byte order (MSB first).

Returns the number of bytes written (4) on success.

◆ Write() [25/26]

static size_t Dwm::FileIO::Write ( FILE * f,
uint8_t c )
static

Writes c to f.

Returns the number of bytes written (1) on success.

◆ Write() [26/26]

static size_t Dwm::FileIO::Write ( FILE * fp,
const std::monostate & sm )
inlinestatic

Just a dummy helper function for std::variant instances that hold a std::monostate.

This should only be called from our Write() for std::variant (via std::visit()), and does nothing. Returns 1.

◆ WriteV()

template<typename... Args>
static size_t Dwm::FileIO::WriteV ( FILE * f,
const Args &... args )
inlinestatic

Writes multiple objects to a FILE.

Returns 1 on success, 0 on failure.

Here is the call graph for this function:

The documentation for this class was generated from the following file: