| OLD | NEW |
| 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 #include "remoting/protocol/fake_session.h" | 5 #include "remoting/protocol/fake_session.h" |
| 6 | 6 |
| 7 namespace remoting { | 7 namespace remoting { |
| 8 namespace protocol { | 8 namespace protocol { |
| 9 | 9 |
| 10 const char kTestJid[] = "host1@gmail.com/chromoting123"; | 10 const char kTestJid[] = "host1@gmail.com/chromoting123"; |
| (...skipping 18 matching lines...) Expand all Loading... |
| 29 | 29 |
| 30 const std::string& FakeSession::jid() { | 30 const std::string& FakeSession::jid() { |
| 31 return jid_; | 31 return jid_; |
| 32 } | 32 } |
| 33 | 33 |
| 34 const CandidateSessionConfig* FakeSession::candidate_config() { | 34 const CandidateSessionConfig* FakeSession::candidate_config() { |
| 35 return candidate_config_.get(); | 35 return candidate_config_.get(); |
| 36 } | 36 } |
| 37 | 37 |
| 38 const SessionConfig& FakeSession::config() { | 38 const SessionConfig& FakeSession::config() { |
| 39 return config_; | 39 return *config_; |
| 40 } | 40 } |
| 41 | 41 |
| 42 void FakeSession::set_config(const SessionConfig& config) { | 42 void FakeSession::set_config(scoped_ptr<SessionConfig> config) { |
| 43 config_ = config; | 43 config_ = config.Pass(); |
| 44 } | 44 } |
| 45 | 45 |
| 46 StreamChannelFactory* FakeSession::GetTransportChannelFactory() { | 46 StreamChannelFactory* FakeSession::GetTransportChannelFactory() { |
| 47 return &channel_factory_; | 47 return &channel_factory_; |
| 48 } | 48 } |
| 49 | 49 |
| 50 StreamChannelFactory* FakeSession::GetMultiplexedChannelFactory() { | 50 StreamChannelFactory* FakeSession::GetMultiplexedChannelFactory() { |
| 51 return &channel_factory_; | 51 return &channel_factory_; |
| 52 } | 52 } |
| 53 | 53 |
| 54 void FakeSession::Close() { | 54 void FakeSession::Close() { |
| 55 closed_ = true; | 55 closed_ = true; |
| 56 } | 56 } |
| 57 | 57 |
| 58 } // namespace protocol | 58 } // namespace protocol |
| 59 } // namespace remoting | 59 } // namespace remoting |
| OLD | NEW |