+// Loads a emulated stored session. Currently only |kLoadableWebSessionId|
+// (containing a |kLoadableSessionKey| for |kLoadableSessionKeyId|) is
+// supported.
+void ClearKeyCdm::LoadSession(uint32_t session_id,
+ const char* web_session_id,
+ uint32_t web_session_id_length) {
+ DVLOG(1) << __FUNCTION__;
+
+ if (std::string(kLoadableWebSessionId) !=
+ std::string(web_session_id, web_session_id_length)) {
+ // TODO(xhwang): Report "NotFoundError" when we support DOMError style.
+ OnSessionError(session_id, MediaKeys::kUnknownError, 0);
+ return;
+ }
+
+ session_id_for_emulated_loadsession_ = session_id;
+
+ decryptor_.CreateSession(session_id, kLoadableSessionContentType, NULL, 0);
+}
+