| OLD | NEW |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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 CONTENT_COMMON_URL_REQUEST_STRUCT_TRAITS_H_ | 5 #ifndef CONTENT_COMMON_URL_REQUEST_STRUCT_TRAITS_H_ |
| 6 #define CONTENT_COMMON_URL_REQUEST_STRUCT_TRAITS_H_ | 6 #define CONTENT_COMMON_URL_REQUEST_STRUCT_TRAITS_H_ |
| 7 | 7 |
| 8 #include "content/common/url_loader.mojom.h" | 8 #include "content/public/common/url_loader.mojom.h" |
| 9 #include "mojo/public/cpp/bindings/enum_traits.h" | 9 #include "mojo/public/cpp/bindings/enum_traits.h" |
| 10 #include "net/base/request_priority.h" | 10 #include "net/base/request_priority.h" |
| 11 | 11 |
| 12 namespace mojo { | 12 namespace mojo { |
| 13 | 13 |
| 14 template <> | 14 template <> |
| 15 struct EnumTraits<content::mojom::RequestPriority, net::RequestPriority> { | 15 struct EnumTraits<content::mojom::RequestPriority, net::RequestPriority> { |
| 16 static content::mojom::RequestPriority ToMojom(net::RequestPriority priority); | 16 static content::mojom::RequestPriority ToMojom(net::RequestPriority priority); |
| 17 static bool FromMojom(content::mojom::RequestPriority in, | 17 static bool FromMojom(content::mojom::RequestPriority in, |
| 18 net::RequestPriority* out); | 18 net::RequestPriority* out); |
| 19 }; | 19 }; |
| 20 | 20 |
| 21 } // namespace mojo | 21 } // namespace mojo |
| 22 | 22 |
| 23 #endif // CONTENT_COMMON_URL_REQUEST_STRUCT_TRAITS_H_ | 23 #endif // CONTENT_COMMON_URL_REQUEST_STRUCT_TRAITS_H_ |
| OLD | NEW |