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

Unified Diff: chromecast/service/cast_network_delegate.h

Issue 598303002: Chromecast: adds CastNetworkDelegate. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: uploads CastNetworkDelegate :) Created 6 years, 3 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
Index: chromecast/service/cast_network_delegate.h
diff --git a/chromecast/service/cast_network_delegate.h b/chromecast/service/cast_network_delegate.h
new file mode 100644
index 0000000000000000000000000000000000000000..09c4876d5a7dff375f393d7351de0ae5c5cc753f
--- /dev/null
+++ b/chromecast/service/cast_network_delegate.h
@@ -0,0 +1,38 @@
+// Copyright 2014 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.
+
+#ifndef CHROMECAST_SERVICE_CAST_NETWORK_DELEGATE_H_
+#define CHROMECAST_SERVICE_CAST_NETWORK_DELEGATE_H_
+
+#include "net/base/network_delegate.h"
+
+namespace net {
+class X509Certificate;
+}
+
+namespace chromecast {
+
+class CastNetworkDelegate : public net::NetworkDelegate {
+ public:
+ static CastNetworkDelegate* Create();
+ static net::X509Certificate* DeviceCert();
+
+ CastNetworkDelegate();
+ virtual ~CastNetworkDelegate();
+
+ virtual void Initialize(bool use_sync_signing) = 0;
+
+ virtual bool IsWhitelisted(const GURL& gurl, bool for_device_auth) const = 0;
+
+ private:
+ // net::NetworkDelegate implementation:
+ virtual bool OnCanAccessFile(const net::URLRequest& request,
+ const base::FilePath& path) const OVERRIDE;
+
+ DISALLOW_COPY_AND_ASSIGN(CastNetworkDelegate);
+};
+
+} // namespace chromecast
+
+#endif // CHROMECAST_SERVICE_CAST_NETWORK_DELEGATE_H_

Powered by Google App Engine
This is Rietveld 408576698