|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
The PortletResponse
interface represents the response
sent to the client device.
It is up to the portlet container to enhance, extend, or modify the response as required before it is actually sent to the client device.
PortletRequest
Method Summary | |
PortletURI |
createURI(Portlet.Mode mode)
Creates a portlet URI for the given portlet mode. |
PortletURI |
createURI(Portlet.Mode mode,
PortletWindow.State state)
Creates a portlet URI for the given portlet mode and given portlet window state. |
java.lang.String |
encodeNamespace(java.lang.String aValue)
Maps the given string value into this portlet's namespace. |
java.lang.String |
encodeURI(java.lang.String path)
Returns the encoded URI of the resource at the given path. |
java.io.PrintWriter |
getWriter()
Returns the writer object that can be used to contribute markup to the portlet response. |
Method Detail |
public java.io.PrintWriter getWriter() throws java.io.IOException
It is important to note that the markup generated by the portlet is either a full document or just a fragment of the markup. A corresponding setting in the deployment descriptor has to be made.
java.io.IOException
- if the I/O operation failspublic PortletURI createURI(Portlet.Mode mode)
mode
- the portlet mode
public PortletURI createURI(Portlet.Mode mode, PortletWindow.State state)
mode
- the portlet modestate
- the portlet window state
public java.lang.String encodeURI(java.lang.String path)
Returns the encoded URI of the resource at the given path. Encoding may include prefixing, conversion to absolute URL, etc.
To generate unprotected URI's like an image use the direct path inside of you portlet (e.g. /myportlet/myimage.gif). Otherwise, to generate protected URI's like an property file use the path inside of your portlet prefixed with /portlet-inf/ (e.g. /portlet-inf/myportlet/myportlet.jsp)
path
- the path to the resource
public java.lang.String encodeNamespace(java.lang.String aValue)
aValue
- the name to be mapped
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |