Index: net/tools/flip_server/balsa_headers.cc |
diff --git a/net/tools/flip_server/balsa_headers.cc b/net/tools/flip_server/balsa_headers.cc |
index 0fe68c2abb27c4525d7c9d0e0949835b00698684..0cba73bbead67a46a4935ef96544bb4037f78fbe 100644 |
--- a/net/tools/flip_server/balsa_headers.cc |
+++ b/net/tools/flip_server/balsa_headers.cc |
@@ -70,10 +70,23 @@ namespace net { |
const size_t BalsaBuffer::kDefaultBlocksize; |
+BalsaHeaders::iterator_base::iterator_base() : headers_(NULL), idx_(0) { } |
+ |
+BalsaHeaders::iterator_base::iterator_base(const iterator_base& it) |
+ : headers_(it.headers_), |
+ idx_(it.idx_) { |
+} |
+ |
std::ostream& BalsaHeaders::iterator_base::operator<<(std::ostream& os) const { |
- os << "[" << this->headers_ << ", " << this->idx_ << "]"; |
- return os; |
- } |
+ os << "[" << this->headers_ << ", " << this->idx_ << "]"; |
+ return os; |
+} |
+ |
+BalsaHeaders::iterator_base::iterator_base(const BalsaHeaders* headers, |
+ HeaderLines::size_type index) |
+ : headers_(headers), |
+ idx_(index) { |
+} |
BalsaBuffer::~BalsaBuffer() { |
CleanupBlocksStartingFrom(0); |
@@ -225,6 +238,26 @@ void BalsaBuffer::CleanupBlocksStartingFrom(Blocks::size_type start_idx) { |
blocks_.resize(start_idx); |
} |
+BalsaHeaders::const_header_lines_key_iterator::const_header_lines_key_iterator( |
+ const const_header_lines_key_iterator& other) |
+ : iterator_base(other), |
+ key_(other.key_) { |
+} |
+ |
+BalsaHeaders::const_header_lines_key_iterator::const_header_lines_key_iterator( |
+ const BalsaHeaders* headers, |
+ HeaderLines::size_type index, |
+ const base::StringPiece& key) |
+ : iterator_base(headers, index), |
+ key_(key) { |
+} |
+ |
+BalsaHeaders::const_header_lines_key_iterator::const_header_lines_key_iterator( |
+ const BalsaHeaders* headers, |
+ HeaderLines::size_type index) |
+ : iterator_base(headers, index) { |
+} |
+ |
BalsaHeaders::BalsaHeaders() |
: balsa_buffer_(4096), |
content_length_(0), |