View Javadoc

1   /*
2    * Copyright 2001-2004 The Apache Software Foundation.
3    * 
4    * Licensed under the Apache License, Version 2.0 (the "License");
5    * you may not use this file except in compliance with the License.
6    * You may obtain a copy of the License at
7    * 
8    *      http://www.apache.org/licenses/LICENSE-2.0
9    * 
10   * Unless required by applicable law or agreed to in writing, software
11   * distributed under the License is distributed on an "AS IS" BASIS,
12   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13   * See the License for the specific language governing permissions and
14   * limitations under the License.
15   */
16  package org.portletbridge.portlet;
17  
18  import java.io.Serializable;
19  import java.net.URI;
20  
21  /***
22   * Default implementation fo the BridgeRequest
23   * 
24   * @author jmccrindle
25   */
26  public class DefaultBridgeRequest implements Serializable, BridgeRequest {
27      
28      /***
29       * default serial version id 
30       */
31      private static final long serialVersionUID = 4504756989609725196L;
32  
33      private String id = null;
34      private String portletId = null;
35      private String pageUrl = null;
36      private URI url = null;
37      
38      public DefaultBridgeRequest() {
39          
40      }
41      
42      /***
43       * Create a new BridgeRequest
44       * 
45       * @param id the id of the bridge request
46       * @param portletId the portletId for the portlet instance (usually the portlet namespace)
47       * @param pageUrl the portlet url to redirect to 
48       * @param url the url of the downstream site.
49       */
50      public DefaultBridgeRequest(String id, String portletId, String pageUrl, URI url) {
51          super();
52          this.id = id;
53          this.portletId = portletId;
54          this.pageUrl = pageUrl;
55          this.url = url;
56      }
57      
58      public String getPageUrl() {
59          return pageUrl;
60      }
61      public void setPageUrl(String pageUrl) {
62          this.pageUrl = pageUrl;
63      }
64      public String getPortletId() {
65          return portletId;
66      }
67      public void setPortletId(String portletId) {
68          this.portletId = portletId;
69      }
70      public URI getUrl() {
71          return url;
72      }
73      public void setUrl(URI url) {
74          this.url = url;
75      }
76  
77      public String getId() {
78          return id;
79      }
80  
81  }