Courier provides an API in the generator-api project that is used by the build system integrations (gradle-plugin and sbt-plugin). This API is then implemented by each language specific generator (scala, swift, android java).
However, there is no implementation of the API for the standard Pegasus Java data binding generator. As a result, it is not possible to generate Pegasus Java data bindings using the Courier schema language.
This is a relatively straight forward task. We simply need to define a new java/generator project and define a java/generator/src/main/java/org/coursera/courier/JavaGenerator.java class that implements PegasusCodeGenerator with a generate method that simply delegates to the existing Pegasus Java generator implementation.
Be sure to document how to set up a Courier project for Java in a README and link to it from the main courier documentation!
Courier provides an API in the generator-api project that is used by the build system integrations (gradle-plugin and sbt-plugin). This API is then implemented by each language specific generator (scala, swift, android java).
However, there is no implementation of the API for the standard Pegasus Java data binding generator. As a result, it is not possible to generate Pegasus Java data bindings using the Courier schema language.
This is a relatively straight forward task. We simply need to define a new
java/generator
project and define ajava/generator/src/main/java/org/coursera/courier/JavaGenerator.java
class that implementsPegasusCodeGenerator
with a generate method that simply delegates to the existing Pegasus Java generator implementation.Be sure to document how to set up a Courier project for Java in a README and link to it from the main courier documentation!