class FreemarkerRenderer implements Renderer {

    @Override
    public void render(String path, Request request) throws IOException {
        if (path == null) {
            throw new CannotRenderException("Cannot dispatch a null path");
        }
        ServletRequest servletRequest = org.apache.tiles.request.servlet.ServletUtil.getServletRequest(request);
        HttpServletRequest httpRequest = servletRequest.getRequest();
        HttpServletResponse httpResponse = servletRequest.getResponse();
        servlet.setValue(path);
        try {
            servlet.doGet(httpRequest,
                    new ExternalWriterHttpServletResponse(httpResponse,
                            request.getPrintWriter()));
        } catch (ServletException e) {
            throw new FreemarkerRequestException("Exception when rendering a FreeMarker attribute", e);
        }
    }

    public  FreemarkerRenderer(AttributeValueFreemarkerServlet servlet);

}