org.codehaus.groovy.grails.plugins.testing
Class GrailsMockHttpServletRequest

java.lang.Object
  extended by org.springframework.mock.web.MockHttpServletRequest
      extended by org.codehaus.groovy.grails.plugins.testing.GrailsMockHttpServletRequest
All Implemented Interfaces:
groovy.lang.GroovyObject, HttpServletRequest, ServletRequest

public class GrailsMockHttpServletRequest
extends MockHttpServletRequest
implements groovy.lang.GroovyObject


Field Summary
 
Fields inherited from class org.springframework.mock.web.MockHttpServletRequest
DEFAULT_PROTOCOL, DEFAULT_REMOTE_ADDR, DEFAULT_REMOTE_HOST, DEFAULT_SERVER_ADDR, DEFAULT_SERVER_NAME, DEFAULT_SERVER_PORT
 
Fields inherited from interface javax.servlet.http.HttpServletRequest
BASIC_AUTH, CLIENT_CERT_AUTH, DIGEST_AUTH, FORM_AUTH
 
Constructor Summary
GrailsMockHttpServletRequest()
           
 
Method Summary
protected  groovy.lang.MetaClass $getStaticMetaClass()
           
 Object each(groovy.lang.Closure c)
           
 Object find(groovy.lang.Closure c)
           
 Object findAll(groovy.lang.Closure c)
           
 Object getAt(String key)
           
 String getForwardURI()
           
 boolean getInvalidToken()
           
 Object getJSON()
           
 groovy.lang.MetaClass getMetaClass()
           
 Object getProperty(String name)
           
 Object getXML()
           
 Object invokeMethod(String method, Object arguments)
           
 boolean isGet()
           
 boolean isInvalidToken()
           
 boolean isPost()
           
 boolean isXhr()
           
 void makeAjaxRequest()
           
 void putAt(String key, Object val)
           
 void setForwardURI(String uri)
           
 void setInvalidToken(boolean value)
           
 void setMetaClass(groovy.lang.MetaClass mc)
           
 void setProperty(String name, Object value)
           
 
Methods inherited from class org.springframework.mock.web.MockHttpServletRequest
addHeader, addParameter, addParameter, addParameters, addPreferredLocale, addUserRole, checkActive, clearAttributes, close, getAttribute, getAttributeNames, getAuthType, getCharacterEncoding, getContentLength, getContentType, getContextPath, getCookies, getDateHeader, getHeader, getHeaderNames, getHeaders, getInputStream, getIntHeader, getLocalAddr, getLocale, getLocales, getLocalName, getLocalPort, getMethod, getParameter, getParameterMap, getParameterNames, getParameterValues, getPathInfo, getPathTranslated, getProtocol, getQueryString, getReader, getRealPath, getRemoteAddr, getRemoteHost, getRemotePort, getRemoteUser, getRequestDispatcher, getRequestedSessionId, getRequestURI, getRequestURL, getScheme, getServerName, getServerPort, getServletContext, getServletPath, getSession, getSession, getUserPrincipal, invalidate, isActive, isRequestedSessionIdFromCookie, isRequestedSessionIdFromUrl, isRequestedSessionIdFromURL, isRequestedSessionIdValid, isSecure, isUserInRole, removeAllParameters, removeAttribute, removeParameter, setAttribute, setAuthType, setCharacterEncoding, setContent, setContentType, setContextPath, setCookies, setLocalAddr, setLocalName, setLocalPort, setMethod, setParameter, setParameter, setParameters, setPathInfo, setProtocol, setQueryString, setRemoteAddr, setRemoteHost, setRemotePort, setRemoteUser, setRequestedSessionId, setRequestedSessionIdFromCookie, setRequestedSessionIdFromURL, setRequestedSessionIdValid, setRequestURI, setScheme, setSecure, setServerName, setServerPort, setServletPath, setSession, setUserPrincipal
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GrailsMockHttpServletRequest

public GrailsMockHttpServletRequest()
Method Detail

getInvalidToken

public boolean getInvalidToken()

isInvalidToken

public boolean isInvalidToken()

setInvalidToken

public void setInvalidToken(boolean value)

getForwardURI

public String getForwardURI()

setForwardURI

public void setForwardURI(String uri)

isXhr

public boolean isXhr()

makeAjaxRequest

public void makeAjaxRequest()

getAt

public Object getAt(String key)

putAt

public void putAt(String key,
                  Object val)

getProperty

public Object getProperty(String name)
Specified by:
getProperty in interface groovy.lang.GroovyObject

setProperty

public void setProperty(String name,
                        Object value)
Specified by:
setProperty in interface groovy.lang.GroovyObject

isGet

public boolean isGet()

isPost

public boolean isPost()

getXML

public Object getXML()

getJSON

public Object getJSON()

find

public Object find(groovy.lang.Closure c)

findAll

public Object findAll(groovy.lang.Closure c)

each

public Object each(groovy.lang.Closure c)

$getStaticMetaClass

protected groovy.lang.MetaClass $getStaticMetaClass()

getMetaClass

public groovy.lang.MetaClass getMetaClass()
Specified by:
getMetaClass in interface groovy.lang.GroovyObject

setMetaClass

public void setMetaClass(groovy.lang.MetaClass mc)
Specified by:
setMetaClass in interface groovy.lang.GroovyObject

invokeMethod

public Object invokeMethod(String method,
                           Object arguments)
Specified by:
invokeMethod in interface groovy.lang.GroovyObject


Copyright (c) 2005-2009 The Grails project