static ObjectCreationExpr getTargetValueVariableInitializer(final TargetValue targetValueField) {
        final MethodDeclaration methodDeclaration =
                TARGETVALUE_TEMPLATE.getMethodsByName(GETTARGETVALUE).get(0).clone();
        final BlockStmt targetValueBody =
                methodDeclaration.getBody().orElseThrow(() -> new KiePMMLException(String.format(MISSING_BODY_TEMPLATE, methodDeclaration)));
        final VariableDeclarator variableDeclarator =
                getVariableDeclarator(targetValueBody, TARGETVALUE).orElseThrow(() -> new KiePMMLException(String.format(MISSING_VARIABLE_IN_BODY, TARGETVALUE, targetValueBody)));
        final ObjectCreationExpr toReturn = variableDeclarator.getInitializer()
                .orElseThrow(() -> new KiePMMLException(String.format(MISSING_VARIABLE_INITIALIZER_TEMPLATE,
                                                                      TARGETVALUE, targetValueBody)))
                .asObjectCreationExpr();
        toReturn.setArgument(0, getExpressionForObject(targetValueField.getValue()));
        toReturn.setArgument(1, getExpressionForObject(targetValueField.getDisplayValue()));
        toReturn.setArgument(2, getExpressionForObject(targetValueField.getPriorProbability()));
        toReturn.setArgument(3, getExpressionForObject(targetValueField.getDefaultValue()));
        return toReturn;
    }
@Test
    void getTargetValueVariableInitializer() throws IOException {
        TargetValue targetValue = convertToKieTargetValue(getRandomTargetValue());
        ObjectCreationExpr retrieved = TargetValueFactory.getTargetValueVariableInitializer(targetValue);
        String text = getFileContent(TEST_01_SOURCE);
        Expression expected = JavaParserUtils.parseExpression(String.format(text,
                                                                            targetValue.getValue(),
                                                                            targetValue.getDisplayValue(),
                                                                            targetValue.getPriorProbability(),
                                                                            targetValue.getDefaultValue()));
        assertThat(JavaParserUtils.equalsNode(expected, retrieved)).isTrue();
        List<Class<?>> imports = Arrays.asList(Arrays.class, Collections.class, KiePMMLTargetValue.class,
                                               TargetValue.class);
        commonValidateCompilationWithImports(retrieved, imports);
    }