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

Unified Diff: net/quic/quic_chromium_alarm_factory.h

Issue 1908103002: Landing Recent QUIC changes until 4/15/2016 17:20 UTC (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix Created 4 years, 8 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 | « net/quic/quic_alarm_factory.h ('k') | net/quic/quic_chromium_alarm_factory.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/quic_chromium_alarm_factory.h
diff --git a/net/quic/quic_chromium_alarm_factory.h b/net/quic/quic_chromium_alarm_factory.h
new file mode 100644
index 0000000000000000000000000000000000000000..16345b7251b887c777e93e066a5fcd985f321135
--- /dev/null
+++ b/net/quic/quic_chromium_alarm_factory.h
@@ -0,0 +1,48 @@
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+// The Chrome-specific helper for QuicConnection which uses
+// a TaskRunner for alarms, and uses a DatagramClientSocket for writing data.
+
+#ifndef NET_QUIC_QUIC_CHROMIUM_ALARM_FACTORY_H_
+#define NET_QUIC_QUIC_CHROMIUM_ALARM_FACTORY_H_
+
+#include <set>
+
+#include "base/macros.h"
+#include "base/memory/weak_ptr.h"
+#include "net/quic/quic_alarm_factory.h"
+#include "net/quic/quic_clock.h"
+#include "net/quic/quic_protocol.h"
+#include "net/quic/quic_time.h"
+
+namespace base {
+class TaskRunner;
+} // namespace base
+
+namespace net {
+
+class NET_EXPORT_PRIVATE QuicChromiumAlarmFactory : public QuicAlarmFactory {
+ public:
+ QuicChromiumAlarmFactory(base::TaskRunner* task_runner,
+ const QuicClock* clock);
+ ~QuicChromiumAlarmFactory() override;
+
+ // QuicAlarmFactory
+ QuicAlarm* CreateAlarm(QuicAlarm::Delegate* delegate) override;
+ QuicArenaScopedPtr<QuicAlarm> CreateAlarm(
+ QuicArenaScopedPtr<QuicAlarm::Delegate> delegate,
+ QuicConnectionArena* arena) override;
+
+ private:
+ base::TaskRunner* task_runner_;
+ const QuicClock* clock_;
+ base::WeakPtrFactory<QuicChromiumAlarmFactory> weak_factory_;
+
+ DISALLOW_COPY_AND_ASSIGN(QuicChromiumAlarmFactory);
+};
+
+} // namespace net
+
+#endif // NET_QUIC_QUIC_CHROMIUM_ALARM_FACTORY_H_
« no previous file with comments | « net/quic/quic_alarm_factory.h ('k') | net/quic/quic_chromium_alarm_factory.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698