public class CommonWebApi extends java.lang.Object
API shared by controllers, tag libraries and any other web artifact.
Modifiers | Name | Description |
---|---|---|
static java.lang.String |
RAW_CODEC_NAME |
Constructor and description |
---|
CommonWebApi
(GrailsPluginManager pluginManager) |
CommonWebApi
() |
Type | Name and description |
---|---|
protected GrailsWebRequest |
currentRequestAttributes() |
java.lang.String |
getActionName(java.lang.Object instance) Obtains the currently executing action name |
org.springframework.context.ApplicationContext |
getApplicationContext(java.lang.Object instance) Obtains the ApplicationContext instance |
java.lang.Object |
getControllerClass(java.lang.Object instance) Obtains the currently executing controllerClass |
java.lang.String |
getControllerName(java.lang.Object instance) Obtains the currently executing controller name |
java.lang.String |
getControllerNamespace(java.lang.Object instance) Obtains the currently executing controller namespace |
FlashScope |
getFlash(java.lang.Object instance) Obtains the Grails FlashScope instance |
GrailsApplication |
getGrailsApplication(java.lang.Object instance) Obtains the GrailsApplication instance |
GrailsApplicationAttributes |
getGrailsAttributes(java.lang.Object instance) Obtains the GrailsApplicationAttributes instance |
GrailsParameterMap |
getParams(java.lang.Object instance) Obtains the Grails parameter map |
java.lang.String |
getPluginContextPath(java.lang.Object delegate) Obtains the pluginContextPath |
javax.servlet.http.HttpServletRequest |
getRequest(java.lang.Object instance) Obtains the HttpServletRequest instance |
javax.servlet.http.HttpServletResponse |
getResponse(java.lang.Object instance) Obtains the HttpServletResponse instance |
javax.servlet.ServletContext |
getServletContext(java.lang.Object instance) Obtains the ServletContext instance |
javax.servlet.http.HttpSession |
getSession(java.lang.Object instance) Obtains the HttpSession instance |
GrailsWebRequest |
getWebRequest(java.lang.Object instance) Obtains the currently executing web request |
java.lang.Object |
raw(java.lang.Object instance, java.lang.Object value) Marks the given value to be output in raw form without encoding |
void |
setApplicationContext(org.springframework.context.ApplicationContext applicationContext) |
void |
setGrailsApplication(GrailsApplication grailsApplication) |
void |
setServletContext(javax.servlet.ServletContext servletContext) |
Methods inherited from class | Name |
---|---|
class java.lang.Object |
java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() |
Obtains the currently executing action name
Obtains the ApplicationContext instance
Obtains the currently executing controllerClass
Obtains the currently executing controller name
Obtains the currently executing controller namespace
Obtains the Grails FlashScope instance
Obtains the GrailsApplication instance
Obtains the GrailsApplicationAttributes instance
Obtains the Grails parameter map
Obtains the pluginContextPath
delegate
- The object the method is being invoked onObtains the HttpServletRequest instance
Obtains the HttpServletResponse instance
Obtains the ServletContext instance
Obtains the HttpSession instance
Obtains the currently executing web request
Marks the given value to be output in raw form without encoding
instance
- The instancevalue
- The value