5 namespace tdc {
namespace io {
11 std::vector<uint8_t> m_escape_bytes;
12 bool m_null_terminate;
14 inline void sort_and_dedup() {
15 std::sort(m_escape_bytes.begin(), m_escape_bytes.end());
16 m_escape_bytes.erase(std::unique(m_escape_bytes.begin(), m_escape_bytes.end()), m_escape_bytes.end());
26 m_null_terminate(null_terminate) {
31 return m_escape_bytes;
35 return m_null_terminate;
39 return m_escape_bytes.empty();
58 <<
", null_termination: " << (v.
null_terminate() ?
"true" :
"false")
67 std::vector<uint8_t> merged;
bool operator==(const InputRestrictions &lhs, const InputRestrictions &rhs)
Contains the text compression and encoding framework.
std::string vec_to_debug_string(const T &s, size_t indent=0)
Builds the string representation of a vector of byte values, sorrounded by square brackets ([ and ])...
InputRestrictions & operator|=(InputRestrictions &a, const InputRestrictions &b)
Merges two InpuTrestrictions to a combined set of restrictions.
std::ostream & operator<<(std::ostream &o, const InputRestrictions &v)
bool operator!=(const InputRestrictions &lhs, const InputRestrictions &rhs)