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

Side by Side Diff: webkit/glue/websocketstreamhandle_impl.h

Issue 9677031: Bind RenderViewImpl routing_id to SocketStreamHost (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 8 years, 9 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
OLDNEW
1 // Copyright (c) 2011 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 WEBKIT_GLUE_WEBSOCKETSTREAMHANDLE_IMPL_H_ 5 #ifndef WEBKIT_GLUE_WEBSOCKETSTREAMHANDLE_IMPL_H_
6 #define WEBKIT_GLUE_WEBSOCKETSTREAMHANDLE_IMPL_H_ 6 #define WEBKIT_GLUE_WEBSOCKETSTREAMHANDLE_IMPL_H_
7 7
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/memory/scoped_ptr.h"
9 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebSocketStr eamHandle.h" 10 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebSocketStr eamHandle.h"
10 11
11 namespace webkit_glue { 12 namespace webkit_glue {
12 13
13 class WebKitPlatformSupportImpl; 14 class WebKitPlatformSupportImpl;
14 15
15 class WebSocketStreamHandleImpl : public WebKit::WebSocketStreamHandle { 16 class WebSocketStreamHandleImpl : public WebKit::WebSocketStreamHandle {
16 public: 17 public:
18 class ExtraData {
19 public:
20 virtual ~ExtraData() {}
21 };
17 explicit WebSocketStreamHandleImpl(WebKitPlatformSupportImpl* platform); 22 explicit WebSocketStreamHandleImpl(WebKitPlatformSupportImpl* platform);
18 virtual ~WebSocketStreamHandleImpl(); 23 virtual ~WebSocketStreamHandleImpl();
19 24
20 // WebSocketStreamHandle methods: 25 // WebSocketStreamHandle methods:
21 virtual void connect( 26 virtual void connect(
22 const WebKit::WebURL& url, 27 const WebKit::WebURL& url,
23 WebKit::WebSocketStreamHandleClient* client); 28 WebKit::WebSocketStreamHandleClient* client) OVERRIDE;
24 virtual bool send(const WebKit::WebData& data); 29 virtual bool send(const WebKit::WebData& data) OVERRIDE;
25 virtual void close(); 30 virtual void close() OVERRIDE;
tony 2012/03/19 20:52:56 I would not mark these as OVERRIDE. It makes refa
Takashi Toyoshima 2012/03/19 22:58:44 Done.
31
32 // Handle extra data associated with the object.
33 const ExtraData* extraData() const { return extra_data_.get(); }
34 void setExtraData(ExtraData* extra_data) { extra_data_.reset(extra_data); }
26 35
27 private: 36 private:
28 class Context; 37 class Context;
29 scoped_refptr<Context> context_; 38 scoped_refptr<Context> context_;
30 WebKitPlatformSupportImpl* platform_; 39 WebKitPlatformSupportImpl* platform_;
40 scoped_ptr<ExtraData> extra_data_;
31 41
32 DISALLOW_COPY_AND_ASSIGN(WebSocketStreamHandleImpl); 42 DISALLOW_COPY_AND_ASSIGN(WebSocketStreamHandleImpl);
33 }; 43 };
34 44
35 } // namespace webkit_glue 45 } // namespace webkit_glue
36 46
37 #endif // WEBKIT_GLUE_WEBSOCKETSTREAMHANDLE_IMPL_H_ 47 #endif // WEBKIT_GLUE_WEBSOCKETSTREAMHANDLE_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698