📄 portletrequest.html.svn-base
字号:
<DT><B>Parameters:</B><DD><CODE>name</CODE> - a <code>String</code> specifying the name of the parameter<DT><B>Returns:</B><DD>a <code>String</code> representing the single value of the parameter<DT><B>Throws:</B><DD><CODE>java.lang.IllegalArgumentException</CODE> - if name is <code>null</code>.<DT><B>See Also:</B><DD><A HREF="../../javax/portlet/PortletRequest.html#getParameterValues(java.lang.String)"><CODE>getParameterValues(java.lang.String)</CODE></A></DL></DD></DL><HR><A NAME="getParameterNames()"><!-- --></A><H3>getParameterNames</H3><PRE>java.util.Enumeration<java.lang.String> <B>getParameterNames</B>()</PRE><DL><DD>Returns an <code>Enumeration</code> of <code>String</code> objects containing the names of the parameters contained in this request. If the request has no parameters, the method returns an empty <code>Enumeration</code>. <p> Only parameters targeted to the current portlet are returned.<P><DD><DL><DT><B>Returns:</B><DD>an <code>Enumeration</code> of <code>String</code> objects, each <code>String</code> containing the name of a request parameter; or an empty <code>Enumeration</code> if the request has no parameters.</DL></DD></DL><HR><A NAME="getParameterValues(java.lang.String)"><!-- --></A><H3>getParameterValues</H3><PRE>java.lang.String[] <B>getParameterValues</B>(java.lang.String name)</PRE><DL><DD>Returns an array of <code>String</code> objects containing all of the values the given request parameter has, or <code>null</code> if the parameter does not exist. The returned parameters are "x-www-form-urlencoded" decoded. <p> If the parameter has a single value, the array has a length of 1.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>name</CODE> - a <code>String</code> containing the name of the parameter the value of which is requested<DT><B>Returns:</B><DD>an array of <code>String</code> objects containing the parameter values.<DT><B>Throws:</B><DD><CODE>java.lang.IllegalArgumentException</CODE> - if name is <code>null</code>.<DT><B>See Also:</B><DD><A HREF="../../javax/portlet/PortletRequest.html#getParameter(java.lang.String)"><CODE>getParameter(java.lang.String)</CODE></A></DL></DD></DL><HR><A NAME="getParameterMap()"><!-- --></A><H3>getParameterMap</H3><PRE>java.util.Map<java.lang.String,java.lang.String[]> <B>getParameterMap</B>()</PRE><DL><DD>Returns a <code>Map</code> of the parameters of this request. Request parameters are extra information sent with the request. The returned parameters are "x-www-form-urlencoded" decoded. <p> The values in the returned <code>Map</code> are from type String array (<code>String[]</code>). <p> If no parameters exist this method returns an empty <code>Map</code>.<P><DD><DL><DT><B>Returns:</B><DD>an immutable <code>Map</code> containing parameter names as keys and parameter values as map values, or an empty <code>Map</code> if no parameters exist. The keys in the parameter map are of type String. The values in the parameter map are of type String array (<code>String[]</code>).</DL></DD></DL><HR><A NAME="isSecure()"><!-- --></A><H3>isSecure</H3><PRE>boolean <B>isSecure</B>()</PRE><DL><DD>Returns a boolean indicating whether this request was made using a secure channel between client and the portal, such as HTTPS.<P><DD><DL><DT><B>Returns:</B><DD>true, if the request was made using a secure channel.</DL></DD></DL><HR><A NAME="setAttribute(java.lang.String, java.lang.Object)"><!-- --></A><H3>setAttribute</H3><PRE>void <B>setAttribute</B>(java.lang.String name, java.lang.Object o)</PRE><DL><DD>Stores an attribute in this request. <p>Attribute names should follow the same conventions as package names. Names beginning with <code>java.*</code>, <code>javax.*</code>, and <code>com.sun.*</code> are reserved.<br> If the value passed into this method is <code>null</code>, the effect is the same as calling <A HREF="../../javax/portlet/PortletRequest.html#removeAttribute(java.lang.String)"><CODE>removeAttribute(java.lang.String)</CODE></A>.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>name</CODE> - a <code>String</code> specifying the name of the attribute<DD><CODE>o</CODE> - the <code>Object</code> to be stored<DT><B>Throws:</B><DD><CODE>java.lang.IllegalArgumentException</CODE> - if name is <code>null</code>.</DL></DD></DL><HR><A NAME="removeAttribute(java.lang.String)"><!-- --></A><H3>removeAttribute</H3><PRE>void <B>removeAttribute</B>(java.lang.String name)</PRE><DL><DD>Removes an attribute from this request. This method is not generally needed, as attributes only persist as long as the request is being handled. <p>Attribute names should follow the same conventions as package names. Names beginning with <code>java.*</code>, <code>javax.*</code>, and <code>com.sun.*</code> are reserved.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>name</CODE> - a <code>String</code> specifying the name of the attribute to be removed<DT><B>Throws:</B><DD><CODE>java.lang.IllegalArgumentException</CODE> - if name is <code>null</code>.</DL></DD></DL><HR><A NAME="getRequestedSessionId()"><!-- --></A><H3>getRequestedSessionId</H3><PRE>java.lang.String <B>getRequestedSessionId</B>()</PRE><DL><DD>Returns the session ID indicated in the client request. This session ID may not be a valid one, it may be an old one that has expired or has been invalidated. If the client request did not specify a session ID, this method returns <code>null</code>.<P><DD><DL><DT><B>Returns:</B><DD>a <code>String</code> specifying the session ID, or <code>null</code> if the request did not specify a session ID<DT><B>See Also:</B><DD><A HREF="../../javax/portlet/PortletRequest.html#isRequestedSessionIdValid()"><CODE>isRequestedSessionIdValid()</CODE></A></DL></DD></DL><HR><A NAME="isRequestedSessionIdValid()"><!-- --></A><H3>isRequestedSessionIdValid</H3><PRE>boolean <B>isRequestedSessionIdValid</B>()</PRE><DL><DD>Checks whether the requested session ID is still valid.<P><DD><DL><DT><B>Returns:</B><DD><code>true</code> if this request has an id for a valid session in the current session context; <code>false</code> otherwise<DT><B>See Also:</B><DD><A HREF="../../javax/portlet/PortletRequest.html#getRequestedSessionId()"><CODE>getRequestedSessionId()</CODE></A>, <A HREF="../../javax/portlet/PortletRequest.html#getPortletSession()"><CODE>getPortletSession()</CODE></A></DL></DD></DL><HR><A NAME="getResponseContentType()"><!-- --></A><H3>getResponseContentType</H3><PRE>java.lang.String <B>getResponseContentType</B>()</PRE><DL><DD>Returns the portal preferred content type for the response. <p> The following restrictions apply: <ul> <li>The content type only includes the MIME type, not the character set. The character set of the response can be retrieved via the <A HREF="../../javax/portlet/MimeResponse.html#getCharacterEncoding()"><CODE>MimeResponse.getCharacterEncoding()</CODE></A>.</li> <li>Only content types that the portlet has defined in its deployment descriptor are valid return values for this method call. If the portlet has defined <code>'*'</code> or <code>'* / *'</code> as supported content types, these may also be valid return values.</li> </ul><P><DD><DL><DT><B>Returns:</B><DD>preferred MIME type of the response</DL></DD></DL><HR><A NAME="getResponseContentTypes()"><!-- --></A><H3>getResponseContentTypes</H3><PRE>java.util.Enumeration<java.lang.String> <B>getResponseContentTypes</B>()</PRE><DL><DD>Gets a list of content types which the portal accepts for the response. This list is ordered with the most preferable types listed first. <p> The following restrictions apply: <ul> <li>The content type only includes the MIME type, not the character set.</li> <li>Only content types that the portlet has defined in its deployment descriptor are valid return values for this method call. If the portlet has defined <code>'*'</code> or <code>'* / *'</code> as supported content types, these may also be valid return values.</li> </ul><P><DD><DL><DT><B>Returns:</B><DD>ordered list of MIME types for the response</DL></DD></DL><HR><A NAME="getLocale()"><!-- --></A><H3>getLocale</H3><PRE>java.util.Locale <B>getLocale</B>()</PRE><DL><DD>Returns the preferred Locale in which the portal will accept content. The Locale may be based on the Accept-Language header of the client.<P><DD><DL><DT><B>Returns:</B><DD>the preferred Locale in which the portal will accept content.</DL></DD></DL><HR><A NAME="getLocales()"><!-- --></A><H3>getLocales</H3><PRE>java.util.Enumeration<java.util.Locale> <B>getLocales</B>()</PRE><DL><DD>Returns an Enumeration of Locale objects indicating, in decreasing order starting with the preferred locale in which the portal will accept content for this request. The Locales may be based on the Accept-Language header of the client.<P><DD><DL><DT><B>Returns:</B><DD>an Enumeration of Locales, in decreasing order, in which the portal will accept content for this request</DL></DD></DL><HR><A NAME="getScheme()"><!-- --></A><H3>getScheme</H3><PRE>java.lang.String <B>getScheme</B>()</PRE><DL><DD>Returns the name of the scheme used to make this request. For example, <code>http</code>, <code>https</code>, or <code>ftp</code>. Different schemes have different rules for constructing URLs, as noted in RFC 1738.<P><DD><DL><DT><B>Returns:</B><DD>a <code>String</code> containing the name of the scheme used to make this request</DL></DD></DL><HR><A NAME="getServerName()"><!-- --></A><H3>getServerName</H3><PRE>java.lang.String <B>getServerName</B>()</PRE><DL><DD>Returns the host name of the server that received the request.<P><DD><DL><DT><B>Returns:</B><DD>a <code>String</code> containing the name of the server to which the request was sent</DL></DD></DL><HR><A NAME="getServerPort()"><!-- --></A><H3>getServerPort</H3><PRE>int <B>getServerPort</B>()</PRE><DL><DD>Returns the port number on which this request was received.<P><DD><DL><DT><B>Returns:</B><DD>an integer specifying the port number</DL></DD></DL><HR><A NAME="getWindowID()"><!-- --></A><H3>getWindowID</H3><PRE>java.lang.String <B>getWindowID</B>()</PRE><D
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -