Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(76)

Unified Diff: trunk/src/net/spdy/spdy_stream.h

Issue 13996009: Revert 194560 "[SPDY] Replace SpdyIOBuffer with new SpdyBuffer c..." (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « trunk/src/net/spdy/spdy_session_spdy3_unittest.cc ('k') | trunk/src/net/spdy/spdy_stream.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: trunk/src/net/spdy/spdy_stream.h
===================================================================
--- trunk/src/net/spdy/spdy_stream.h (revision 194561)
+++ trunk/src/net/spdy/spdy_stream.h (working copy)
@@ -12,7 +12,6 @@
#include "base/basictypes.h"
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
-#include "base/memory/scoped_vector.h"
#include "base/memory/weak_ptr.h"
#include "googleurl/src/gurl.h"
#include "net/base/bandwidth_metrics.h"
@@ -84,10 +83,9 @@
// Called when a HEADERS frame is sent.
virtual void OnHeadersSent() = 0;
- // Called when data is received. |buffer| may be NULL, which
- // signals EOF. Must return OK if the data was received
- // successfully, or a network error code otherwise.
- virtual int OnDataReceived(scoped_ptr<SpdyBuffer> buffer) = 0;
+ // Called when data is received.
+ // Returns network error code. OK when it successfully receives data.
+ virtual int OnDataReceived(const char* data, int length) = 0;
// Called when data is sent.
virtual void OnDataSent(size_t bytes_sent) = 0;
@@ -220,7 +218,7 @@
//
// |length| is the number of bytes received (at most 2^24 - 1) or 0 if
// the stream is being closed.
- void OnDataReceived(scoped_ptr<SpdyBuffer> buffer);
+ void OnDataReceived(const char* buffer, size_t length);
// Called by the SpdySession when a frame has been successfully and
// completely written. |frame_size| is the total size of the frame
@@ -291,8 +289,8 @@
int GetProtocolVersion() const;
private:
- class SynStreamBufferProducer;
- class HeaderBufferProducer;
+ class SynStreamFrameProducer;
+ class HeaderFrameProducer;
enum State {
STATE_NONE,
@@ -413,7 +411,7 @@
int recv_bytes_;
// Data received before delegate is attached.
- ScopedVector<SpdyBuffer> pending_buffers_;
+ std::vector<scoped_refptr<IOBufferWithSize> > pending_buffers_;
SSLClientCertType domain_bound_cert_type_;
std::string domain_bound_private_key_;
« no previous file with comments | « trunk/src/net/spdy/spdy_session_spdy3_unittest.cc ('k') | trunk/src/net/spdy/spdy_stream.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698