001: /*
002: * Copyright 2002 Sun Microsystems, Inc. All
003: * rights reserved. Use of this product is subject
004: * to license terms. Federal Acquisitions:
005: * Commercial Software -- Government Users
006: * Subject to Standard License Terms and
007: * Conditions.
008: *
009: * Sun, Sun Microsystems, the Sun logo, and Sun ONE
010: * are trademarks or registered trademarks of Sun Microsystems,
011: * Inc. in the United States and other countries.
012: */
013:
014: package com.sun.portal.portletcontainercommon;
015:
016: import com.sun.portal.container.ExecuteActionResponse;
017: import com.sun.portal.container.WindowState;
018: import com.sun.portal.container.ChannelMode;
019:
020: import java.util.Map;
021: import java.net.URL;
022:
023: public class PortletContainerActionResponse extends
024: PortletContainerResponse {
025:
026: private ExecuteActionResponse _res;
027: private Map _renderParameters;
028: private URL _redirectURL;
029: private WindowState _windowState;
030: private ChannelMode _channelMode;
031:
032: public PortletContainerActionResponse(ExecuteActionResponse res) {
033: super (res);
034: _res = res;
035: }
036:
037: /**
038: * Returns the URL the portal server should redirect to.
039: *
040: * @return redirect URL
041: **/
042: public URL getRedirectURL() {
043: return _redirectURL;
044: }
045:
046: /**
047: * Sets the URL the portal server should redirect to.
048: *
049: * @return redirect URL
050: **/
051: public void setRedirectURL(URL redirectURL) {
052: _redirectURL = redirectURL;
053: _res.setRedirectURL(redirectURL);
054: }
055:
056: /**
057: * Returns the new window state of the channel.
058: *
059: * @return new window state
060: **/
061: public WindowState getNewWindowState() {
062: return _windowState;
063: }
064:
065: /**
066: * Sets the new window state of the channel.
067: *
068: * @param newWindowState the new window state to be set to
069: */
070: public void setNewWindowState(WindowState newWindowState) {
071: _windowState = newWindowState;
072: _res.setNewWindowState(newWindowState);
073: }
074:
075: /**
076: * Returns the new mode of the channel.
077: *
078: * @return the new channel mode
079: **/
080: public ChannelMode getNewChannelMode() {
081: return _channelMode;
082: }
083:
084: /**
085: * Sets the new mode of the channel.
086: *
087: * @param newChannelMode the new channel mode to be set to
088: */
089: public void setNewChannelMode(ChannelMode newChannelMode) {
090: _channelMode = newChannelMode;
091: _res.setNewChannelMode(newChannelMode);
092: }
093:
094: /**
095: * Set the render parameters map. Portlet container may use this API to
096: * set the render parameters for the future rendering.
097: *
098: * @param the render parameters map
099: **/
100: public void setRenderParameters(Map renderParameters) {
101: _renderParameters = renderParameters;
102: _res.setRenderParameters(renderParameters);
103: }
104:
105: /**
106: * Returns a <code>Map</code> of the render parameters.
107: *
108: * @return the render parameters map.
109: **/
110: public Map getRenderParameters() {
111: return _renderParameters;
112: }
113:
114: }
|