wex v24.10.0
Public Member Functions | List of all members
wex::stream_statistics Class Reference

Offers stream_statistics. More...

#include <wex/common/stream-statistics.h>

Public Member Functions

stream_statisticsoperator+= (const stream_statistics &s)
 Adds other statistics.
 
void clear ()
 Clears the statistics.
 
bool empty () const
 Returns true if statistics are empty.
 
const std::string get () const
 Returns all items as a string.
 
int get (const std::string &key) const
 Returns the key, if not present 0 is returned.
 
const auto & get_elements () const
 Returns the elements.
 
auto & get_elements ()
 Returns the elements.
 
int inc (const std::string &keyword, int inc_value=1)
 Increments keyword.
 
int inc_actions ()
 Increments actions.
 
int inc_actions_completed (int inc_value=1)
 Increments actions completed.
 

Detailed Description

Offers stream_statistics.

Used by stream to keep statistics.

Member Function Documentation

◆ get()

const std::string wex::stream_statistics::get ( ) const
inline

Returns all items as a string.

All items are returned as a string, with newlines separating items.