public class GroovyPageView extends AbstractGrailsView
A Spring View that renders Groovy Server Pages to the response. It requires an instance of GroovyPagesTemplateEngine to be set and will render to view returned by the getUrl() method of AbstractUrlBasedView This view also requires an instance of GrailsWebRequest to be bound to the currently executing Thread using Spring's RequestContextHolder. This can be done with by adding the GrailsWebRequestFilter.
Modifiers | Name | Description |
---|---|---|
static java.lang.String |
EXCEPTION_MODEL_KEY |
|
protected GroovyPageTemplate |
template |
|
protected GroovyPagesTemplateEngine |
templateEngine |
Type Params | Return Type | Name and description |
---|---|---|
|
public void |
afterPropertiesSet() |
|
public static GroovyPagesException |
createGroovyPageException(java.lang.Exception exception, GroovyPagesTemplateEngine engine, java.lang.String pageUrl) |
|
protected GSPResponseWriter |
createResponseWriter(GrailsWebRequest webRequest, HttpServletResponse response) Creates the Response Writer for the specified HttpServletResponse instance. |
|
public groovy.text.Template |
getTemplate() |
|
protected void |
handleException(java.lang.Exception exception, GroovyPagesTemplateEngine engine) Performs exception handling by attempting to render the Errors view. |
|
protected void |
initTemplate() |
|
public boolean |
isExpired() |
|
protected boolean |
isUrlRequired() |
|
protected void |
renderTemplate(java.util.Map<java.lang.String, java.lang.Object> model, GrailsWebRequest webRequest, HttpServletRequest request, HttpServletResponse response) |
|
public void |
rethrowRenderException(java.lang.Throwable ex, java.lang.String message) |
|
public void |
setScriptSource(ScriptSource scriptSource) |
|
public void |
setTemplate(groovy.text.Template template) |
|
public void |
setTemplateEngine(GroovyPagesTemplateEngine templateEngine) |
Creates the Response Writer for the specified HttpServletResponse instance.
response
- The HttpServletResponse instancePerforms exception handling by attempting to render the Errors view.
exception
- The exception that occuredengine
- The GSP engine