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 5 #ifndef MOJO_PUBLIC_CPP_BASE_THREAD_PRIORITY_MOJOM_TRAITS_H_ 6 #define MOJO_PUBLIC_CPP_BASE_THREAD_PRIORITY_MOJOM_TRAITS_H_ 7 8 #include "base/component_export.h" 9 #include "mojo/public/mojom/base/thread_priority.mojom-shared.h" 10 11 namespace mojo { 12 13 template <> COMPONENT_EXPORT(MOJO_BASE_MOJOM)14struct COMPONENT_EXPORT(MOJO_BASE_MOJOM) 15 EnumTraits<mojo_base::mojom::ThreadPriority, base::ThreadPriority> { 16 static mojo_base::mojom::ThreadPriority ToMojom( 17 base::ThreadPriority thread_priority); 18 static bool FromMojom(mojo_base::mojom::ThreadPriority input, 19 base::ThreadPriority* out); 20 }; 21 22 } // namespace mojo 23 24 #endif // MOJO_PUBLIC_CPP_BASE_THREAD_PRIORITY_MOJOM_TRAITS_H_