Shaka Packager SDK
common_pssh_generator.h
1 // Copyright 2017 Google LLC. All rights reserved.
2 //
3 // Use of this source code is governed by a BSD-style
4 // license that can be found in the LICENSE file or at
5 // https://developers.google.com/open-source/licenses/bsd
6 
7 #ifndef PACKAGER_MEDIA_BASE_COMMON_PSSH_GENERATOR_H_
8 #define PACKAGER_MEDIA_BASE_COMMON_PSSH_GENERATOR_H_
9 
10 #include <packager/media/base/pssh_generator.h>
11 
12 namespace shaka {
13 namespace media {
14 
16  public:
18  ~CommonPsshGenerator() override;
19 
22  bool SupportMultipleKeys() override;
24 
25  private:
26  CommonPsshGenerator& operator=(const CommonPsshGenerator&) = delete;
28 
29  // PsshGenerator implemetation overrides.
30 
31  std::optional<std::vector<uint8_t>> GeneratePsshDataFromKeyIds(
32  const std::vector<std::vector<uint8_t>>& key_ids) const override;
33 
34  std::optional<std::vector<uint8_t>> GeneratePsshDataFromKeyIdAndKey(
35  const std::vector<uint8_t>& key_id,
36  const std::vector<uint8_t>& key) const override;
37 };
38 } // namespace media
39 } // namespace shaka
40 
41 #endif // PACKAGER_MEDIA_BASE_COMMON_PSSH_GENERATOR_H_
All the methods that are virtual are virtual for mocking.
Definition: crypto_flags.cc:66