OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
| 5 #include "remoting/base/compound_buffer.h" |
| 6 |
| 7 #include <algorithm> |
5 #include <functional> | 8 #include <functional> |
6 | 9 |
7 #include "base/logging.h" | 10 #include "base/logging.h" |
8 #include "net/base/io_buffer.h" | 11 #include "net/base/io_buffer.h" |
9 #include "remoting/base/compound_buffer.h" | |
10 | 12 |
11 namespace remoting { | 13 namespace remoting { |
12 | 14 |
13 CompoundBuffer::DataChunk::DataChunk( | 15 CompoundBuffer::DataChunk::DataChunk( |
14 net::IOBuffer* buffer_value, const char* start_value, int size_value) | 16 net::IOBuffer* buffer_value, const char* start_value, int size_value) |
15 : buffer(buffer_value), | 17 : buffer(buffer_value), |
16 start(start_value), | 18 start(start_value), |
17 size(size_value) { | 19 size(size_value) { |
18 } | 20 } |
19 | 21 |
(...skipping 248 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
268 } | 270 } |
269 | 271 |
270 return count == 0; | 272 return count == 0; |
271 } | 273 } |
272 | 274 |
273 int64 CompoundBufferInputStream::ByteCount() const { | 275 int64 CompoundBufferInputStream::ByteCount() const { |
274 return position_; | 276 return position_; |
275 } | 277 } |
276 | 278 |
277 } // namespace remoting | 279 } // namespace remoting |
OLD | NEW |