class StringRenderer implements Renderer {

    @Override
    public void render(String value, Request request) throws IOException {
        if (value == null) {
            throw new CannotRenderException("Cannot render a null string");
        }
        request.getWriter().write(value);
    }

}