Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2016 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 CONTENT_PUBLIC_BROWSER_CDM_SERVICE_H_ | |
| 6 #define CONTENT_PUBLIC_BROWSER_CDM_SERVICE_H_ | |
| 7 | |
| 8 #include <vector> | |
| 9 | |
| 10 #include "content/common/content_export.h" | |
| 11 #include "content/public/common/cdm_info.h" | |
| 12 | |
| 13 namespace content { | |
| 14 | |
| 15 class CONTENT_EXPORT CdmService { | |
| 16 public: | |
| 17 // Returns the CdmService singleton. | |
| 18 static CdmService* GetInstance(); | |
| 19 | |
| 20 virtual ~CdmService() {} | |
| 21 | |
| 22 // Must be called on the instance to finish initialization. | |
| 23 virtual void Init() = 0; | |
| 24 | |
| 25 // Registers a CDM with the specified CDM information. The CDM will be | |
| 26 // inserted at the head of the list so that it can override any older | |
| 27 // registrations. | |
| 28 // Note: Since only 1 version of the CDM can be loaded at any given time, | |
| 29 // it is possible that there will be a mismatch between the functionality | |
| 30 // reported and what is actually available, if the reported functionality | |
| 31 // changes between versions. (http://crbug.com/599588) | |
| 32 virtual void RegisterCdm(const CdmInfo& info) = 0; | |
| 33 | |
| 34 // Returns the list of all registered CDMs and the associated data. | |
| 35 virtual const std::vector<CdmInfo>& GetAllRegisteredCdms() = 0; | |
|
Sorin Jianu
2016/04/15 01:53:26
forward declare CdmInfo?
Sorin Jianu
2016/04/15 01:53:26
const?
jrummell
2016/04/18 20:39:47
Done.
jrummell
2016/04/18 20:39:47
Done.
| |
| 36 }; | |
| 37 | |
| 38 } // namespace content | |
| 39 | |
| 40 #endif // CONTENT_PUBLIC_BROWSER_CDM_SERVICE_H_ | |
| OLD | NEW |