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

Side by Side Diff: remoting/client/plugin/delegating_signal_strategy.h

Issue 2384063008: Enables delegating signal strategy for It2Me Host. (Closed)
Patch Set: Fix typos Created 4 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 unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef REMOTING_CLIENT_PLUGIN_DELEGATING_SIGNAL_STRATEGY_H_
6 #define REMOTING_CLIENT_PLUGIN_DELEGATING_SIGNAL_STRATEGY_H_
7
8 #include "base/callback.h"
9 #include "base/macros.h"
10 #include "base/observer_list.h"
11 #include "remoting/signaling/signal_strategy.h"
12
13 namespace base {
14 class SingleThreadTaskRunner;
15 } // namespace base
16
17 namespace remoting {
18
19 class DelegatingSignalStrategy : public SignalStrategy {
20 public:
21 typedef base::Callback<void(const std::string&)> SendIqCallback;
22
23 DelegatingSignalStrategy(std::string local_jid,
24 const SendIqCallback& send_iq_callback);
25 ~DelegatingSignalStrategy() override;
26
27 void OnIncomingMessage(const std::string& message);
28
29 // SignalStrategy interface.
30 void Connect() override;
31 void Disconnect() override;
32 State GetState() const override;
33 Error GetError() const override;
34 std::string GetLocalJid() const override;
35 void AddListener(Listener* listener) override;
36 void RemoveListener(Listener* listener) override;
37 bool SendStanza(std::unique_ptr<buzz::XmlElement> stanza) override;
38 std::string GetNextId() override;
39
40 private:
41 std::string local_jid_;
42 SendIqCallback send_iq_callback_;
43
44 base::ObserverList<Listener> listeners_;
45
46 DISALLOW_COPY_AND_ASSIGN(DelegatingSignalStrategy);
47 };
48
49 } // namespace remoting
50
51 #endif // REMOTING_CLIENT_PLUGIN_DELEGATING_SIGNAL_STRATEGY_H_
OLDNEW
« no previous file with comments | « remoting/client/plugin/chromoting_instance.cc ('k') | remoting/client/plugin/delegating_signal_strategy.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698