tree: 589ee3612b982655615228701c6b076d35d61729 [path history] [tgz]
  1. access_code_cast_constants.cc
  2. access_code_cast_constants.h
  3. access_code_cast_discovery_interface.cc
  4. access_code_cast_discovery_interface.h
  5. access_code_cast_discovery_interface_unittest.cc
  6. access_code_cast_feature.cc
  7. access_code_cast_feature.h
  8. access_code_cast_feature_unittest.cc
  9. access_code_cast_pref_updater.cc
  10. access_code_cast_pref_updater.h
  11. access_code_cast_pref_updater_impl.cc
  12. access_code_cast_pref_updater_impl.h
  13. access_code_cast_pref_updater_impl_unittest.cc
  14. access_code_cast_pref_updater_unittest.cc
  15. access_code_cast_sink_service.cc
  16. access_code_cast_sink_service.h
  17. access_code_cast_sink_service_browsertest.cc
  18. access_code_cast_sink_service_factory.cc
  19. access_code_cast_sink_service_factory.h
  20. access_code_cast_sink_service_factory_unittest.cc
  21. access_code_cast_sink_service_unittest.cc
  22. access_code_media_sink_util.cc
  23. access_code_media_sink_util.h
  24. access_code_media_sink_util_unittest.cc
  25. access_code_test_util.cc
  26. access_code_test_util.h
  27. BUILD.gn
  28. DEPS
  29. DIR_METADATA
  30. discovery_resources.proto
  31. OWNERS
  32. README.md
chrome/browser/media/router/discovery/access_code/README.md

Overview

Access Code Casting is an extension of the Media Router that allows for casting via an access code.

External Uses

The external product that currently only uses this feature is Cast Moderator

User Flow

The code within this directory handles the back end of an access code within Chrome.

  1. An access code is submitted
  2. Check with the server if this is a valid access code
  3. Construct a device with returned info from server
  4. Attempt to add this device to the media router
  5. Attempt to start a casting session to this device
  6. (Optional) Store this device in prefs

Important Classes

access_code_cast_sink_service The communication from the frontend to backend is handled by this class. This class also handles the lifetimes of other objects that are constructed within this directory.

This class also handles stored device logic on startup/whenever a route is removed.

access_code_cast_discovery_interface Handles communication between the server and Chrome

access_code_cast_pref_updater Handles storage of prefs within Chrome.

access_code_cast_service_factory Handles the construction of the AccessCodeCastSinkService and ensures lifetime is valid within the constrains of the Media Router lifetime.