Java Generation

The goal of the Java Generation plug-in is to allow Java code generation from a Java model. Such a generation will fulfill some of the requirements for Legacy refactoring and migration.

Quality disclaimer: this generator is provided without any guarantee.

Description

This plug-in proposes Acceleo modules for generating Java files conforming to Java models. Templates are contained in two modules

Java models are obtained with the Java Discoverer component.

Considering a Java legacy, a minimal migration/refactoring chain will involve

User manual

A prerequisite is a Java model. Please refer to the Java Discoverer user manual.

To launch a Java generation, add org.eclipse.modisco.java.generation in your plugin dependencies and use the GenerateJavaExtended main method with input model and target folder as parameters. The code should look like this :

GenerateJavaExtended javaGenerator = new GenerateJavaExtended(URI.createFileURI("C:/.../my.javaxmi"),
    new File("C:/.../myOutputFolder"), new ArrayList<Object>());
javaGenerator.doGenerate(null);

Note : at the moment this documentation is written, there is no way of creating one Acceleo Launch Configuration based on one installed Acceleo module plugin.