| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef MEDIA_BASE_VIDEO_FRAME_METADATA_H_ | 5 #ifndef MEDIA_BASE_VIDEO_FRAME_METADATA_H_ |
| 6 #define MEDIA_BASE_VIDEO_FRAME_METADATA_H_ | 6 #define MEDIA_BASE_VIDEO_FRAME_METADATA_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
| (...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 124 // Returns null if |key| was not present. | 124 // Returns null if |key| was not present. |
| 125 const base::Value* GetValue(Key key) const WARN_UNUSED_RESULT; | 125 const base::Value* GetValue(Key key) const WARN_UNUSED_RESULT; |
| 126 | 126 |
| 127 // Convenience method that returns true if |key| exists and is set to true. | 127 // Convenience method that returns true if |key| exists and is set to true. |
| 128 bool IsTrue(Key key) const WARN_UNUSED_RESULT; | 128 bool IsTrue(Key key) const WARN_UNUSED_RESULT; |
| 129 | 129 |
| 130 // For serialization. | 130 // For serialization. |
| 131 void MergeInternalValuesInto(base::DictionaryValue* out) const; | 131 void MergeInternalValuesInto(base::DictionaryValue* out) const; |
| 132 void MergeInternalValuesFrom(const base::DictionaryValue& in); | 132 void MergeInternalValuesFrom(const base::DictionaryValue& in); |
| 133 | 133 |
| 134 // Merges internal values from |metadata_source|. |
| 135 void MergeMetadataFrom(const VideoFrameMetadata* metadata_source); |
| 136 |
| 134 private: | 137 private: |
| 135 const base::BinaryValue* GetBinaryValue(Key key) const; | 138 const base::BinaryValue* GetBinaryValue(Key key) const; |
| 136 | 139 |
| 137 base::DictionaryValue dictionary_; | 140 base::DictionaryValue dictionary_; |
| 138 | 141 |
| 139 DISALLOW_COPY_AND_ASSIGN(VideoFrameMetadata); | 142 DISALLOW_COPY_AND_ASSIGN(VideoFrameMetadata); |
| 140 }; | 143 }; |
| 141 | 144 |
| 142 } // namespace media | 145 } // namespace media |
| 143 | 146 |
| 144 #endif // MEDIA_BASE_VIDEO_FRAME_METADATA_H_ | 147 #endif // MEDIA_BASE_VIDEO_FRAME_METADATA_H_ |
| OLD | NEW |