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

Unified Diff: jingle/notifier/listener/fake_push_client.cc

Issue 11232048: Adding XMPP ping functionality to CLoudPrint. XMPP ping and timeout is controlled thorugh Service S… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: comments addressed Created 8 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 | « jingle/notifier/listener/fake_push_client.h ('k') | jingle/notifier/listener/non_blocking_push_client.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: jingle/notifier/listener/fake_push_client.cc
diff --git a/jingle/notifier/listener/fake_push_client.cc b/jingle/notifier/listener/fake_push_client.cc
index 0565c3c1ed51c038eded992b2cfb3f213c6b0d02..1106c932b7f3016abccc539c4b226f7072b62598 100644
--- a/jingle/notifier/listener/fake_push_client.cc
+++ b/jingle/notifier/listener/fake_push_client.cc
@@ -8,7 +8,7 @@
namespace notifier {
-FakePushClient::FakePushClient() {}
+FakePushClient::FakePushClient() : sent_pings_(0) {}
FakePushClient::~FakePushClient() {}
@@ -35,6 +35,10 @@ void FakePushClient::SendNotification(const Notification& notification) {
sent_notifications_.push_back(notification);
}
+void FakePushClient::SendPing() {
+ sent_pings_++;
+}
+
void FakePushClient::EnableNotifications() {
FOR_EACH_OBSERVER(PushClientObserver, observers_,
OnNotificationsEnabled());
@@ -68,5 +72,9 @@ const std::vector<Notification>& FakePushClient::sent_notifications() const {
return sent_notifications_;
}
+int FakePushClient::sent_pings() const {
+ return sent_pings_;
+}
+
} // namespace notifier
« no previous file with comments | « jingle/notifier/listener/fake_push_client.h ('k') | jingle/notifier/listener/non_blocking_push_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698