Ensure callback objects held by the Indexed DB
[chromium-blink-merge.git] / media / base / decrypt_config.cc
blob53e20143e1b0a0bdbbc82409d2a97f8fa64263f3
1 // Copyright (c) 2012 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.
5 #include "media/base/decrypt_config.h"
7 #include "base/logging.h"
9 namespace media {
11 DecryptConfig::DecryptConfig(const std::string& key_id,
12 const std::string& iv,
13 const int data_offset,
14 const std::vector<SubsampleEntry>& subsamples)
15 : key_id_(key_id),
16 iv_(iv),
17 data_offset_(data_offset),
18 subsamples_(subsamples) {
19 CHECK_GT(key_id.size(), 0u);
20 CHECK(iv.size() == static_cast<size_t>(DecryptConfig::kDecryptionKeySize) ||
21 iv.empty());
22 CHECK_GE(data_offset, 0);
25 DecryptConfig::~DecryptConfig() {}
27 } // namespace media