Renaming of Usage Table related variables and types.
[ Merge of http://go/wvgerrit/164077 ] This CL makes major changes to the names of variables and types that are related to the usage table, header, entries, entry indexes, and other related data. The renaming followed these rules: 1) "Usage table header" will exclusively refer to the header blob that is OEMCrypto specific. The CDM class "UsageTableHeader" is the CDM-layer's abstraction around the "usage table" concept. The name has been updated to reflect that. 2) The "Cdm" prefix is only used for the CDM-specific data types for the usage table and entry info. It has been removed from OEMCrypto-specific types. - UsageTableHeader -> CdmUsageTable - CdmUsageTableHeader -> UsageTableHeader - CdmUsageEntry -> UsageEntry 3) The "usage_" prefix has been removed from variables when the usage table or usage entries are the subject of the function or class. 4) UsageEntryIndex is the type for entry indexes, instead of directly using uint32_t. This matches how we wrap other types in "wv_cdm_types.h" 5) Changed entry "number" to entry "index". 6) Vectors of elements have been renamed to be either pluralized or have a suffix "_list". 7) "Usage info" was occasionally being used to refer to the usage table or entries generally, rather than specifically secure-stop. - CryptoSession::HasUsageInfoSupport() -> HasUsageTableSupport() The most major change is that the files "usage_table_header*" have been renamed to be "cdm_usage_table*". Bug: 242914226 Test: run_x86_64_tests and request_license_test Change-Id: Iee98446b71f4f2934d3c9e0fb949eb05b84d1f8c
This commit is contained in:
@@ -97,8 +97,8 @@ class DeviceFiles {
|
||||
// App parameters.
|
||||
CdmAppParameterMap app_parameters;
|
||||
// Usage entry and index.
|
||||
CdmUsageEntry usage_entry;
|
||||
uint32_t usage_entry_number;
|
||||
UsageEntry usage_entry;
|
||||
UsageEntryIndex usage_entry_index;
|
||||
std::string drm_certificate;
|
||||
CryptoWrappedKey wrapped_private_key;
|
||||
};
|
||||
@@ -108,8 +108,8 @@ class DeviceFiles {
|
||||
CdmKeyMessage license_request;
|
||||
CdmKeyResponse license;
|
||||
std::string key_set_id;
|
||||
CdmUsageEntry usage_entry;
|
||||
uint32_t usage_entry_number;
|
||||
UsageEntry usage_entry;
|
||||
UsageEntryIndex usage_entry_index;
|
||||
std::string drm_certificate;
|
||||
CryptoWrappedKey wrapped_private_key;
|
||||
};
|
||||
@@ -180,7 +180,7 @@ class DeviceFiles {
|
||||
const std::string& provider_session_token,
|
||||
const CdmKeyMessage& key_request, const CdmKeyResponse& key_response,
|
||||
const std::string& usage_info_file_name, const std::string& key_set_id,
|
||||
const CdmUsageEntry& usage_entry, uint32_t usage_entry_number,
|
||||
const UsageEntry& usage_entry, UsageEntryIndex usage_entry_index,
|
||||
const std::string& drm_certificate, const CryptoWrappedKey& wrapped_key);
|
||||
|
||||
// Retrieve usage identifying information stored on the file system.
|
||||
@@ -233,8 +233,8 @@ class DeviceFiles {
|
||||
const std::string& provider_session_token,
|
||||
CdmKeyMessage* license_request,
|
||||
CdmKeyResponse* license_response,
|
||||
CdmUsageEntry* usage_entry,
|
||||
uint32_t* usage_entry_number,
|
||||
UsageEntry* usage_entry,
|
||||
UsageEntryIndex* usage_entry_index,
|
||||
std::string* drm_certificate,
|
||||
CryptoWrappedKey* wrapped_key);
|
||||
// Retrieve the usage info entry specified by |key_set_id|.
|
||||
@@ -242,8 +242,8 @@ class DeviceFiles {
|
||||
virtual bool RetrieveUsageInfoByKeySetId(
|
||||
const std::string& usage_info_file_name, const std::string& key_set_id,
|
||||
std::string* provider_session_token, CdmKeyMessage* license_request,
|
||||
CdmKeyResponse* license_response, CdmUsageEntry* usage_entry,
|
||||
uint32_t* usage_entry_number, std::string* drm_certificate,
|
||||
CdmKeyResponse* license_response, UsageEntry* usage_entry,
|
||||
UsageEntryIndex* usage_entry_index, std::string* drm_certificate,
|
||||
CryptoWrappedKey* wrapped_key);
|
||||
|
||||
// These APIs support upgrading from usage tables to usage tabler header +
|
||||
@@ -271,15 +271,15 @@ class DeviceFiles {
|
||||
virtual bool DeleteHlsAttributes(const std::string& key_set_id);
|
||||
|
||||
virtual bool StoreUsageTableInfo(
|
||||
const CdmUsageTableHeader& usage_table_header,
|
||||
const std::vector<CdmUsageEntryInfo>& usage_entry_info);
|
||||
const UsageTableHeader& usage_table_header,
|
||||
const std::vector<CdmUsageEntryInfo>& usage_entry_info_list);
|
||||
|
||||
// When retrieving usage table information from the file system; any
|
||||
// table that has yet to be updated for the LRU attributes will be
|
||||
// indicated by |lru_upgrade|.
|
||||
virtual bool RetrieveUsageTableInfo(
|
||||
CdmUsageTableHeader* usage_table_header,
|
||||
std::vector<CdmUsageEntryInfo>* usage_entry_info, bool* lru_upgrade);
|
||||
UsageTableHeader* usage_table_header,
|
||||
std::vector<CdmUsageEntryInfo>* usage_entry_info_list, bool* lru_upgrade);
|
||||
|
||||
virtual bool DeleteUsageTableInfo();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user