class KiePMMLRegressionTableRegressionFactory {

    static void populateOutputFieldsMap(final ClassOrInterfaceDeclaration tableTemplate,
                                        final List<KiePMMLOutputField> outputFields) {
        MethodDeclaration methodDeclaration =
                tableTemplate.getMethodsByName("populateOutputFieldsMapWithResult").get(0);
        BlockStmt body =
                methodDeclaration.getBody().orElseThrow(() -> new KiePMMLInternalException(String.format(MISSING_BODY_TEMPLATE, "populateOutputFieldsMapWithResult")));
        populateOutputFieldsMapWithResult(body, outputFields);
    }

    private  KiePMMLRegressionTableRegressionFactory();

}