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

Side by Side Diff: net/spdy/spdy_websocket_stream.h

Issue 10417002: RefCounted types should not have public destructors, net/ edition (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased to r139261 Created 8 years, 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « net/spdy/buffered_spdy_framer.h ('k') | net/url_request/url_request.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 NET_SPDY_SPDY_WEBSOCKET_STREAM_H_ 5 #ifndef NET_SPDY_SPDY_WEBSOCKET_STREAM_H_
6 #define NET_SPDY_SPDY_WEBSOCKET_STREAM_H_ 6 #define NET_SPDY_SPDY_WEBSOCKET_STREAM_H_
7 #pragma once 7 #pragma once
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/gtest_prod_util.h" 10 #include "base/gtest_prod_util.h"
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 int status) = 0; 44 int status) = 0;
45 45
46 // Called when data is sent. 46 // Called when data is sent.
47 virtual void OnSentSpdyData(int amount_sent) = 0; 47 virtual void OnSentSpdyData(int amount_sent) = 0;
48 48
49 // Called when data is received. 49 // Called when data is received.
50 virtual void OnReceivedSpdyData(const char* data, int length) = 0; 50 virtual void OnReceivedSpdyData(const char* data, int length) = 0;
51 51
52 // Called when SpdyStream is closed. 52 // Called when SpdyStream is closed.
53 virtual void OnCloseSpdyStream() = 0; 53 virtual void OnCloseSpdyStream() = 0;
54
55 protected:
56 virtual ~Delegate() {}
54 }; 57 };
55 58
56 SpdyWebSocketStream(SpdySession* spdy_session, Delegate* delegate); 59 SpdyWebSocketStream(SpdySession* spdy_session, Delegate* delegate);
57 virtual ~SpdyWebSocketStream(); 60 virtual ~SpdyWebSocketStream();
58 61
59 // Initializes SPDY stream for the WebSocket. 62 // Initializes SPDY stream for the WebSocket.
60 // It might create SPDY stream asynchronously. In this case, this method 63 // It might create SPDY stream asynchronously. In this case, this method
61 // returns ERR_IO_PENDING and call OnCreatedSpdyStream delegate with result 64 // returns ERR_IO_PENDING and call OnCreatedSpdyStream delegate with result
62 // after completion. In other cases, delegate does not be called. 65 // after completion. In other cases, delegate does not be called.
63 int InitializeStream(const GURL& url, 66 int InitializeStream(const GURL& url,
(...skipping 25 matching lines...) Expand all
89 scoped_refptr<SpdyStream> stream_; 92 scoped_refptr<SpdyStream> stream_;
90 scoped_refptr<SpdySession> spdy_session_; 93 scoped_refptr<SpdySession> spdy_session_;
91 Delegate* delegate_; 94 Delegate* delegate_;
92 95
93 DISALLOW_COPY_AND_ASSIGN(SpdyWebSocketStream); 96 DISALLOW_COPY_AND_ASSIGN(SpdyWebSocketStream);
94 }; 97 };
95 98
96 } // namespace net 99 } // namespace net
97 100
98 #endif // NET_SPDY_SPDY_WEBSOCKET_STREAM_H_ 101 #endif // NET_SPDY_SPDY_WEBSOCKET_STREAM_H_
OLDNEW
« no previous file with comments | « net/spdy/buffered_spdy_framer.h ('k') | net/url_request/url_request.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698