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/fake_session.cc

Issue 1420273002: Add TransportSession interface to prepare for WebRTC-based transport. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 2 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 | « remoting/protocol/fake_session.h ('k') | remoting/protocol/ice_transport_factory.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/protocol/fake_session.cc
diff --git a/remoting/protocol/fake_session.cc b/remoting/protocol/fake_session.cc
index e21f932a4118da74b114ceb86cd60cb3b65c8d50..9e7d8fcc5da2e94d60b5c8f8042d48f7fe6da68f 100644
--- a/remoting/protocol/fake_session.cc
+++ b/remoting/protocol/fake_session.cc
@@ -9,6 +9,33 @@ namespace protocol {
const char kTestJid[] = "host1@gmail.com/chromoting123";
+FakeTransportSession::FakeTransportSession() {}
+FakeTransportSession::~FakeTransportSession() {}
+
+void FakeTransportSession::Start(EventHandler* event_handler,
+ Authenticator* authenticator) {
+ NOTREACHED();
+}
+
+bool FakeTransportSession::ProcessTransportInfo(
+ buzz::XmlElement* transport_info) {
+ NOTREACHED();
+ return true;
+}
+
+DatagramChannelFactory* FakeTransportSession::GetDatagramChannelFactory() {
+ NOTIMPLEMENTED();
+ return nullptr;
+}
+
+FakeStreamChannelFactory* FakeTransportSession::GetStreamChannelFactory() {
+ return &channel_factory_;
+}
+
+FakeStreamChannelFactory* FakeTransportSession::GetMultiplexedChannelFactory() {
+ return &channel_factory_;
+}
+
FakeSession::FakeSession()
: event_handler_(nullptr),
config_(SessionConfig::ForTest()),
@@ -34,16 +61,12 @@ const SessionConfig& FakeSession::config() {
return *config_;
}
-StreamChannelFactory* FakeSession::GetTransportChannelFactory() {
- return &channel_factory_;
+FakeTransportSession* FakeSession::GetTransportSession() {
+ return &transport_session_;
}
-StreamChannelFactory* FakeSession::GetMultiplexedChannelFactory() {
- return &channel_factory_;
-}
-
-StreamChannelFactory* FakeSession::GetQuicChannelFactory() {
- return &channel_factory_;
+FakeStreamChannelFactory* FakeSession::GetQuicChannelFactory() {
+ return transport_session_.GetStreamChannelFactory();
}
void FakeSession::Close() {
« no previous file with comments | « remoting/protocol/fake_session.h ('k') | remoting/protocol/ice_transport_factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698