commit | 34e29f5b28f019f062f5e4290ee635dcbf254c80 | [log] [tgz] |
---|---|---|
author | Wyatt Hepler <hepler@google.com> | Fri Aug 04 00:17:36 2023 +0000 |
committer | CQ Bot Account <pigweed-scoped@luci-project-accounts.iam.gserviceaccount.com> | Fri Aug 04 00:17:36 2023 +0000 |
tree | ce756764e5f906a5738eeff3cd8a336afb9136f9 | |
parent | ef1ee1b6af1dcbea5359a1b430cdc19646405861 [diff] |
pw_rpc: Avoid reflection in Java client The pw_rpc Java client currently requires manual service declarations, since codegen has not yet been implemented. Previously, service declarations used protobuf class objects. Later, their parser() methods were called using reflection. Relying on reflection is not ideal. It breaks when optimizers like R8 are used, since the parser() method is not actually called anywhere. This change updates Service declarations to accept protobuf parsers instead of class objects. Bug: b/293361955 Change-Id: Idec52db5ba429861c73a3886c9214001a2b264bb Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/162930 Pigweed-Auto-Submit: Wyatt Hepler <hepler@google.com> Reviewed-by: Alexei Frolov <frolv@google.com> Commit-Queue: Wyatt Hepler <hepler@google.com>
Pigweed is an open source collection of embedded-targeted libraries–or as we like to call them, modules. These modules are building blocks and infrastructure that enable faster and more reliable development on small-footprint MMU-less 32-bit microcontrollers like the STMicroelectronics STM32L452 or the Nordic nRF52832.
For more information please see our website: https://pigweed.dev/.