| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef MEDIA_MOJO_SERVICES_MOJO_CDM_SERVICE_H_ | 5 #ifndef MEDIA_MOJO_SERVICES_MOJO_CDM_SERVICE_H_ |
| 6 #define MEDIA_MOJO_SERVICES_MOJO_CDM_SERVICE_H_ | 6 #define MEDIA_MOJO_SERVICES_MOJO_CDM_SERVICE_H_ |
| 7 | 7 |
| 8 #include "base/callback.h" | 8 #include "base/callback.h" |
| 9 #include "base/macros.h" | 9 #include "base/macros.h" |
| 10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| (...skipping 18 matching lines...) Expand all Loading... |
| 29 CdmFactory* cdm_factory, | 29 CdmFactory* cdm_factory, |
| 30 mojo::InterfaceRequest<mojo::ContentDecryptionModule> request); | 30 mojo::InterfaceRequest<mojo::ContentDecryptionModule> request); |
| 31 | 31 |
| 32 ~MojoCdmService() final; | 32 ~MojoCdmService() final; |
| 33 | 33 |
| 34 // mojo::ContentDecryptionModule implementation. | 34 // mojo::ContentDecryptionModule implementation. |
| 35 void SetClient(mojo::ContentDecryptionModuleClientPtr client) final; | 35 void SetClient(mojo::ContentDecryptionModuleClientPtr client) final; |
| 36 void Initialize( | 36 void Initialize( |
| 37 const mojo::String& key_system, | 37 const mojo::String& key_system, |
| 38 const mojo::String& security_origin, | 38 const mojo::String& security_origin, |
| 39 mojo::CdmConfigPtr cdm_config, |
| 39 int32_t cdm_id, | 40 int32_t cdm_id, |
| 40 const mojo::Callback<void(mojo::CdmPromiseResultPtr)>& callback) final; | 41 const mojo::Callback<void(mojo::CdmPromiseResultPtr)>& callback) final; |
| 41 void SetServerCertificate( | 42 void SetServerCertificate( |
| 42 mojo::Array<uint8_t> certificate_data, | 43 mojo::Array<uint8_t> certificate_data, |
| 43 const mojo::Callback<void(mojo::CdmPromiseResultPtr)>& callback) final; | 44 const mojo::Callback<void(mojo::CdmPromiseResultPtr)>& callback) final; |
| 44 void CreateSessionAndGenerateRequest( | 45 void CreateSessionAndGenerateRequest( |
| 45 mojo::ContentDecryptionModule::SessionType session_type, | 46 mojo::ContentDecryptionModule::SessionType session_type, |
| 46 mojo::ContentDecryptionModule::InitDataType init_data_type, | 47 mojo::ContentDecryptionModule::InitDataType init_data_type, |
| 47 mojo::Array<uint8_t> init_data, | 48 mojo::Array<uint8_t> init_data, |
| 48 const mojo::Callback<void(mojo::CdmPromiseResultPtr, mojo::String)>& | 49 const mojo::Callback<void(mojo::CdmPromiseResultPtr, mojo::String)>& |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 102 | 103 |
| 103 base::WeakPtr<MojoCdmService> weak_this_; | 104 base::WeakPtr<MojoCdmService> weak_this_; |
| 104 base::WeakPtrFactory<MojoCdmService> weak_factory_; | 105 base::WeakPtrFactory<MojoCdmService> weak_factory_; |
| 105 | 106 |
| 106 DISALLOW_COPY_AND_ASSIGN(MojoCdmService); | 107 DISALLOW_COPY_AND_ASSIGN(MojoCdmService); |
| 107 }; | 108 }; |
| 108 | 109 |
| 109 } // namespace media | 110 } // namespace media |
| 110 | 111 |
| 111 #endif // MEDIA_MOJO_SERVICES_MOJO_CDM_SERVICE_H_ | 112 #endif // MEDIA_MOJO_SERVICES_MOJO_CDM_SERVICE_H_ |
| OLD | NEW |