class VelocityMailTemplateService {

    public String mergeTemplate(@NotNull String templatePath, Map<String, Object> contextMap) {
        var velocityTemplate = velocityEngine.getTemplate(templatePath);
        var velocityContext = new VelocityContext(new HashMap<>(contextMap));
        var writer = new StringWriter();
        velocityTemplate.merge(velocityContext, writer);

        return writer.toString();
    }

    public  VelocityMailTemplateService(VelocityEngine velocityEngine);

}