Java Doc for ProviderAdapter.java in  » Portal » Open-Portal » com » sun » portal » providers » 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.providers 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   com.sun.portal.providers.ProviderAdapter

All known Subclasses:   __PACKAGE__.__NAME__,  com.sun.portal.providers.portletwindowprocess.PortletWindowProcessProvider,  com.sun.portal.providers.ProfileProviderAdapter,  com.sun.portal.desktop.test.TestProvider,
ProviderAdapter
abstract public class ProviderAdapter implements Provider,ProviderWidths,ProviderEditTypes(Code)
This class provides default implementations of methods in the Provider interface implemented using a ProviderContext object as the persistent store.

Developers who wish to implement a provider should extend this class or ProfileProviderAdapter.

The advantage of extending this class versus implementing the Provider interface directly is that you will maintain forward compatability as additions are made to the Provider API. Existing code will by default call the methods in this class. Eventually, code should be written to implement all of the methods in the Provider interface.

For method details, see the descriptions in the Provider interface.
See Also:   com.sun.portal.providers.context.ProviderContext
See Also:   com.sun.portal.providers.Provider





Method Summary
 StringgetClientTypeProperty(String propertyName)
     This method has package-scope and is used here and in ProfileProviderAdapter for retrieving property values based on the session's clientType.
public  StringBuffergetContent(HttpServletRequest request, HttpServletResponse response)
     Calls the getContent(Map) method in this object to provide backwards compatibility.

The implementation of this method provides backwards compatibility for providers that only implement the deprecated getContent(Map) method.

public  StringBuffergetContent(Map m)
     This method has no effect.
public  StringgetDescription()
     Gets the description for the channel.
public  StringBuffergetEdit(HttpServletRequest request, HttpServletResponse response)
     Calls the getEdit(Map) method in this object to provide backwards compatibility. The implementation of this method provides backwards compatibility for providers that only implement the deprecated getEdit(Map) method.
public  StringBuffergetEdit(Map m)
     This method has no effect.
public  intgetEditType()
     Gets the edit type for the channel.
public  URLgetHelp(HttpServletRequest req, String key)
     Gets the named help URL for the channel that this object is providing an environment for. The request object parameter is included to facilitate implementations. It can be used to get the server name, port, and protocol.
public  URLgetHelp(HttpServletRequest req)
     Gets the default help URL for the channel that this object is providing an environment for.
public  StringgetName()
    
public  ProviderContextgetProviderContext()
     Gets the ProviderContext for the provider.
public  longgetRefreshTime()
     Gets the refresh time for the channel.
public  ResourceBundlegetResourceBundle(String base)
     Gets a specified ResourceBundle file for the provider based on User's locale.

A provider can specify on-screen strings to be localized in a resource bundle file, as described in the Java ResourceBundle class.
Parameters:
  base - a specified ResourceBundle name.
See Also:    java.util.ResourceBundle.

public  ResourceBundlegetResourceBundle()
     Gets the well-knowned ResourceBundle for the provider based on User's locale.
public  StringgetTitle()
     Gets the title for the channel.
public  intgetWidth()
     Gets the width for the channel that this is providing an environment for.
public  voidinit(String n, HttpServletRequest req)
    
public  booleanisEditable()
     Gets if the channel is editable.
public  booleanisPresentable()
    

Dictates whether the provider is presentable.

public  booleanisPresentable(HttpServletRequest req)
    

Dictates whether the provider is presentable.

Searches for the key genericHTML with the value true on the client data for the session's client type and returns true.

If there is no such key, method will return true if the session's client type is named genericHTML.

In both cases, the content-type for the session's client type must equal text/html in order for the method to return true.
Parameters:
  request - An HttpServletRequest that containsthe request the client made of the provider.

public  URLprocessEdit(HttpServletRequest request, HttpServletResponse response)
     Calls the processEdit(Map) method in this object to provide backwards compatibility.

The implementation of this method provides backwards compatibility for providers that only implement the deprecated processEdit(Map) method.

public  URLprocessEdit(Map m)
     This method has no effect.



Method Detail
getClientTypeProperty
String getClientTypeProperty(String propertyName) throws ProviderException(Code)
This method has package-scope and is used here and in ProfileProviderAdapter for retrieving property values based on the session's clientType.
Parameters:
  propertyName - client property name The client property value
exception:
  ClientException - When propertyName is null or when there was an exceptiongetting the client property.



getContent
public StringBuffer getContent(HttpServletRequest request, HttpServletResponse response) throws ProviderException(Code)
Calls the getContent(Map) method in this object to provide backwards compatibility.

The implementation of this method provides backwards compatibility for providers that only implement the deprecated getContent(Map) method. It logs a warning informing the administrator that calling this method has performance implications, and that it should be re-implemented using the non-deprecated version of this method.

Each time this method is called, the HTTP parameter data in the request object must be converted to the Map form that is accepted by the getContent(Map) version of this method.




getContent
public StringBuffer getContent(Map m) throws ProviderException(Code)
This method has no effect. null, always.



getDescription
public String getDescription() throws ProviderException(Code)
Gets the description for the channel. A string description.
exception:
  ProviderException - if error occurs when getting the descriptionof the channel.



getEdit
public StringBuffer getEdit(HttpServletRequest request, HttpServletResponse response) throws ProviderException(Code)
Calls the getEdit(Map) method in this object to provide backwards compatibility. The implementation of this method provides backwards compatibility for providers that only implement the deprecated getEdit(Map) method. It logs a warning informing the administrator that calling this method has performance implications, and that it should be re-implemented using the non-deprecated version of this method. Each time this method is called, the HTTP parameter data in the request object must be converted to the Map form that is accepted by the getEdit(Map) version of this method.



getEdit
public StringBuffer getEdit(Map m) throws ProviderException(Code)
This method has no effect. null, always.



getEditType
public int getEditType() throws UnknownEditTypeException(Code)
Gets the edit type for the channel. The edit type for a channel informs clients of the channel (such as a container channel) what sort of content to be returned for its edit view; either a fragment or a complete document. The edit type; either EDIT_COMPLETE or EDIT_SUBSET.
exception:
  UnknownEditTypeException - if an error occurs when getting theedit type of the channel.
See Also:   com.sun.portal.providers.ProviderEditTypes



getHelp
public URL getHelp(HttpServletRequest req, String key) throws ProviderException(Code)
Gets the named help URL for the channel that this object is providing an environment for. The request object parameter is included to facilitate implementations. It can be used to get the server name, port, and protocol. These can be used to transform a relative URL to absolute. It is not required that the request object be used as such. If the named help page is not supported, then the default help URL is returned (see getHelp(HttpServletRequest)).
Parameters:
  key - Key name that maps to a help URL.
Parameters:
  req - Request object containing information for buildingthe URL. A URL object.
exception:
  ProviderException - If there was an error constructing theURL.



getHelp
public URL getHelp(HttpServletRequest req) throws ProviderException(Code)
Gets the default help URL for the channel that this object is providing an environment for. This method must return an absolute URL. The request object parameter is included to facilitate implementations. It can be used to get the server name, port, and protocol. These can be used to transform a relative URL to absolute. It is not required that the request object be used as such.
Parameters:
  req - Request object containing information for buildingthe URL. URL object that points to the channel's help page.
exception:
  ProviderException - If there was an error constructing theURL.
See Also:   ProviderAdapter.getHelp(HttpServletRequest)



getName
public String getName()(Code)
The name of the provider, as it was passed in to the init()method.



getProviderContext
public ProviderContext getProviderContext()(Code)
Gets the ProviderContext for the provider. ProviderContext.
See Also:   com.sun.portal.providers.context.ProviderContext



getRefreshTime
public long getRefreshTime() throws ProviderException(Code)
Gets the refresh time for the channel. The refresh time for a channel is used to allow containers to implement caching of content for their contained channels. This value is used to indicate the validity of the cached content. >0, refresh time in number of seconds that a container shouldwait before expiring a content cache.0, container should never cache channel's content.-1, container may cache channel's content indefinitely.
exception:
  ProviderException - If there was an error getting the refreshtime for the channel.



getResourceBundle
public ResourceBundle getResourceBundle(String base) throws ProviderException(Code)
Gets a specified ResourceBundle file for the provider based on User's locale.

A provider can specify on-screen strings to be localized in a resource bundle file, as described in the Java ResourceBundle class.
Parameters:
  base - a specified ResourceBundle name.
See Also:    java.util.ResourceBundle. ResourceBundle.




getResourceBundle
public ResourceBundle getResourceBundle() throws ProviderException(Code)
Gets the well-knowned ResourceBundle for the provider based on User's locale.

A provider can specify on-screen strings to be localized in a resource bundle file, as described in the Java ResourceBundle class.

The well-knowned name is the provider name. ResourceBundle.




getTitle
public String getTitle() throws ProviderException(Code)
Gets the title for the channel. A string title.
exception:
  ProviderException - if error occurs when getting the title forthe channel.



getWidth
public int getWidth() throws ProviderException(Code)
Gets the width for the channel that this is providing an environment for. The channel width is used as a suggestion to the container of the channel as to how much screen real estate it requires. The width; either WIDTH_THIN, WIDTH_THICK,WIDTH_FULL_TOP, or WIDTH_FULL_BOTTOM.
exception:
  ProviderException - If there was an error getting the widthof the channel.
See Also:   com.sun.portal.providers.ProviderWidths



init
public void init(String n, HttpServletRequest req) throws ProviderException(Code)



isEditable
public boolean isEditable() throws ProviderException(Code)
Gets if the channel is editable. If a provider is editable, it is capable of providing an edit view to clients. true if the channel is editable, otherwisefalse.
exception:
  ProviderException - if error occurs when getting if the channelis editable.



isPresentable
public boolean isPresentable()(Code)

Dictates whether the provider is presentable.

Searches for the key genericHTML with the value true on the client data for the session's client type and returns true.

If there is no such key, method will return true if the session's client type is named genericHTML.

In both cases, the content-type for the session's client type must equal text/html in order for the method to return true. A boolean value dictating presentability
See Also:   com.sun.portal.providers.Provider.isPresentable




isPresentable
public boolean isPresentable(HttpServletRequest req)(Code)

Dictates whether the provider is presentable.

Searches for the key genericHTML with the value true on the client data for the session's client type and returns true.

If there is no such key, method will return true if the session's client type is named genericHTML.

In both cases, the content-type for the session's client type must equal text/html in order for the method to return true.
Parameters:
  request - An HttpServletRequest that containsthe request the client made of the provider. A boolean value dictating presentability
See Also:   com.sun.portal.providers.Provider.isPresentable




processEdit
public URL processEdit(HttpServletRequest request, HttpServletResponse response) throws ProviderException(Code)
Calls the processEdit(Map) method in this object to provide backwards compatibility.

The implementation of this method provides backwards compatibility for providers that only implement the deprecated processEdit(Map) method. It logs a warning informing the administrator that calling this method has performance implications, and that it should be re-implemented using the non-deprecated version of this method.

Each time this method is called, the HTTP parameter data in the request object must be converted to the Map form that is accepted by the processEdit(Map) version of this method.




processEdit
public URL processEdit(Map m) throws ProviderException(Code)
This method has no effect. null, always



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.