aboutsummaryrefslogtreecommitdiff
path: root/pw_protobuf/CMakeLists.txt
diff options
context:
space:
mode:
authorScott James Remnant <keybuk@google.com>2022-04-01 15:11:15 -0700
committerCQ Bot Account <pigweed-scoped@luci-project-accounts.iam.gserviceaccount.com>2022-04-08 23:50:29 +0000
commit3c4cb30280736202eba44e87b3c56e58416868ec (patch)
tree824ac5435510cf1a458f5c79e8c4b3942e23a780 /pw_protobuf/CMakeLists.txt
parent1d3fe223eee7b73f994cade1d09cfc77e046f1b9 (diff)
downloadpigweed-3c4cb30280736202eba44e87b3c56e58416868ec.tar.gz
pw_protobuf: StreamEncoder and MemoryEncoder support for tables
This implements protobuf encoding from a struct described by a series of MessageField structures. A new protected StreamEncoder::Write() method is added that accepts a span of bytes corresponding to a 'struct Message', and a span of MessageField describing the fields therein. The generated code is extended to add a Write() method to each StreamEncoder and MemoryEncoder wrapper that accepts a struct of the correct type and passes in the corresponding fields table. Change-Id: I7c67a5bbf4920ae5f9b8a561babee58c4dac7e33 Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/89641 Reviewed-by: Keir Mierle <keir@google.com> Commit-Queue: Scott James Remnant <keybuk@google.com> Pigweed-Auto-Submit: Scott James Remnant <keybuk@google.com>
Diffstat (limited to 'pw_protobuf/CMakeLists.txt')
-rw-r--r--pw_protobuf/CMakeLists.txt1
1 files changed, 1 insertions, 0 deletions
diff --git a/pw_protobuf/CMakeLists.txt b/pw_protobuf/CMakeLists.txt
index 58461a6c8..8cba471fb 100644
--- a/pw_protobuf/CMakeLists.txt
+++ b/pw_protobuf/CMakeLists.txt
@@ -133,6 +133,7 @@ pw_add_test(pw_protobuf.codegen_message_test
DEPS
pw_protobuf
pw_protobuf.codegen_test_protos.pwpb
+ pw_string
GROUPS
modules
pw_protobuf