Source Code Cross Referenced for DesktopPortletRequest.java in  » Portal » Open-Portal » com » sun » portal » desktop » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Portal » Open Portal » com.sun.portal.desktop 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        package com.sun.portal.desktop;
002:
003:        import java.util.*;
004:        import java.util.logging.Logger;
005:        import java.util.logging.Level;
006:        import java.text.*;
007:        import java.net.*;
008:        import java.io.*;
009:        import javax.servlet.*;
010:        import javax.servlet.http.*;
011:
012:        import com.sun.portal.desktop.context.DesktopAppContext;
013:        import com.sun.portal.desktop.util.I18n;
014:        import com.sun.portal.desktop.util.NSStringBuffer;
015:        import com.sun.portal.desktop.util.PIParser;
016:        import com.sun.portal.log.common.PortalLogger;
017:
018:        /**
019:         * A DesktopRequest encapsulates the HttpServletRequest that is passed
020:         * to the provider, hiding and redefining those methods that are
021:         * inappropriate to be called by a provider.
022:         */
023:
024:        public class DesktopPortletRequest implements  HttpServletRequest {
025:            private DesktopRequest dreq;
026:            private Hashtable portletParams;
027:
028:            public DesktopPortletRequest(DesktopRequest request,
029:                    Hashtable portletParams) {
030:                dreq = request;
031:                this .portletParams = portletParams;
032:            }
033:
034:            /* HttpServletRequest methods */
035:
036:            public Map getParameterMap() {
037:                return portletParams;
038:            }
039:
040:            public String getAuthType() {
041:                return dreq.getAuthType();
042:            }
043:
044:            public String getContextPath() {
045:                return dreq.getContextPath();
046:            }
047:
048:            public Cookie[] getCookies() {
049:                return dreq.getCookies();
050:            }
051:
052:            public long getDateHeader(String name) {
053:                return dreq.getDateHeader(name);
054:            }
055:
056:            public String getHeader(String name) {
057:                return dreq.getHeader(name);
058:            }
059:
060:            public Enumeration getHeaderNames() {
061:                return dreq.getHeaderNames();
062:            }
063:
064:            public Enumeration getHeaders(String name) {
065:                return dreq.getHeaders(name);
066:            }
067:
068:            public int getIntHeader(String name) {
069:                return dreq.getIntHeader(name);
070:            }
071:
072:            public String getMethod() {
073:                return dreq.getMethod();
074:            }
075:
076:            public String getPathInfo() {
077:                return dreq.getPathInfo();
078:            }
079:
080:            public String getPathTranslated() {
081:                return dreq.getPathTranslated();
082:            }
083:
084:            public String getQueryString() {
085:                return dreq.getQueryString();
086:            }
087:
088:            public String getRemoteUser() {
089:                return dreq.getRemoteUser();
090:            }
091:
092:            public String getRequestedSessionId() {
093:                return dreq.getRequestedSessionId();
094:            }
095:
096:            public String getRequestURI() {
097:                return dreq.getRequestURI();
098:            }
099:
100:            public String getServletPath() {
101:                return dreq.getServletPath();
102:            }
103:
104:            public HttpSession getSession() {
105:                return dreq.getSession();
106:            }
107:
108:            public HttpSession getSession(boolean create) {
109:                return dreq.getSession(create);
110:            }
111:
112:            public java.security.Principal getUserPrincipal() {
113:                return dreq.getUserPrincipal();
114:            }
115:
116:            public boolean isRequestedSessionIdFromCookie() {
117:                return dreq.isRequestedSessionIdFromCookie();
118:            }
119:
120:            /**
121:             * @deprecated
122:             */
123:            public boolean isRequestedSessionIdFromUrl() {
124:                return dreq.isRequestedSessionIdFromUrl();
125:            }
126:
127:            public boolean isRequestedSessionIdFromURL() {
128:                return dreq.isRequestedSessionIdFromURL();
129:            }
130:
131:            public boolean isRequestedSessionIdValid() {
132:                return dreq.isRequestedSessionIdValid();
133:            }
134:
135:            public boolean isUserInRole(String role) {
136:                return dreq.isUserInRole(role);
137:            }
138:
139:            /* ServletRequest methods */
140:
141:            public Object getAttribute(String name) {
142:                return dreq.getAttribute(name);
143:            }
144:
145:            public Enumeration getAttributeNames() {
146:                return dreq.getAttributeNames();
147:            }
148:
149:            public String getCharacterEncoding() {
150:                return dreq.getCharacterEncoding();
151:            }
152:
153:            public int getContentLength() {
154:                return dreq.getContentLength();
155:            }
156:
157:            public String getContentType() {
158:                return dreq.getContentType();
159:            }
160:
161:            public ServletInputStream getInputStream() throws IOException {
162:                return dreq.getInputStream();
163:            }
164:
165:            public Locale getLocale() {
166:                return dreq.getLocale();
167:            }
168:
169:            public Enumeration getLocales() {
170:                return dreq.getLocales();
171:            }
172:
173:            public String getParameter(String name) {
174:                String values[] = (String[]) portletParams.get(name);
175:                if (values != null && values.length >= 1) {
176:                    return values[0];
177:                }
178:                return null;
179:            }
180:
181:            public Enumeration getParameterNames() {
182:                return portletParams.keys();
183:            }
184:
185:            public String[] getParameterValues(String name) {
186:                return (String[]) portletParams.get(name);
187:            }
188:
189:            public String getProtocol() {
190:                return dreq.getProtocol();
191:            }
192:
193:            public synchronized BufferedReader getReader() throws IOException {
194:                return dreq.getReader();
195:            }
196:
197:            /**
198:             * @deprecated As of Version 2.1 of the Java Servlet API, use ServletContext.getRealPath(String) instead.
199:             */
200:            public String getRealPath(String path) {
201:                return dreq.getRealPath(path);
202:
203:            }
204:
205:            public String getRemoteAddr() {
206:                return dreq.getRemoteAddr();
207:            }
208:
209:            public String getRemoteHost() {
210:                return dreq.getRemoteHost();
211:            }
212:
213:            public RequestDispatcher getRequestDispatcher(String path) {
214:                return dreq.getRequestDispatcher(path);
215:            }
216:
217:            public String getScheme() {
218:                return dreq.getScheme();
219:            }
220:
221:            public String getServerName() {
222:                return dreq.getServerName();
223:            }
224:
225:            public int getServerPort() {
226:                return dreq.getServerPort();
227:            }
228:
229:            public boolean isSecure() {
230:                return dreq.isSecure();
231:            }
232:
233:            public void removeAttribute(String name) {
234:                dreq.removeAttribute(name);
235:            }
236:
237:            public void setAttribute(String name, Object o) {
238:                dreq.setAttribute(name, o);
239:            }
240:
241:            /*   
242:             * Added as part of upgradation to servlet2.3 spec 
243:             */
244:
245:            public StringBuffer getRequestURL() {
246:                return dreq.getRequestURL();
247:            }
248:
249:            public void setCharacterEncoding(String env)
250:                    throws UnsupportedEncodingException {
251:                dreq.setCharacterEncoding(env);
252:            }
253:
254:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.