route_message_util.h 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. // Copyright 2018 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. #ifndef COMPONENTS_MEDIA_ROUTER_BROWSER_ROUTE_MESSAGE_UTIL_H_
  5. #define COMPONENTS_MEDIA_ROUTER_BROWSER_ROUTE_MESSAGE_UTIL_H_
  6. #include <cstdint>
  7. #include <string>
  8. #include <vector>
  9. #include "components/media_router/common/mojom/media_router.mojom.h"
  10. #include "third_party/blink/public/mojom/presentation/presentation.mojom.h"
  11. namespace base {
  12. class Value;
  13. } // namespace base
  14. namespace media_router {
  15. namespace message_util {
  16. media_router::mojom::RouteMessagePtr RouteMessageFromValue(base::Value value);
  17. media_router::mojom::RouteMessagePtr RouteMessageFromString(
  18. std::string message);
  19. media_router::mojom::RouteMessagePtr RouteMessageFromData(
  20. std::vector<uint8_t> data);
  21. blink::mojom::PresentationConnectionMessagePtr
  22. PresentationConnectionFromRouteMessage(
  23. media_router::mojom::RouteMessagePtr route_message);
  24. } // namespace message_util
  25. } // namespace media_router
  26. #endif // COMPONENTS_MEDIA_ROUTER_BROWSER_ROUTE_MESSAGE_UTIL_H_