Index: net/quic/chromium/quic_chromium_packet_writer.h |
diff --git a/net/quic/chromium/quic_chromium_packet_writer.h b/net/quic/chromium/quic_chromium_packet_writer.h |
index 72b25adb9004ae305a5c8a78a616a500f1fa2920..c6b2f72c1981b7110dcef87d39e377078efbb70f 100644 |
--- a/net/quic/chromium/quic_chromium_packet_writer.h |
+++ b/net/quic/chromium/quic_chromium_packet_writer.h |
@@ -32,8 +32,10 @@ class NET_EXPORT_PRIVATE QuicChromiumPacketWriter : public QuicPacketWriter { |
// |error_code| otherwise. |
virtual int HandleWriteError(int error_code, |
scoped_refptr<StringIOBuffer> last_packet) = 0; |
+ |
// Called to propagate the final write error to the delegate. |
virtual void OnWriteError(int error_code) = 0; |
+ |
// Called when the writer is unblocked due to a write completion. |
virtual void OnWriteUnblocked() = 0; |
}; |
@@ -46,8 +48,10 @@ class NET_EXPORT_PRIVATE QuicChromiumPacketWriter : public QuicPacketWriter { |
// |delegate| must outlive writer. |
void set_delegate(Delegate* delegate) { delegate_ = delegate; } |
+ void set_write_blocked(bool write_blocked) { write_blocked_ = write_blocked; } |
+ |
// Writes |packet| to the socket and returns the error code from the write. |
- int WritePacketToSocket(StringIOBuffer* packet); |
+ WriteResult WritePacketToSocket(scoped_refptr<StringIOBuffer> packet); |
// QuicPacketWriter |
WriteResult WritePacket(const char* buffer, |
@@ -62,9 +66,6 @@ class NET_EXPORT_PRIVATE QuicChromiumPacketWriter : public QuicPacketWriter { |
void OnWriteComplete(int rv); |
- protected: |
- void set_write_blocked(bool is_blocked) { write_blocked_ = is_blocked; } |
- |
private: |
Socket* socket_; // Unowned. |
Delegate* delegate_; // Unowned. |