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

Unified Diff: content/public/browser/cdm_service.h

Issue 1637083002: Add CdmService to keep track of CDMs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: changes Created 4 years, 9 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: content/public/browser/cdm_service.h
diff --git a/content/public/browser/cdm_service.h b/content/public/browser/cdm_service.h
new file mode 100644
index 0000000000000000000000000000000000000000..54e034fd174f745403ee3d648df3188e1a8b59c0
--- /dev/null
+++ b/content/public/browser/cdm_service.h
@@ -0,0 +1,36 @@
+// Copyright 2016 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 CONTENT_PUBLIC_BROWSER_CDM_SERVICE_H_
+#define CONTENT_PUBLIC_BROWSER_CDM_SERVICE_H_
+
+#include <vector>
+
+#include "content/common/content_export.h"
+#include "content/public/common/cdm_info.h"
+
+namespace content {
+
+class CONTENT_EXPORT CdmService {
+ public:
+ // Returns the CdmService singleton.
+ static CdmService* GetInstance();
+
+ virtual ~CdmService() {}
+
+ // Must be called on the instance to finish initialization.
+ virtual void Init() = 0;
+
+ // Registers a CDM with the specified CDM information. The CDM will be
+ // insertted at the head of the list so that it can override any older
xhwang 2016/04/13 00:22:13 inserted
jrummell 2016/04/14 01:32:16 Done.
+ // registrations.
xhwang 2016/04/13 00:22:13 Please add a note to potential issues described in
jrummell 2016/04/14 01:32:16 Done (although I think this is more an issue for t
+ virtual void RegisterCdm(const CdmInfo& info) = 0;
+
+ // Returns the list of all registered CDMs and the associated data.
+ virtual const std::vector<CdmInfo>& GetAllRegisteredCdms() = 0;
+};
+
+} // namespace content
+
+#endif // CONTENT_PUBLIC_BROWSER_CDM_SERVICE_H_

Powered by Google App Engine
This is Rietveld 408576698