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

Side by Side Diff: services/shell/public/cpp/connection.h

Issue 2138263002: Revert of Move content's shell connections to the IO thread (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 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
« no previous file with comments | « services/navigation/view_impl.cc ('k') | services/shell/public/cpp/connector.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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 SERVICES_SHELL_PUBLIC_CPP_CONNECTION_H_ 5 #ifndef SERVICES_SHELL_PUBLIC_CPP_CONNECTION_H_
6 #define SERVICES_SHELL_PUBLIC_CPP_CONNECTION_H_ 6 #define SERVICES_SHELL_PUBLIC_CPP_CONNECTION_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <string> 10 #include <string>
(...skipping 19 matching lines...) Expand all
30 // 30 //
31 // Call AddService<T>(factory) to expose an interface to the remote application, 31 // Call AddService<T>(factory) to expose an interface to the remote application,
32 // and GetInterface(&interface_ptr) to consume an interface exposed by the 32 // and GetInterface(&interface_ptr) to consume an interface exposed by the
33 // remote application. 33 // remote application.
34 // 34 //
35 // Internally, this class wraps an InterfaceRegistry that accepts interfaces 35 // Internally, this class wraps an InterfaceRegistry that accepts interfaces
36 // that may be exposed to a remote application. See documentation in 36 // that may be exposed to a remote application. See documentation in
37 // interface_registry.h for more information. 37 // interface_registry.h for more information.
38 // 38 //
39 // A Connection returned via Shell::ConnectToApplication() is owned by the 39 // A Connection returned via Shell::ConnectToApplication() is owned by the
40 // caller. A Connection received via OnConnect is owned by the ServiceContext. 40 // caller.
41 // An Connection received via OnConnect is owned by the ServiceContext.
41 // To close a connection, call CloseConnection which will destroy this object. 42 // To close a connection, call CloseConnection which will destroy this object.
42 class Connection { 43 class Connection {
43 public: 44 public:
44 virtual ~Connection() {} 45 virtual ~Connection() {}
45 46
46 enum class State { 47 enum class State {
47 // The shell has not yet processed the connection. 48 // The shell has not yet processed the connection.
48 PENDING, 49 PENDING,
49 50
50 // The shell processed the connection and it was established. GetResult() 51 // The shell processed the connection and it was established. GetResult()
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 // Returns an object encapsulating a remote InterfaceProvider. 151 // Returns an object encapsulating a remote InterfaceProvider.
151 virtual InterfaceProvider* GetRemoteInterfaces() = 0; 152 virtual InterfaceProvider* GetRemoteInterfaces() = 0;
152 153
153 protected: 154 protected:
154 virtual base::WeakPtr<Connection> GetWeakPtr() = 0; 155 virtual base::WeakPtr<Connection> GetWeakPtr() = 0;
155 }; 156 };
156 157
157 } // namespace shell 158 } // namespace shell
158 159
159 #endif // SERVICES_SHELL_PUBLIC_CPP_CONNECTION_H_ 160 #endif // SERVICES_SHELL_PUBLIC_CPP_CONNECTION_H_
OLDNEW
« no previous file with comments | « services/navigation/view_impl.cc ('k') | services/shell/public/cpp/connector.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698