Search in sources :

Example 1 with MasterDataDefinitionModel

use of io.vertigo.studio.plugins.mda.domain.java.model.masterdata.MasterDataDefinitionModel in project vertigo by KleeGroup.

the class DomainGeneratorPlugin method generateJavaEnum.

private void generateJavaEnum(final FileGeneratorConfig fileGeneratorConfig, final MdaResultBuilder mdaResultBuilder, final DtDefinition dtDefinition, final Map<String, MasterDataValue> values) {
    final MasterDataDefinitionModel masterDataDefinitionModel = new MasterDataDefinitionModel(dtDefinition, values);
    final Map<String, Object> model = new MapBuilder<String, Object>().put("entity", masterDataDefinitionModel).build();
    FileGenerator.builder(fileGeneratorConfig).withModel(model).withFileName(masterDataDefinitionModel.getClassSimpleName() + "Enum.java").withGenSubDir(targetSubDir).withPackageName(dtDefinition.getPackageName()).withTemplateName("domain/java/template/masterdata_enum.ftl").build().generateFile(mdaResultBuilder);
}
Also used : MapBuilder(io.vertigo.util.MapBuilder) MasterDataDefinitionModel(io.vertigo.studio.plugins.mda.domain.java.model.masterdata.MasterDataDefinitionModel)

Aggregations

MasterDataDefinitionModel (io.vertigo.studio.plugins.mda.domain.java.model.masterdata.MasterDataDefinitionModel)1 MapBuilder (io.vertigo.util.MapBuilder)1