#ifdef UNSAFE_BUFFERS_BUILD
#pragma allow_unsafe_buffers
#endif
#include "media/cdm/library_cdm/clear_key_cdm/cdm_file_adapter.h"
#include <memory>
#include "base/functional/bind.h"
#include "base/logging.h"
#include "media/cdm/library_cdm/cdm_host_proxy.h"
namespace media {
namespace {
CdmFileAdapter::Status ConvertStatus(cdm::FileIOClient::Status status) { … }
}
CdmFileAdapter::CdmFileAdapter(CdmHostProxy* cdm_host_proxy) { … }
CdmFileAdapter::~CdmFileAdapter() { … }
void CdmFileAdapter::Open(const std::string& name, FileOpenedCB open_cb) { … }
void CdmFileAdapter::Read(ReadCB read_cb) { … }
void CdmFileAdapter::Write(const std::vector<uint8_t>& data, WriteCB write_cb) { … }
void CdmFileAdapter::OnOpenComplete(cdm::FileIOClient::Status status) { … }
void CdmFileAdapter::OnReadComplete(cdm::FileIOClient::Status status,
const uint8_t* data,
uint32_t data_size) { … }
void CdmFileAdapter::OnWriteComplete(cdm::FileIOClient::Status status) { … }
}