Instead of writing a custom adapter class for every single block, like ArduBlock is doing it,
I would really prefer to embed the code translation snippets inside the Language spec XML, maybe using some kind of pattern-template.
This would reduce code duplication for Processing Blocks JS, and would allow us to add other languages that are supported by the Processing IDE, like Python and Scala.
However a template based approach may not be powerful enough for some of the Higher-Level Blocks that don't have a 1:1 correspondence to the syntax of the target language.
Instead of writing a custom adapter class for every single block, like ArduBlock is doing it,
I would really prefer to embed the code translation snippets inside the Language spec XML, maybe using some kind of pattern-template.
This would reduce code duplication for Processing Blocks JS, and would allow us to add other languages that are supported by the Processing IDE, like Python and Scala.
However a template based approach may not be powerful enough for some of the Higher-Level Blocks that don't have a 1:1 correspondence to the syntax of the target language.