Replies: 2 comments 2 replies
-
|
I'm not as familiar with the gRPC-LabVIEW side of things but I think there's an alternative for all of these oneofs. I haven't tried this personally but according to https://protobuf.dev/programming-guides/encoding/
Alternative: remains in your .proto file in place of the enum and two fields and is used to generate your client stubs. Or you just use the Again, I haven't tried this but I think this would be the case if you want to make the adjustments on your .proto files you got from this repo. gRPC-Device rationale for all the oneofs: |
Beta Was this translation helpful? Give feedback.
-
|
That were very helpful insights. I have to digest this now. Thank you so far. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hello, I really appreciate this project for its simplicity on the gRPC-device side. However, on the gRPC-LabVIEW side, we encounter cluttered code compared to the native LabVIEW implementation of the drivers. The primary reason for this is the extensive use of oneof in the driver’s proto files—nidaqmx.proto, for instance, contains 483 oneof statements. In LabVIEW, oneof generates classes, which feels unnecessarily heavy for an enum-like structure. LabVIEW users typically prefer to avoid class-based APIs, and I can't recall any official LabVIEW API that adopts such an approach.
I would like to understand whether there is an alternative to using oneof in cases like this. Additionally, could you explain why it is necessary to include all these _raw alternatives in the proto files?
Beta Was this translation helpful? Give feedback.
All reactions