Add a flatbuffer merge function
The second value wins. Vectors get appended. Nested objects get both
merged.
Change-Id: I1cb3f65b57d7cf219fca3c6d8dbb8418f8a0d697
diff --git a/aos/json_to_flatbuffer.fbs b/aos/json_to_flatbuffer.fbs
index 9743345..2e90a53 100644
--- a/aos/json_to_flatbuffer.fbs
+++ b/aos/json_to_flatbuffer.fbs
@@ -14,13 +14,14 @@
table Application {
name:string;
+ priority:int;
maps:[Map];
}
table Configuration {
locations:[Location] (id: 0);
maps:[Map] (id: 1);
- applications:[Application] (id: 2);
+ apps:[Application] (id: 2);
imports:[string] (id: 3);
// 8 bit: byte ubyte bool
@@ -68,6 +69,11 @@
// And a simple nested application.
single_application:Application (id: 28);
+
+ // TODO(austin): enum
+
+ // And nest this object to get some crazy coverage.
+ nested_config:Configuration (id: 29);
}
root_type Configuration;