Agent: add automatically generated bindings for Java #4617
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Previously, we only generated bindings for Kotlin. The Eclipse plugin is written in Java so this PR adds support to generate Java bindings as well. Java and Kotlin are very similar so required diff is minimal. The Java code is not added to this repo because we already have the Kotlin bindings here and I don't want every agent-protocol.ts PR to have a huge diff. Instead, we can just commit the Java bindings directly to the Eclipse repo.
Note: the code generator implementation is already quite messy and it's getting more messy with this PR. I am willing to take on this tech debt for now because it's easy to catch regressions from diffs in the generated code.
Test plan
Minimal and low-risk diffs in Kotlin bindings (adding semi-colons and using Java getter method names instead of Kotlin sugar)