Meta data for a single cache entry.
More...
#include <cache_entry.hpp>
|
|
std::vector< std::string > | m_file_ids |
| |
|
comp_mode_t | m_compression_mode = comp_mode_t::NONE |
| |
|
std::string | m_std_out |
| |
|
std::string | m_std_err |
| |
|
int | m_return_code = 0 |
| |
|
bool | m_valid = false |
| |
Meta data for a single cache entry.
◆ comp_mode_t
Compression mode.
| Enumerator |
|---|
| NONE | Compress nothing (i.e. the entry is uncompressed in the cache).
|
| ALL | Compress all files and stdout + stderr.
|
◆ cache_entry_t()
| bcache::cache_entry_t::cache_entry_t |
( |
const std::vector< std::string > & |
file_ids, |
|
|
const comp_mode_t |
compression_mode, |
|
|
const std::string & |
std_out, |
|
|
const std::string & |
std_err, |
|
|
const int |
return_code |
|
) |
| |
Construct a valid cache entry.
- Parameters
-
| file_ids | ID:s of the cached files. |
| compression_mode | Compression mode. |
| std_out | stdout from the program run. |
| std_err | stderr from the program run. |
| return_code | Program return code (0 = success). |
◆ compression_mode()
| comp_mode_t bcache::cache_entry_t::compression_mode |
( |
| ) |
const |
|
inline |
- Returns
- the compression mode.
◆ deserialize()
| cache_entry_t bcache::cache_entry_t::deserialize |
( |
const std::string & |
data | ) |
|
|
static |
Deserialize a cache entry.
- Parameters
-
- Returns
- the deserialized cache entry.
◆ file_ids()
| const std::vector<std::string>& bcache::cache_entry_t::file_ids |
( |
| ) |
const |
|
inline |
- Returns
- the ID:s of the cached files.
◆ operator bool()
| bcache::cache_entry_t::operator bool |
( |
| ) |
const |
|
inline |
- Returns
- true if this object represents a valid cache entry. E.g. for a cache miss, the return value is false.
◆ return_code()
| int bcache::cache_entry_t::return_code |
( |
| ) |
const |
|
inline |
- Returns
- the program return code (0 = success).
◆ serialize()
| std::string bcache::cache_entry_t::serialize |
( |
| ) |
const |
Serialize a cache entry.
- Returns
- a serialized data as a string object.
◆ std_err()
| const std::string& bcache::cache_entry_t::std_err |
( |
| ) |
const |
|
inline |
- Returns
- the stderr from the program run.
◆ std_out()
| const std::string& bcache::cache_entry_t::std_out |
( |
| ) |
const |
|
inline |
- Returns
- the stdout from the program run.
The documentation for this class was generated from the following files: