Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2016 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. | |
| 4 | |
| 5 #ifndef CHROME_BROWSER_UI_WEBUI_MEDIA_ROUTER_CAST_MODES_WITH_MEDIA_SOURCES_H_ | |
| 6 #define CHROME_BROWSER_UI_WEBUI_MEDIA_ROUTER_CAST_MODES_WITH_MEDIA_SOURCES_H_ | |
| 7 | |
| 8 #include <map> | |
| 9 #include <unordered_set> | |
| 10 | |
| 11 #include "chrome/browser/media/router/media_source.h" | |
| 12 #include "chrome/browser/ui/webui/media_router/media_cast_mode.h" | |
| 13 | |
| 14 namespace media_router { | |
| 15 | |
| 16 // | |
|
mark a. foltz
2016/08/31 05:18:55
Finish class level comment
takumif
2016/09/01 21:09:25
Oops. Done.
| |
| 17 class CastModesWithMediaSources { | |
| 18 public: | |
| 19 CastModesWithMediaSources(); | |
| 20 CastModesWithMediaSources(const CastModesWithMediaSources& other); | |
| 21 ~CastModesWithMediaSources(); | |
| 22 | |
| 23 void AddSource(const MediaSource& source, MediaCastMode cast_mode); | |
| 24 void RemoveSource(const MediaSource& source, MediaCastMode cast_mode); | |
| 25 bool HasSource(const MediaSource& source, MediaCastMode cast_mode) const; | |
| 26 | |
| 27 void RemoveCastMode(MediaCastMode cast_mode); | |
| 28 | |
| 29 CastModeSet GetCastModes() const; | |
| 30 | |
| 31 bool IsEmpty() const; | |
|
mark a. foltz
2016/08/31 05:18:54
Does this mean the cast mode set is empty? Please
takumif
2016/09/01 21:09:25
Done.
| |
| 32 | |
| 33 private: | |
| 34 std::map<MediaCastMode, std::unordered_set<MediaSource, MediaSource::Hash>> | |
| 35 cast_modes_; | |
| 36 }; | |
| 37 | |
| 38 } // namespace media_router | |
| 39 | |
| 40 #endif // CHROME_BROWSER_UI_WEBUI_MEDIA_ROUTER_CAST_MODES_WITH_MEDIA_SOURCES_H_ | |
| OLD | NEW |