16 using std::stringstream;
21 ostream& operator<<(ostream& os, const std::list<uint32_t>* refset) {
22 os << std::endl <<
'[';
23 for (
auto& ref : *refset) {
26 os <<
']' << std::endl;
30 std::ostream& operator<<(std::ostream& os, const std::vector<HPACKHeader>&
v) {
31 for (
const auto &
h :
v) {
32 os <<
h.name <<
": " <<
h.value << std::endl;
39 const vector<HPACKHeader> &v2) {
45 while (i < v1.size() && j < v2.size()) {
47 if (i > 0 && v1[i - 1] == v1[i]) {
48 out <<
" duplicate " << v1[
i] << std::endl;
50 out <<
" + " << v1[
i] << std::endl;
53 }
else if (v1[i] > v2[j]) {
54 out <<
" - " << v2[j] << std::endl;
61 while (i < v1.size()) {
62 out <<
" + " << v1[
i];
63 if (i > 0 && v1[i - 1] == v1[i]) {
64 out <<
" (duplicate)";
69 while (j < v2.size()) {
70 out <<
" - " << v2[j] << std::endl;
string printDelta(const vector< HPACKHeader > &v1, const vector< HPACKHeader > &v2)