Class TextView
java.lang.Object
org.springframework.context.support.ApplicationObjectSupport
org.springframework.web.context.support.WebApplicationObjectSupport
org.springframework.web.servlet.view.AbstractView
ubic.gemma.web.controller.util.view.TextView
- All Implemented Interfaces:
org.springframework.beans.factory.Aware
,org.springframework.beans.factory.BeanNameAware
,org.springframework.context.ApplicationContextAware
,org.springframework.web.context.ServletContextAware
,org.springframework.web.servlet.View
public class TextView
extends org.springframework.web.servlet.view.AbstractView
Simply prints text to the client. The model must have a parameter matching TEXT_PARAM which holds the text to be
written.
- Author:
- pavlidis
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final String
Name of parameter used to retrieve the text from the model.Fields inherited from class org.springframework.web.servlet.view.AbstractView
DEFAULT_CONTENT_TYPE
Fields inherited from class org.springframework.context.support.ApplicationObjectSupport
logger
Fields inherited from interface org.springframework.web.servlet.View
PATH_VARIABLES, RESPONSE_STATUS_ATTRIBUTE, SELECTED_CONTENT_TYPE
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected void
renderMergedOutputModel
(Map<String, Object> model, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) void
setContentDisposition
(String contentDisposition) Methods inherited from class org.springframework.web.servlet.view.AbstractView
addStaticAttribute, createMergedOutputModel, createRequestContext, createTemporaryOutputStream, exposeModelAsRequestAttributes, generatesDownloadContent, getAttributesMap, getBeanName, getContentType, getRequestContextAttribute, getStaticAttributes, isExposePathVariables, prepareResponse, render, setAttributes, setAttributesCSV, setAttributesMap, setBeanName, setContentType, setExposePathVariables, setRequestContextAttribute, setResponseContentType, toString, writeToResponse
Methods inherited from class org.springframework.web.context.support.WebApplicationObjectSupport
getServletContext, getTempDir, getWebApplicationContext, initApplicationContext, initServletContext, isContextRequired, setServletContext
Methods inherited from class org.springframework.context.support.ApplicationObjectSupport
getApplicationContext, getMessageSourceAccessor, initApplicationContext, requiredContextClass, setApplicationContext
-
Field Details
-
TEXT_PARAM
Name of parameter used to retrieve the text from the model.- See Also:
-
-
Constructor Details
-
TextView
- Parameters:
textMediaSubType
- the subtype oftext/*
media type to use.
-
TextView
public TextView()Create a text view fortext/plain
content.
-
-
Method Details
-
setContentDisposition
-
renderMergedOutputModel
protected void renderMergedOutputModel(Map<String, Object> model, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws Exception- Specified by:
renderMergedOutputModel
in classorg.springframework.web.servlet.view.AbstractView
- Throws:
Exception
-