Index: services/resource_coordinator/public/cpp/coordination_unit_struct_traits.h |
diff --git a/services/resource_coordinator/public/cpp/coordination_unit_struct_traits.h b/services/resource_coordinator/public/cpp/coordination_unit_struct_traits.h |
new file mode 100644 |
index 0000000000000000000000000000000000000000..dfbe719005d26a8b1c709b88b887d937233c8e5e |
--- /dev/null |
+++ b/services/resource_coordinator/public/cpp/coordination_unit_struct_traits.h |
@@ -0,0 +1,29 @@ |
+// Copyright 2017 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+#ifndef SERVICES_RESOURCE_COORDINATOR_PUBLIC_CPP_COORDINATION_UNIT_STRUCT_TRAITS_H_ |
+#define SERVICES_RESOURCE_COORDINATOR_PUBLIC_CPP_COORDINATION_UNIT_STRUCT_TRAITS_H_ |
+ |
+#include "ipc/ipc_message_macros.h" |
+#include "ipc/param_traits_macros.h" |
+#include "services/resource_coordinator/public/cpp/coordination_unit_events.h" |
+#include "services/resource_coordinator/public/interfaces/coordination_unit.mojom.h" |
+ |
+IPC_ENUM_TRAITS_MIN_MAX_VALUE( |
Ken Rockot(use gerrit already)
2017/04/10 23:58:00
I am thoroughly confused. Why are you introducing
oystein (OOO til 10th of July)
2017/04/11 00:11:56
Separate reasons for each enum basically:
* For th
|
+ resource_coordinator::EventType, |
+ resource_coordinator::EventType::INVALID_EVENT, |
+ static_cast<size_t>(resource_coordinator::EventType::NUM_EVENTS) - 1) |
+ |
+IPC_ENUM_TRAITS_MIN_MAX_VALUE( |
+ resource_coordinator::CoordinationUnitType, |
+ resource_coordinator::CoordinationUnitType::INVALID_TYPE, |
+ static_cast<size_t>(resource_coordinator::CoordinationUnitType::NUM_TYPES) - |
+ 1) |
+ |
+IPC_STRUCT_TRAITS_BEGIN(resource_coordinator::CoordinationUnitID) |
+ IPC_STRUCT_TRAITS_MEMBER(type) |
+ IPC_STRUCT_TRAITS_MEMBER(id) |
+IPC_STRUCT_TRAITS_END() |
+ |
+#endif // SERVICES_RESOURCE_COORDINATOR_PUBLIC_CPP_COORDINATION_UNIT_STRUCT_TRAITS_H_ |