return new RedirectResponse(re1.getTarget());
}
+ postProcess(request);
+
StringWriter stringWriter = new StringWriter();
template.render(stringWriter);
pageNode.content.addChild("%", stringWriter.toString());
}
/**
+ * This method will be called after
+ * {@link #processTemplate(net.pterodactylus.sone.web.page.Page.Request, Template)}
+ * has processed the template and the template was rendered. This method
+ * will not be called if
+ * {@link #processTemplate(net.pterodactylus.sone.web.page.Page.Request, Template)}
+ * throws a {@link RedirectException}!
+ *
+ * @param request
+ * The request being processed
+ */
+ protected void postProcess(Request request) {
+ /* do nothing. */
+ }
+
+ /**
* Can be overridden to redirect the user to a different page, in case a log
* in is required, or something else is wrong.
*