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

Unified Diff: remoting/protocol/connection_to_host.h

Issue 1520323007: Simplify ConnectionToHost interface. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@sm_cleanup
Patch Set: Created 5 years 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 | « remoting/client/client_user_interface.h ('k') | remoting/protocol/connection_to_host_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/protocol/connection_to_host.h
diff --git a/remoting/protocol/connection_to_host.h b/remoting/protocol/connection_to_host.h
index f5c8c8207f20aa95056abf06f336328d57071af3..b41df200f3dbe142d2ec174fa37dbcd54dc225c3 100644
--- a/remoting/protocol/connection_to_host.h
+++ b/remoting/protocol/connection_to_host.h
@@ -7,27 +7,20 @@
#include <string>
-#include "base/callback_forward.h"
-#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
#include "remoting/protocol/errors.h"
namespace remoting {
-
-class SignalStrategy;
-
namespace protocol {
class AudioStub;
class Authenticator;
-class CandidateSessionConfig;
class ClientStub;
class ClipboardStub;
-class ExtensionMessage;
class HostStub;
class InputStub;
+class Session;
class SessionConfig;
-class TransportContext;
struct TransportRoute;
class VideoStub;
@@ -69,11 +62,6 @@ class ConnectionToHost {
virtual ~ConnectionToHost() {}
- // Allows to set a custom protocol configuration (e.g. for tests). Cannot be
- // called after Connect().
- virtual void set_candidate_config(
- scoped_ptr<CandidateSessionConfig> config) = 0;
-
// Set the stubs which will handle messages from the host.
// The caller must ensure that stubs out-live the connection.
// Unless otherwise specified, all stubs must be set before Connect()
@@ -84,17 +72,10 @@ class ConnectionToHost {
// If no audio stub is specified then audio will not be requested.
virtual void set_audio_stub(AudioStub* audio_stub) = 0;
- // Initiates a connection to the host specified by |host_jid|.
- // |signal_strategy| is used to signal to the host, and must outlive the
- // connection. Data channels will be negotiated over |transport_factory|.
- // |authenticator| will be used to authenticate the session and data channels.
- // |event_callback| will be notified of changes in the state of the connection
- // and must outlive the ConnectionToHost.
- // Caller must set stubs (see below) before calling Connect.
- virtual void Connect(SignalStrategy* signal_strategy,
- scoped_refptr<TransportContext> transport_context,
- scoped_ptr<Authenticator> authenticator,
- const std::string& host_jid,
+ // Initiates a connection using |session|. |event_callback| will be notified
+ // of changes in the state of the connection and must outlive the
+ // ConnectionToHost. Caller must set stubs (see below) before calling Connect.
+ virtual void Connect(scoped_ptr<Session> session,
HostEventCallback* event_callback) = 0;
// Returns the session configuration that was negotiated with the host.
« no previous file with comments | « remoting/client/client_user_interface.h ('k') | remoting/protocol/connection_to_host_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698