Java Doc for CPortletAdapter.java in  » Portal » uPortal_rel-2-6-1-GA » org » jasig » portal » channels » portlet » 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 » uPortal_rel 2 6 1 GA » org.jasig.portal.channels.portlet 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.jasig.portal.channels.portlet.CPortletAdapter

CPortletAdapter
public class CPortletAdapter implements ICharacterChannel,IPrivileged,ICacheable,IDirectResponse,IPortletAdaptor(Code)
A JSR 168 Portlet adapter that presents a portlet through the uPortal channel interface.

There is a related channel type called "Portlet Adapter" that is included with uPortal, so to use this channel, just select the "Portlet" type when publishing.

Note: A portlet can specify the String "password" in the user attributes section of the portlet.xml. In this is done, this adapter will look for the user's cached password. If the user's password is being stored in memory by a caching security context, the adapter will consult the cache to fill the request for the attribute. If the user's password is not cached, null will be set for the attributes value.


author:
   Ken Weiner, kweiner@unicon.net
version:
   $Revision: 42658 $


Field Summary
final protected  Loglog
    
final public static  StringportletPreferenceNamePrefix
    


Method Summary
public  ChannelCacheKeygenerateKey()
     Generates a channel cache key.
protected synchronized  StringgetMarkup()
     This is where we do the real work of getting the markup.
public  ChannelRuntimePropertiesgetRuntimeProperties()
     Sets channel runtime properties.
protected  MapgetUserInfo(ChannelStaticData staticData, UserAttributeListImpl userAttributes)
     Get the Map of portlet user attribute names to portlet user attribute values. This is an extension point.
protected  voidinitPortletWindow()
    
public  booleanisCacheValid(Object validity)
     Determines whether the cached content for this channel is still valid.
public  voidreceiveEvent(PortalEvent ev)
     React to portal events.
public  voidrenderCharacters(PrintWriter pw)
    
public  voidrenderXML(ContentHandler out)
     Output channel content to the portal.
public  voidsetPortalControlStructures(PortalControlStructures pcs1)
     Sets the portal control structures.
public synchronized  voidsetResponse(HttpServletResponse response)
    
public  voidsetRuntimeData(ChannelRuntimeData rd)
     Sets the channel runtime data.
public static  voidsetServletConfig(ServletConfig config)
     Receive the servlet config from uPortal's PortalSessionManager servlet.
public  voidsetStaticData(ChannelStaticData sd)
     Sets the channel static data.
protected  voidsetupRequestAttributes(HttpServletRequest request)
     Adds the appropriate information to the request attributes of the portlet. This is an extension point.

Field Detail
log
final protected Log log(Code)



portletPreferenceNamePrefix
final public static String portletPreferenceNamePrefix(Code)





Method Detail
generateKey
public ChannelCacheKey generateKey()(Code)
Generates a channel cache key. The key scope is currently set to be instance-wide. the channel cache key



getMarkup
protected synchronized String getMarkup() throws PortalException(Code)
This is where we do the real work of getting the markup. This is called from both renderXML() and renderCharacters(). markup representing channel content



getRuntimeProperties
public ChannelRuntimeProperties getRuntimeProperties()(Code)
Sets channel runtime properties. channel runtime properties



getUserInfo
protected Map getUserInfo(ChannelStaticData staticData, UserAttributeListImpl userAttributes)(Code)
Get the Map of portlet user attribute names to portlet user attribute values. This is an extension point. You can extend CPortletAdapter and override this method to implement the particular user attribute Map creation strategy that you need to implement. Such strategies might rename uPortal user attributes to names that your particular portlet knows how to consume, transform the user attribute values to forms expected by your portlet, add additional attributes, convey a CAS proxy ticket or other security token. This extension point is the way to accomodate the particular user attributes particular portlets require. The default implementation of this method includes in the userInfo Map those uPortal IPerson attributes matching entries in the list of attributes the Portlet declared it wanted. Additionally, the default implementation copies the cached user password if the Portlet declares it wants the user attribute 'password'.
Parameters:
  staticData - data associated with the particular instance of the portlet window for the particularuser session
Parameters:
  userAttributes - the user attributes requested by the Portlet a Map from portlet user attribute names to portlet user attribute values.



initPortletWindow
protected void initPortletWindow() throws PortalException(Code)



isCacheValid
public boolean isCacheValid(Object validity)(Code)
Determines whether the cached content for this channel is still valid.

Return true when:

  1. We have not just received an event
  2. No runtime parameters are sent to the channel
  3. The focus hasn't switched.
Otherwise, return false.

In other words, cache the content in all cases except for when a user clicks a channel button, a link or form button within the channel, or the focus or unfocus button.
Parameters:
  validity - the validity object true if the cache is still valid, otherwise false




receiveEvent
public void receiveEvent(PortalEvent ev)(Code)
React to portal events. Removes channel state from the channel state map when the session expires.
Parameters:
  ev - a portal event



renderCharacters
public void renderCharacters(PrintWriter pw) throws PortalException(Code)
Output channel content to the portal as raw characters
Parameters:
  pw - a print writer



renderXML
public void renderXML(ContentHandler out) throws PortalException(Code)
Output channel content to the portal. This version of the render method is normally not used since this is a "character channel".
Parameters:
  out - a sax document handler



setPortalControlStructures
public void setPortalControlStructures(PortalControlStructures pcs1) throws PortalException(Code)
Sets the portal control structures.
Parameters:
  pcs1 - the portal control structures
throws:
  org.jasig.portal.PortalException -



setResponse
public synchronized void setResponse(HttpServletResponse response)(Code)



setRuntimeData
public void setRuntimeData(ChannelRuntimeData rd) throws PortalException(Code)
Sets the channel runtime data.
Parameters:
  rd - the channel runtime data
throws:
  org.jasig.portal.PortalException -



setServletConfig
public static void setServletConfig(ServletConfig config)(Code)
Receive the servlet config from uPortal's PortalSessionManager servlet. Pluto needs access to this object from serveral places.
Parameters:
  config - the servlet config



setStaticData
public void setStaticData(ChannelStaticData sd) throws PortalException(Code)
Sets the channel static data.
Parameters:
  sd - the channel static data
throws:
  org.jasig.portal.PortalException -



setupRequestAttributes
protected void setupRequestAttributes(HttpServletRequest request)(Code)
Adds the appropriate information to the request attributes of the portlet. This is an extension point. You can override this method to set other request attributes.
Parameters:
  request - The request to add the attributes to



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.