} else if ("json".equals(type)) {
res.setContentType("application/json");
provider = new ActionReportResultJsonProvider();
} else {
res.setContentType("text/html");
provider = new ActionReportResultHtmlProvider();
}
res.setStatus(statusCode);
res.getOutputStream().write(provider.getContent(new ActionReportResult(report)).getBytes());
res.getOutputStream().flush();
res.finishResponse();