examples/shardingsphere-sample/shardingsphere-example-engine/src/main/java/org/apache/sharding/example/engine/ExampleGenerateEngine.java
/**
     * Generate files based on data model.
     * @param obj data model
     * @param templateFile Equivalent to the template name of the template base directory.
     * @param outputFile Output directory and file name
     */
Generate files based on data model.
@param obj data model
@param templateFile Equivalent to the template name of the template base directory.
@param outputFile Output directory and file name
Generate files based on data model . @param obj data model @param templateFile Equivalent to the template name of the template base directory . @param outputFile Output directory and file name
public void process(final Object obj, final String templateFile, final String outputFile) {
        try {
            Template template = CONFIGURATION.getTemplate(templateFile);
            template.process(obj, new FileWriter(outputFile));
        } catch (IOException | TemplateException e) {
            e.printStackTrace();
        }
    }
public void process ( final Object obj , final String templateFile , final String outputFile ) { try { Template template = CONFIGURATION . getTemplate ( templateFile ) ; template . process ( obj , new FileWriter ( outputFile ) ) ; } catch ( IOException | TemplateException e ) { e . printStackTrace ( ) ; } }
Generate files based on data model.
Generate files based on data model .