|
spring-test | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.springframework.mock.web.portlet.MockPortletRequest
org.springframework.mock.web.portlet.MockClientDataRequest
org.springframework.mock.web.portlet.MockActionRequest
org.springframework.mock.web.portlet.MockMultipartActionRequest
public class MockMultipartActionRequest
Mock implementation of the
MultipartActionRequest interface.
Useful for testing application controllers that access multipart uploads.
The MockMultipartFile can be used to
populate these mock requests with files.
MockMultipartFile| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface javax.portlet.PortletRequest |
|---|
javax.portlet.PortletRequest.P3PUserInfos |
| Field Summary |
|---|
| Fields inherited from interface javax.portlet.ActionRequest |
|---|
ACTION_NAME |
| Fields inherited from interface javax.portlet.PortletRequest |
|---|
ACTION_PHASE, ACTION_SCOPE_ID, BASIC_AUTH, CCPP_PROFILE, CLIENT_CERT_AUTH, DIGEST_AUTH, EVENT_PHASE, FORM_AUTH, LIFECYCLE_PHASE, RENDER_HEADERS, RENDER_MARKUP, RENDER_PART, RENDER_PHASE, RESOURCE_PHASE, USER_INFO |
| Constructor Summary | |
|---|---|
MockMultipartActionRequest()
|
|
| Method Summary | |
|---|---|
void |
addFile(org.springframework.web.multipart.MultipartFile file)
Add a file to this request. |
org.springframework.web.multipart.MultipartFile |
getFile(java.lang.String name)
|
java.util.Map<java.lang.String,org.springframework.web.multipart.MultipartFile> |
getFileMap()
|
java.util.Iterator<java.lang.String> |
getFileNames()
|
java.util.List<org.springframework.web.multipart.MultipartFile> |
getFiles(java.lang.String name)
|
org.springframework.util.MultiValueMap<java.lang.String,org.springframework.web.multipart.MultipartFile> |
getMultiFileMap()
|
java.lang.String |
getMultipartContentType(java.lang.String paramOrFileName)
|
| Methods inherited from class org.springframework.mock.web.portlet.MockActionRequest |
|---|
getLifecyclePhase |
| Methods inherited from class org.springframework.mock.web.portlet.MockClientDataRequest |
|---|
getCharacterEncoding, getContentLength, getContentType, getMethod, getPortletInputStream, getReader, setCharacterEncoding, setContent, setContentType, setMethod |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface javax.portlet.ClientDataRequest |
|---|
getCharacterEncoding, getContentLength, getContentType, getMethod, getPortletInputStream, getReader, setCharacterEncoding |
| Methods inherited from interface javax.portlet.PortletRequest |
|---|
getAttribute, getAttributeNames, getAuthType, getContextPath, getCookies, getLocale, getLocales, getParameter, getParameterMap, getParameterNames, getParameterValues, getPortalContext, getPortletMode, getPortletSession, getPortletSession, getPreferences, getPrivateParameterMap, getProperties, getProperty, getPropertyNames, getPublicParameterMap, getRemoteUser, getRequestedSessionId, getResponseContentType, getResponseContentTypes, getScheme, getServerName, getServerPort, getUserPrincipal, getWindowID, getWindowState, isPortletModeAllowed, isRequestedSessionIdValid, isSecure, isUserInRole, isWindowStateAllowed, removeAttribute, setAttribute |
| Constructor Detail |
|---|
public MockMultipartActionRequest()
| Method Detail |
|---|
public void addFile(org.springframework.web.multipart.MultipartFile file)
MultipartFile.getName().
file - multipart file to be addedpublic java.util.Iterator<java.lang.String> getFileNames()
getFileNames in interface org.springframework.web.multipart.MultipartRequestpublic org.springframework.web.multipart.MultipartFile getFile(java.lang.String name)
getFile in interface org.springframework.web.multipart.MultipartRequestpublic java.util.List<org.springframework.web.multipart.MultipartFile> getFiles(java.lang.String name)
getFiles in interface org.springframework.web.multipart.MultipartRequestpublic java.util.Map<java.lang.String,org.springframework.web.multipart.MultipartFile> getFileMap()
getFileMap in interface org.springframework.web.multipart.MultipartRequestpublic org.springframework.util.MultiValueMap<java.lang.String,org.springframework.web.multipart.MultipartFile> getMultiFileMap()
getMultiFileMap in interface org.springframework.web.multipart.MultipartRequestpublic java.lang.String getMultipartContentType(java.lang.String paramOrFileName)
getMultipartContentType in interface org.springframework.web.multipart.MultipartRequest
|
spring-test | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||