當前位置: 首頁>>代碼示例>>Java>>正文


Java RenderRequest.getParameter方法代碼示例

本文整理匯總了Java中javax.portlet.RenderRequest.getParameter方法的典型用法代碼示例。如果您正苦於以下問題:Java RenderRequest.getParameter方法的具體用法?Java RenderRequest.getParameter怎麽用?Java RenderRequest.getParameter使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在javax.portlet.RenderRequest的用法示例。


在下文中一共展示了RenderRequest.getParameter方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: doView

import javax.portlet.RenderRequest; //導入方法依賴的package包/類
public void doView(RenderRequest request, RenderResponse response)
        throws PortletException, IOException
{
    response.setContentType("text/html");
    PrintWriter writer = response.getWriter();
    String user = request.getParameter("user");
    writer.println("<h1>Hello "+user+"!</h1>");
}
 
開發者ID:blackarbiter,項目名稱:Android_Code_Arbiter,代碼行數:9,代碼來源:XssPortlet.java

示例2: doView

import javax.portlet.RenderRequest; //導入方法依賴的package包/類
@Override
protected void doView(RenderRequest request, RenderResponse response)
	throws IOException, PortletException {

	PrintWriter printWriter = response.getWriter();

	String fileName = request.getParameter("fileName");
	String mimeType = request.getParameter("mimeType");
	String version = request.getParameter("version");
	String statusLabel = request.getParameter("statusLabel");
	String createdDate = request.getParameter("createdDate");
	String createdUserName = request.getParameter("createdUserName");

	printWriter.print(
		"<span style=\"color:green\">File Name</span>:" + fileName +
			"<br/>");
	printWriter.print(
		"<span style=\"color:green\">Type</span>:" + mimeType + "<br/>");
	printWriter.print(
		"<span style=\"color:green\">Version</span>:" + version + "<br/>");
	printWriter.print(
		"<span style=\"color:green\">Status</span>:" + statusLabel +
			"<br/>");
	printWriter.print(
		"<span style=\"color:green\">Created Date</span>:" + createdDate +
			"<br/>");
	printWriter.print(
		"<span style=\"color:green\">Created User Name</span>:" +
			createdUserName + "<br/>");
}
 
開發者ID:liferay,項目名稱:liferay-blade-samples,代碼行數:31,代碼來源:BladeDocumentActionPortlet.java

示例3: handleRenderRequest

import javax.portlet.RenderRequest; //導入方法依賴的package包/類
@Override
public ModelAndView handleRenderRequest(RenderRequest request, RenderResponse response) throws Exception {
	return new ModelAndView(request.getParameter("param"));
}
 
開發者ID:langtianya,項目名稱:spring4-understanding,代碼行數:5,代碼來源:ComplexPortletApplicationContext.java


注:本文中的javax.portlet.RenderRequest.getParameter方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。