📄 portletresponse.html.svn-base
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Frameset//EN""http://www.w3.org/TR/REC-html40/frameset.dtd"><!--NewPage--><HTML><HEAD><!-- Generated by javadoc on Mon Sep 08 18:33:40 CEST 2003 --><TITLE>Portlet API (V1.0) : Interface PortletResponse</TITLE><LINK REL ="stylesheet" TYPE="text/css" HREF="../../stylesheet.css" TITLE="Style"></HEAD><BODY BGCOLOR="white"><!-- ========== START OF NAVBAR ========== --><A NAME="navbar_top"><!-- --></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0"><TR><TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"><A NAME="navbar_top_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3"> <TR ALIGN="center" VALIGN="top"> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD> <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD> </TR></TABLE></TD><TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>Portlet API (V1.0) </EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../javax/portlet/PortletRequestDispatcher.html"><B>PREV CLASS</B></A> <A HREF="../../javax/portlet/PortletSession.html"><B>NEXT CLASS</B></A></FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../index.html" TARGET="_top"><B>FRAMES</B></A> <A HREF="PortletResponse.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> SUMMARY: INNER | FIELD | CONSTR | <A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL: FIELD | CONSTR | <A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><!-- =========== END OF NAVBAR =========== --><HR><!-- ======== START OF CLASS DATA ======== --><H2><FONT SIZE="-1">javax.portlet</FONT><BR>Interface PortletResponse</H2><DL><DT><B>All Known Subinterfaces:</B> <DD><A HREF="../../javax/portlet/ActionResponse.html">ActionResponse</A>, <A HREF="../../javax/portlet/RenderResponse.html">RenderResponse</A></DD></DL><HR><DL><DT>public interface <B>PortletResponse</B></DL><P>The <CODE>PortletResponse</CODE> defines the base interface to assist a portlet in creating and sending a response to the client. The portlet container uses two specialized versions of this interface when invoking a portlet, <CODE>ActionResponse</CODE> and <CODE>RenderResponse</CODE>. The portlet container creates these objects and passes them as arguments to the portlet's <CODE>processAction</CODE> and <CODE>render</CODE> methods.<P><DL><DT><B>See Also: </B><DD><A HREF="../../javax/portlet/ActionResponse.html"><CODE>ActionResponse</CODE></A>, <A HREF="../../javax/portlet/RenderResponse.html"><CODE>RenderResponse</CODE></A></DL><HR><P><!-- ======== INNER CLASS SUMMARY ======== --><!-- =========== FIELD SUMMARY =========== --><!-- ======== CONSTRUCTOR SUMMARY ======== --><!-- ========== METHOD SUMMARY =========== --><A NAME="method_summary"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=2><FONT SIZE="+2"><B>Method Summary</B></FONT></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/portlet/PortletResponse.html#addProperty(java.lang.String, java.lang.String)">addProperty</A></B>(java.lang.String key, java.lang.String value)</CODE><BR> Adds a String property to an existing key to be returned to the portal.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> java.lang.String</CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/portlet/PortletResponse.html#encodeURL(java.lang.String)">encodeURL</A></B>(java.lang.String path)</CODE><BR> Returns the encoded URL of the resource, like servlets, JSPs, images and other static files, at the given path.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/portlet/PortletResponse.html#setProperty(java.lang.String, java.lang.String)">setProperty</A></B>(java.lang.String key, java.lang.String value)</CODE><BR> Sets a String property to be returned to the portal.</TD></TR></TABLE> <P><!-- ============ FIELD DETAIL =========== --><!-- ========= CONSTRUCTOR DETAIL ======== --><!-- ============ METHOD DETAIL ========== --><A NAME="method_detail"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Method Detail</B></FONT></TD></TR></TABLE><A NAME="addProperty(java.lang.String, java.lang.String)"><!-- --></A><H3>addProperty</H3><PRE>public void <B>addProperty</B>(java.lang.String key, java.lang.String value)</PRE><DL><DD>Adds a String property to an existing key to be returned to the portal. <p> This method allows response properties to have multiple values. <p> Properties can be used by portlets to provide vendor specific information to the portal.<DD><DL><DT><B>Parameters:</B><DD><CODE>key</CODE> - the key of the property to be returned to the portal<DD><CODE>value</CODE> - the value of the property to be returned to the portal<DT><B>Throws:</B><DD><CODE>java.lang.IllegalArgumentException</CODE> - if key is <code>null</code>.</DL></DD></DL><HR><A NAME="setProperty(java.lang.String, java.lang.String)"><!-- --></A><H3>setProperty</H3><PRE>public void <B>setProperty</B>(java.lang.String key, java.lang.String value)</PRE><DL><DD>Sets a String property to be returned to the portal. <p> Properties can be used by portlets to provide vendor specific information to the portal. <p> This method resets all properties previously added with the same key.<DD><DL><DT><B>Parameters:</B><DD><CODE>key</CODE> - the key of the property to be returned to the portal<DD><CODE>value</CODE> - the value of the property to be returned to the portal<DT><B>Throws:</B><DD><CODE>java.lang.IllegalArgumentException</CODE> - if key is <code>null</code>.</DL></DD></DL><HR><A NAME="encodeURL(java.lang.String)"><!-- --></A><H3>encodeURL</H3><PRE>public java.lang.String <B>encodeURL</B>(java.lang.String path)</PRE><DL><DD>Returns the encoded URL of the resource, like servlets, JSPs, images and other static files, at the given path. <p> Some portal/portlet-container implementation may require those URLs to contain implementation specific data encoded in it. Because of that, portlets should use this method to create such URLs. <p> The <code>encodeURL</code> method may include the session ID and other portal/portlet-container specific information into the URL. If encoding is not needed, it returns the URL unchanged.<DD><DL><DT><B>Parameters:</B><DD><CODE>path</CODE> - the URI path to the resource. This must be either an absolute URL (e.g. <code>http://my.co/myportal/mywebap/myfolder/myresource.gif</code>) or a full path URI (e.g. <code>/myportal/mywebap/myfolder/myresource.gif</code>).<DT><B>Returns:</B><DD>the encoded resource URL as string<DT><B>Throws:</B><DD><CODE>java.lang.IllegalArgumentException</CODE> - if path doesn't have a leading slash or is not an absolute URL</DL></DD></DL><!-- ========= END OF CLASS DATA ========= --><HR><!-- ========== START OF NAVBAR ========== --><A NAME="navbar_bottom"><!-- --></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0"><TR><TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"><A NAME="navbar_bottom_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3"> <TR ALIGN="center" VALIGN="top"> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD> <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD> </TR></TABLE></TD><TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>Portlet API (V1.0) </EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../javax/portlet/PortletRequestDispatcher.html"><B>PREV CLASS</B></A> <A HREF="../../javax/portlet/PortletSession.html"><B>NEXT CLASS</B></A></FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../index.html" TARGET="_top"><B>FRAMES</B></A> <A HREF="PortletResponse.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> SUMMARY: INNER | FIELD | CONSTR | <A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL: FIELD | CONSTR | <A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><!-- =========== END OF NAVBAR =========== --><HR><a href=license.txt >Copyright</a> © 2003 IBM Corporation and Sun Microsystems, Inc. All rights reserved</BODY></HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -