OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #ifndef REMOTING_PROTOCOL_BUFFERED_SOCKET_WRITER_H_ | 5 #ifndef REMOTING_PROTOCOL_BUFFERED_SOCKET_WRITER_H_ |
6 #define REMOTING_PROTOCOL_BUFFERED_SOCKET_WRITER_H_ | 6 #define REMOTING_PROTOCOL_BUFFERED_SOCKET_WRITER_H_ |
7 | 7 |
8 #include <list> | 8 #include <list> |
9 | 9 |
10 #include "base/callback.h" | 10 #include "base/callback.h" |
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
100 | 100 |
101 bool* destroyed_flag_; | 101 bool* destroyed_flag_; |
102 }; | 102 }; |
103 | 103 |
104 class BufferedSocketWriter : public BufferedSocketWriterBase { | 104 class BufferedSocketWriter : public BufferedSocketWriterBase { |
105 public: | 105 public: |
106 BufferedSocketWriter(); | 106 BufferedSocketWriter(); |
107 virtual ~BufferedSocketWriter(); | 107 virtual ~BufferedSocketWriter(); |
108 | 108 |
109 protected: | 109 protected: |
110 virtual void GetNextPacket(net::IOBuffer** buffer, int* size) OVERRIDE; | 110 virtual void GetNextPacket(net::IOBuffer** buffer, int* size) override; |
111 virtual base::Closure AdvanceBufferPosition(int written) OVERRIDE; | 111 virtual base::Closure AdvanceBufferPosition(int written) override; |
112 virtual void OnError(int result) OVERRIDE; | 112 virtual void OnError(int result) override; |
113 | 113 |
114 private: | 114 private: |
115 scoped_refptr<net::DrainableIOBuffer> current_buf_; | 115 scoped_refptr<net::DrainableIOBuffer> current_buf_; |
116 }; | 116 }; |
117 | 117 |
118 class BufferedDatagramWriter : public BufferedSocketWriterBase { | 118 class BufferedDatagramWriter : public BufferedSocketWriterBase { |
119 public: | 119 public: |
120 BufferedDatagramWriter(); | 120 BufferedDatagramWriter(); |
121 virtual ~BufferedDatagramWriter(); | 121 virtual ~BufferedDatagramWriter(); |
122 | 122 |
123 protected: | 123 protected: |
124 virtual void GetNextPacket(net::IOBuffer** buffer, int* size) OVERRIDE; | 124 virtual void GetNextPacket(net::IOBuffer** buffer, int* size) override; |
125 virtual base::Closure AdvanceBufferPosition(int written) OVERRIDE; | 125 virtual base::Closure AdvanceBufferPosition(int written) override; |
126 virtual void OnError(int result) OVERRIDE; | 126 virtual void OnError(int result) override; |
127 }; | 127 }; |
128 | 128 |
129 } // namespace protocol | 129 } // namespace protocol |
130 } // namespace remoting | 130 } // namespace remoting |
131 | 131 |
132 #endif // REMOTING_PROTOCOL_BUFFERED_SOCKET_WRITER_H_ | 132 #endif // REMOTING_PROTOCOL_BUFFERED_SOCKET_WRITER_H_ |
OLD | NEW |