Return-Path: Delivered-To: apmail-portals-pluto-scm-archive@www.apache.org Received: (qmail 20545 invoked from network); 2 Nov 2008 22:20:30 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 2 Nov 2008 22:20:30 -0000 Received: (qmail 92454 invoked by uid 500); 2 Nov 2008 22:20:36 -0000 Delivered-To: apmail-portals-pluto-scm-archive@portals.apache.org Received: (qmail 92429 invoked by uid 500); 2 Nov 2008 22:20:36 -0000 Mailing-List: contact pluto-scm-help@portals.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: List-Id: Delivered-To: mailing list pluto-scm@portals.apache.org Received: (qmail 92420 invoked by uid 99); 2 Nov 2008 22:20:36 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 02 Nov 2008 14:20:36 -0800 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 02 Nov 2008 22:19:24 +0000 Received: by eris.apache.org (Postfix, from userid 65534) id 5AE5C2388AEF; Sun, 2 Nov 2008 14:19:12 -0800 (PST) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r709960 [13/23] - in /portals/pluto/branches/2.0-spi-refactoring/src/site/resources/portlet-2.0-apidocs: ./ index-files/ javax/portlet/ javax/portlet/class-use/ javax/portlet/filter/ javax/portlet/listener/ Date: Sun, 02 Nov 2008 22:19:09 -0000 To: pluto-scm@portals.apache.org From: ate@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20081102221912.5AE5C2388AEF@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Added: portals/pluto/branches/2.0-spi-refactoring/src/site/resources/portlet-2.0-apidocs/javax/portlet/PortletConfig.html URL: http://svn.apache.org/viewvc/portals/pluto/branches/2.0-spi-refactoring/src/site/resources/portlet-2.0-apidocs/javax/portlet/PortletConfig.html?rev=709960&view=auto ============================================================================== --- portals/pluto/branches/2.0-spi-refactoring/src/site/resources/portlet-2.0-apidocs/javax/portlet/PortletConfig.html (added) +++ portals/pluto/branches/2.0-spi-refactoring/src/site/resources/portlet-2.0-apidocs/javax/portlet/PortletConfig.html Sun Nov 2 14:19:07 2008 @@ -0,0 +1,578 @@ + + + + + + +PortletConfig + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + +
+ +

+ +javax.portlet +
+Interface PortletConfig

+
+
All Known Implementing Classes:
GenericPortlet
+
+
+
+
public interface PortletConfig
+ + +

+The PortletConfig interface provides the portlet with + its configuration. The configuration holds information about the + portlet that is valid for all users. The configuration is retrieved + from the portlet definition in the deployment descriptor. + The portlet can only read the configuration data. +

+ The configuration information contains the portlet name, the portlet + initialization parameters, the portlet resource bundle and the portlet + application context. +

+ +

+

+
See Also:
Portlet
+
+ +

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+Method Summary
+ java.util.Map<java.lang.String,java.lang.String[]>getContainerRuntimeOptions() + +
+          Returns the container runtime options + and values for this portlet.
+ java.lang.StringgetDefaultNamespace() + +
+          Returns the default namespace for events and public render parameters.
+ java.lang.StringgetInitParameter(java.lang.String name) + +
+          Returns a String containing the value of the named initialization parameter, + or null if the parameter does not exist.
+ java.util.Enumeration<java.lang.String>getInitParameterNames() + +
+          Returns the names of the portlet initialization parameters as an + Enumeration of String objects, or an empty Enumeration if the + portlet has no initialization parameters.
+ PortletContextgetPortletContext() + +
+          Returns the PortletContext of the portlet application + the portlet is in.
+ java.lang.StringgetPortletName() + +
+          Returns the name of the portlet.
+ java.util.Enumeration<javax.xml.namespace.QName>getProcessingEventQNames() + +
+          Returns the QNames of the processing events supported by the portlet + as an Enumeration of QName objects, + or an empty Enumeration if the + portlet has not defined any processing events.
+ java.util.Enumeration<java.lang.String>getPublicRenderParameterNames() + +
+          Returns the names of the public render parameters supported by the portlet + as an Enumeration of String objects, + or an empty Enumeration if the + portlet has not defined public render parameters.
+ java.util.Enumeration<javax.xml.namespace.QName>getPublishingEventQNames() + +
+          Returns the QNames of the publishing events supported by the portlet + as an Enumeration of QName objects, + or an empty Enumeration if the + portlet has not defined any publishing events.
+ java.util.ResourceBundlegetResourceBundle(java.util.Locale locale) + +
+          Gets the resource bundle for the given locale based on the + resource bundle defined in the deployment descriptor + with resource-bundle tag or the inlined resources + defined in the deployment descriptor.
+ java.util.Enumeration<java.util.Locale>getSupportedLocales() + +
+          Returns the locales supported by the portlet + as an Enumeration of Locale objects, + or an empty Enumeration if the + portlet has not defined any supported locales.
+  +

+ + + + + + + + +
+Method Detail
+ +

+getPortletName

+
+java.lang.String getPortletName()
+
+
Returns the name of the portlet. +

+ The name may be provided via server administration, assigned in the + portlet application deployment descriptor with the portlet-name + tag. +

+

+ +
Returns:
the portlet name
+
+
+
+ +

+getPortletContext

+
+PortletContext getPortletContext()
+
+
Returns the PortletContext of the portlet application + the portlet is in. +

+

+ +
Returns:
a PortletContext object, used by the + caller to interact with its portlet container
See Also:
PortletContext
+
+
+
+ +

+getResourceBundle

+
+java.util.ResourceBundle getResourceBundle(java.util.Locale locale)
+
+
Gets the resource bundle for the given locale based on the + resource bundle defined in the deployment descriptor + with resource-bundle tag or the inlined resources + defined in the deployment descriptor. +

+

+
Parameters:
locale - the locale for which to retrieve the resource bundle +
Returns:
the resource bundle for the given locale
+
+
+
+ +

+getInitParameter

+
+java.lang.String getInitParameter(java.lang.String name)
+
+
Returns a String containing the value of the named initialization parameter, + or null if the parameter does not exist. +

+

+
Parameters:
name - a String specifying the name + of the initialization parameter +
Returns:
a String containing the value + of the initialization parameter +
Throws: +
java.lang.IllegalArgumentException - if name is null.
+
+
+
+ +

+getInitParameterNames

+
+java.util.Enumeration<java.lang.String> getInitParameterNames()
+
+
Returns the names of the portlet initialization parameters as an + Enumeration of String objects, or an empty Enumeration if the + portlet has no initialization parameters. +

+

+ +
Returns:
an Enumeration of String + objects containing the names of the portlet + initialization parameters, or an empty Enumeration if the + portlet has no initialization parameters.
+
+
+
+ +

+getPublicRenderParameterNames

+
+java.util.Enumeration<java.lang.String> getPublicRenderParameterNames()
+
+
Returns the names of the public render parameters supported by the portlet + as an Enumeration of String objects, + or an empty Enumeration if the + portlet has not defined public render parameters. +

+ Public render parameters are defined in the portlet deployment descriptor + with the supported-public-render-parameter element. +

+

+ +
Returns:
an Enumeration of String + objects containing the names of the public + render parameters, or an empty Enumeration if the + portlet has not defined support for any public render parameters + in the portlet deployment descriptor.
Since:
+
2.0
+
+
+
+
+ +

+getDefaultNamespace

+
+java.lang.String getDefaultNamespace()
+
+
Returns the default namespace for events and public render parameters. + This namespace is defined in the portlet deployment descriptor + with the default-namespace element. +

+ If no default namespace is defined in the portlet deployment + descriptor this methods returns the XML default namespace + XMLConstants.NULL_NS_URI. +

+

+ +
Returns:
the default namespace defined in the portlet deployment + descriptor, or XMLConstants.NULL_NS_URI is non is + defined.
Since:
+
2.0
+
+
+
+
+ +

+getPublishingEventQNames

+
+java.util.Enumeration<javax.xml.namespace.QName> getPublishingEventQNames()
+
+
Returns the QNames of the publishing events supported by the portlet + as an Enumeration of QName objects, + or an empty Enumeration if the + portlet has not defined any publishing events. +

+ Publishing events are defined in the portlet deployment descriptor + with the supported-publishing-event element. +

+ Note that this call does not return any events published that have not been + declared in the deployment descriptor as supported. +

+ If the event was defined using the name element instead of + the qname element the defined default namespace + is added as namespace for the returned QName. +

+

+ +
Returns:
an Enumeration of QName + objects containing the names of the publishing events, + or an empty Enumeration if the + portlet has not defined any support for publishing events in + the deployment descriptor.
Since:
+
2.0
+
+
+
+
+ +

+getProcessingEventQNames

+
+java.util.Enumeration<javax.xml.namespace.QName> getProcessingEventQNames()
+
+
Returns the QNames of the processing events supported by the portlet + as an Enumeration of QName objects, + or an empty Enumeration if the + portlet has not defined any processing events. +

+ Processing events are defined in the portlet deployment descriptor + with the supported-processing-event element. +

+ If the event was defined using the name element instead of + the qname element the defined default namespace + is added as namespace for the returned QName. +

+

+ +
Returns:
an Enumeration of QName + objects containing the names of the processing events, + or an empty Enumeration if the + portlet has not defined any support for processing events in + the deployment descriptor.
Since:
+
2.0
+
+
+
+
+ +

+getSupportedLocales

+
+java.util.Enumeration<java.util.Locale> getSupportedLocales()
+
+
Returns the locales supported by the portlet + as an Enumeration of Locale objects, + or an empty Enumeration if the + portlet has not defined any supported locales. +

+ Supported locales are defined in the portlet deployment descriptor + with the supported-locale element. +

+

+ +
Returns:
an Enumeration of Locale + objects containing the supported locales, + or an empty Enumeration if the + portlet has not defined any supported locales in + the deployment descriptor.
Since:
+
2.0
+
+
+
+
+ +

+getContainerRuntimeOptions

+
+java.util.Map<java.lang.String,java.lang.String[]> getContainerRuntimeOptions()
+
+
Returns the container runtime options + and values for this portlet. +

+ The portlet can set container runtime + options in the portlet.xml via the + container-runtime-option element with a name and a + value on the application and portlet level.
+ If a container runtime option is set on the portlet application + level and on the portlet level with the same name the setting + on the portlet level takes precedence and overwrites the one + set on the portal application level. +

+ The map returned from this method will provide the subset the + portlet container supports of the options the portlet has specified + in the portlet.xml. Options that the portlet container + does not support will not be returned in this map. +

+ The map will contain name of the runtime option as key of type String + and the runtime options as values of type String array (String[]) + with the values specified in the portlet.xml deployment descriptor. +

+

+ +
Returns:
an immutable Map containing portlet + container runtime options names as keys and the + container runtime values as map values, or an empty Map + if no portlet container runtime options are set + in the portlet.xml or supported by this portlet container. + The keys in the map are of type String. The values in the map are of type + String array (String[]).
Since:
+
2.0
+
+
+
+ +
+ + + + + + + + + + + + + + + + + + + +
+ +
+ + + +
+ + + Propchange: portals/pluto/branches/2.0-spi-refactoring/src/site/resources/portlet-2.0-apidocs/javax/portlet/PortletConfig.html ------------------------------------------------------------------------------ svn:keywords = Id Added: portals/pluto/branches/2.0-spi-refactoring/src/site/resources/portlet-2.0-apidocs/javax/portlet/PortletContext.html URL: http://svn.apache.org/viewvc/portals/pluto/branches/2.0-spi-refactoring/src/site/resources/portlet-2.0-apidocs/javax/portlet/PortletContext.html?rev=709960&view=auto ============================================================================== --- portals/pluto/branches/2.0-spi-refactoring/src/site/resources/portlet-2.0-apidocs/javax/portlet/PortletContext.html (added) +++ portals/pluto/branches/2.0-spi-refactoring/src/site/resources/portlet-2.0-apidocs/javax/portlet/PortletContext.html Sun Nov 2 14:19:07 2008 @@ -0,0 +1,855 @@ + + + + + + +PortletContext + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + +
+ +

+ +javax.portlet +
+Interface PortletContext

+
+
+
public interface PortletContext
+ + +

+The PortletContext interface defines a portlet view + of the portlet container. + The PortletContext also makes resources available + to the portlet. Using the context, a portlet can access + the portlet log, and obtain URL references to resources. + +

There is one context per "portlet application" per Java Virtual Machine. (A + "portlet application" is a collection of portlets, servlets, and content installed + under a specific subset of the server URL namespace, such as /catalog. + They are possibly installed via a .war file.) + As a web application, a portlet application also has a servlet context. + The portlet context leverages most of its functionality from the + servlet context of the portlet application. +

+ Attributes stored in the context are global for all users and all + components in the portlet application. +

+ In the case of a web + application marked "distributed" in its deployment descriptor, there will + be one context instance for each virtual machine. In this situation, the + context cannot be used as a location to share global information (because + the information is not truly global). Use an external resource, such as + a database to achieve sharing on a global scope. +

+ +

+


+ +

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+Method Summary
+ java.lang.ObjectgetAttribute(java.lang.String name) + +
+          Returns the portlet container attribute with the given name, + or null if there is no attribute by that name.
+ java.util.Enumeration<java.lang.String>getAttributeNames() + +
+          Returns an Enumeration containing the attribute names + available within this portlet context, or an empty + Enumeration if no attributes are available.
+ java.util.Enumeration<java.lang.String>getContainerRuntimeOptions() + +
+          Returns the container container runtime options + keys supported by this portlet container.
+ java.lang.StringgetInitParameter(java.lang.String name) + +
+          Returns a String containing the value of the named context-wide + initialization parameter, or null if the parameter does not exist.
+ java.util.Enumeration<java.lang.String>getInitParameterNames() + +
+          Returns the names of the context initialization parameters as an + Enumeration of String objects, or an empty Enumeration if the context + has no initialization parameters.
+ intgetMajorVersion() + +
+          Returns the major version of the Portlet API that this portlet + container supports.
+ java.lang.StringgetMimeType(java.lang.String file) + +
+          Returns the MIME type of the specified file, or null if + the MIME type is not known.
+ intgetMinorVersion() + +
+          Returns the minor version of the Portlet API that this portlet + container supports.
+ PortletRequestDispatchergetNamedDispatcher(java.lang.String name) + +
+          Returns a PortletRequestDispatcher object that acts + as a wrapper for the named servlet.
+ java.lang.StringgetPortletContextName() + +
+          Returns the name of this portlet application correponding to this PortletContext as specified + in the web.xml deployment descriptor for this web application by the + display-name element.
+ java.lang.StringgetRealPath(java.lang.String path) + +
+          Returns a String containing the real path + for a given virtual path.
+ PortletRequestDispatchergetRequestDispatcher(java.lang.String path) + +
+          Returns a PortletRequestDispatcher object that acts + as a wrapper for the resource located at the given path.
+ java.net.URLgetResource(java.lang.String path) + +
+          Returns a URL to the resource that is mapped to a specified + path.
+ java.io.InputStreamgetResourceAsStream(java.lang.String path) + +
+          Returns the resource located at the given path as an InputStream object.
+ java.util.Set<java.lang.String>getResourcePaths(java.lang.String path) + +
+          Returns a directory-like listing of all the paths to resources within + the web application longest sub-path of which + matches the supplied path argument.
+ java.lang.StringgetServerInfo() + +
+          Returns the name and version of the portlet container in which the + portlet is running.
+ voidlog(java.lang.String msg) + +
+          Writes the specified message to a portlet log file, usually an event log.
+ voidlog(java.lang.String message, + java.lang.Throwable throwable) + +
+          Writes an explanatory message and a stack trace for a given + Throwable exception to the portlet log file.
+ voidremoveAttribute(java.lang.String name) + +
+          Removes the attribute with the given name from the portlet context.
+ voidsetAttribute(java.lang.String name, + java.lang.Object object) + +
+          Binds an object to a given attribute name in this portlet context.
+  +

+ + + + + + + + +
+Method Detail
+ +

+getServerInfo

+
+java.lang.String getServerInfo()
+
+
Returns the name and version of the portlet container in which the + portlet is running. + +

+ The form of the returned string is containername/versionnumber. +

+

+ +
Returns:
the string containing at least name and version number
+
+
+
+ +

+getRequestDispatcher

+
+PortletRequestDispatcher getRequestDispatcher(java.lang.String path)
+
+
Returns a PortletRequestDispatcher object that acts + as a wrapper for the resource located at the given path. + A PortletRequestDispatcher object can be used include the + resource in a response. The resource can be dynamic or static. + +

The pathname must begin with a slash ( / ) and is interpreted as relative + to the current context root. + +

This method returns null if the PortletContext + cannot return a PortletRequestDispatcher + for any reason. +

+

+
Parameters:
path - a String specifying the pathname + to the resource +
Returns:
a PortletRequestDispatcher object + that acts as a wrapper for the resource + at the specified path.
See Also:
PortletRequestDispatcher
+
+
+
+ +

+getNamedDispatcher

+
+PortletRequestDispatcher getNamedDispatcher(java.lang.String name)
+
+
Returns a PortletRequestDispatcher object that acts + as a wrapper for the named servlet. + +

Servlets (and also JSP pages) may be given names via server + administration or via a web application deployment descriptor. + +

This method returns null if the + PortletContext cannot return a + PortletRequestDispatcher for any reason. +

+

+
Parameters:
name - a String specifying the name + of a servlet to be wrapped +
Returns:
a PortletRequestDispatcher object + that acts as a wrapper for the named servlet
See Also:
PortletRequestDispatcher
+
+
+
+ +

+getResourceAsStream

+
+java.io.InputStream getResourceAsStream(java.lang.String path)
+
+
Returns the resource located at the given path as an InputStream object. + The data in the InputStream can be of any type or length. The method returns + null if no resource exists at the given path. +

+ In order to access protected resources the path has to be prefixed with + /WEB-INF/ (for example /WEB-INF/myportlet/myportlet.jsp). + Otherwise, the direct path is used + (for example /myportlet/myportlet.jsp). +

+

+
Parameters:
path - the path to the resource +
Returns:
the input stream
+
+
+
+ +

+getMajorVersion

+
+int getMajorVersion()
+
+
Returns the major version of the Portlet API that this portlet + container supports. +

+

+ +
Returns:
the major version
See Also:
getMinorVersion()
+
+
+
+ +

+getMinorVersion

+
+int getMinorVersion()
+
+
Returns the minor version of the Portlet API that this portlet + container supports. +

+

+ +
Returns:
the minor version
See Also:
getMajorVersion()
+
+
+
+ +

+getMimeType

+
+java.lang.String getMimeType(java.lang.String file)
+
+
Returns the MIME type of the specified file, or null if + the MIME type is not known. The MIME type is determined + by the configuration of the portlet container and may be specified + in a web application deployment descriptor. Common MIME + types are text/html and image/gif. +

+

+
Parameters:
file - a String specifying the name + of a file +
Returns:
a String specifying the MIME type of the file
+
+
+
+ +

+getRealPath

+
+java.lang.String getRealPath(java.lang.String path)
+
+
Returns a String containing the real path + for a given virtual path. For example, the path /index.html + returns the absolute file path of the portlet container file system. + +

The real path returned will be in a form + appropriate to the computer and operating system on + which the portlet container is running, including the + proper path separators. This method returns null + if the portlet container cannot translate the virtual path + to a real path for any reason (such as when the content is + being made available from a .war archive). +

+

+
Parameters:
path - a String specifying a virtual path +
Returns:
a String specifying the real path, + or null if the transformation cannot be performed.
+
+
+
+ +

+getResourcePaths

+
+java.util.Set<java.lang.String> getResourcePaths(java.lang.String path)
+
+
Returns a directory-like listing of all the paths to resources within + the web application longest sub-path of which + matches the supplied path argument. Paths indicating subdirectory paths + end with a slash (/). The returned paths are all + relative to the root of the web application and have a leading slash. + For example, for a web application + containing

+ + /welcome.html
+ /catalog/index.html
+ /catalog/products.html
+ /catalog/offers/books.html
+ /catalog/offers/music.html
+ /customer/login.jsp
+ /WEB-INF/web.xml
+ /WEB-INF/classes/com.acme.OrderPortlet.class,

+
+ + getResourcePaths("/") returns + {"/welcome.html", "/catalog/", "/customer/", "/WEB-INF/"}
+ getResourcePaths("/catalog/") returns + {"/catalog/index.html", "/catalog/products.html", "/catalog/offers/"}.
+

+

+
Parameters:
path - the partial path used to match the resources, which must start with a slash +
Returns:
a Set containing the directory listing, or null if there + are no resources in the web application of which the path + begins with the supplied path.
+
+
+
+ +

+getResource

+
+java.net.URL getResource(java.lang.String path)
+                         throws java.net.MalformedURLException
+
+
Returns a URL to the resource that is mapped to a specified + path. The path must begin with a slash (/) and is interpreted + as relative to the current context root. + +

This method allows the portlet container to make a resource + available to portlets from any source. Resources + can be located on a local or remote + file system, in a database, or in a .war file. + +

The portlet container must implement the URL handlers + and URLConnection objects that are necessary + to access the resource. + +

This method returns null + if no resource is mapped to the pathname. + +

Some containers may allow writing to the URL returned by + this method using the methods of the URL class. + +

The resource content is returned directly, so be aware that + requesting a .jsp page returns the JSP source code. + Use a RequestDispatcher instead to include results of + an execution. + +

This method has a different purpose than + java.lang.Class.getResource, + which looks up resources based on a class loader. This + method does not use class loaders. +

+

+
Parameters:
path - a String specifying + the path to the resource +
Returns:
the resource located at the named path, + or null if there is no resource + at that path +
Throws: +
java.net.MalformedURLException - if the pathname is not given in + the correct form
+
+
+
+ +

+getAttribute

+
+java.lang.Object getAttribute(java.lang.String name)
+
+
Returns the portlet container attribute with the given name, + or null if there is no attribute by that name. + An attribute allows a portlet container to give the + portlet additional information not + already provided by this interface. + A list of supported attributes can be retrieved using + getAttributeNames. + +

The attribute is returned as a java.lang.Object + or some subclass. + Attribute names should follow the same convention as package + names. The Java Portlet API specification reserves names + matching java.*, javax.*, + and sun.*. +

+

+
Parameters:
name - a String specifying the name + of the attribute +
Returns:
an Object containing the value + of the attribute, or null + if no attribute exists matching the given + name +
Throws: +
java.lang.IllegalArgumentException - if name is null.
See Also:
getAttributeNames()
+
+
+
+ +

+getAttributeNames

+
+java.util.Enumeration<java.lang.String> getAttributeNames()
+
+
Returns an Enumeration containing the attribute names + available within this portlet context, or an empty + Enumeration if no attributes are available. Use the + getAttribute(java.lang.String) method with an attribute name + to get the value of an attribute. +

+

+ +
Returns:
an Enumeration of attribute names
See Also:
getAttribute(java.lang.String)
+
+
+
+ +

+getInitParameter

+
+java.lang.String getInitParameter(java.lang.String name)
+
+
Returns a String containing the value of the named context-wide + initialization parameter, or null if the parameter does not exist. + This method provides configuration information which may be useful for + an entire "portlet application". +

+

+
Parameters:
name - a String containing the name of the + requested parameter +
Returns:
a String containing the value + of the initialization parameter, or + null if the parameter does not exist. +
Throws: +
java.lang.IllegalArgumentException - if name is null.
See Also:
getInitParameterNames()
+
+
+
+ +

+getInitParameterNames

+
+java.util.Enumeration<java.lang.String> getInitParameterNames()
+
+
Returns the names of the context initialization parameters as an + Enumeration of String objects, or an empty Enumeration if the context + has no initialization parameters. +

+

+ +
Returns:
an Enumeration of String + objects containing the names of the context + initialization parameters
See Also:
getInitParameter(java.lang.String)
+
+
+
+ +

+log

+
+void log(java.lang.String msg)
+
+
Writes the specified message to a portlet log file, usually an event log. + The name and type of the portlet log file is specific to the portlet container. +

+ This method mapps to the ServletContext.log method. + The portlet container may in addition log this message in a + portlet container specific log file. +

+

+
Parameters:
msg - a String specifying the + message to be written to the log file
+
+
+
+ +

+log

+
+void log(java.lang.String message,
+         java.lang.Throwable throwable)
+
+
Writes an explanatory message and a stack trace for a given + Throwable exception to the portlet log file. + The name and type of the portlet log file is specific to the + portlet container, usually an event log. +

+ This method is mapped to the ServletContext.log method. + The portlet container may in addition log this message in a + portlet container specific log file. +

+

+
Parameters:
message - a String that + describes the error or exception
throwable - the Throwable error + or exception
+
+
+
+ +

+removeAttribute

+
+void removeAttribute(java.lang.String name)
+
+
Removes the attribute with the given name from the portlet context. + After removal, subsequent calls to + getAttribute(java.lang.String) to retrieve the attribute's value + will return null. +

+

+
Parameters:
name - a String specifying the name + of the attribute to be removed +
Throws: +
java.lang.IllegalArgumentException - if name is null.
+
+
+
+ +

+setAttribute

+
+void setAttribute(java.lang.String name,
+                  java.lang.Object object)
+
+
Binds an object to a given attribute name in this portlet context. + If the name specified is already used for an attribute, this method + removes the old attribute and binds the name to the new attribute. +

+ If a null value is passed, the effect is the same as calling + removeAttribute(). + +

Attribute names should follow the same convention as package + names. The Java Portlet API specification reserves names + matching java.*, javax.*, and + sun.*. +

+

+
Parameters:
name - a String specifying the name + of the attribute
object - an Object representing the + attribute to be bound +
Throws: +
java.lang.IllegalArgumentException - if name is null.
+
+
+
+ +

+getPortletContextName

+
+java.lang.String getPortletContextName()
+
+
Returns the name of this portlet application correponding to this PortletContext as specified + in the web.xml deployment descriptor for this web application by the + display-name element. +

+

+ +
Returns:
The name of the web application or null if no name has been declared in the deployment descriptor.
+
+
+
+ +

+getContainerRuntimeOptions

+
+java.util.Enumeration<java.lang.String> getContainerRuntimeOptions()
+
+
Returns the container container runtime options + keys supported by this portlet container. +

+

+ +
Returns:
container runtime options keys supported by this + container as String values.
Since:
+
2.0
+
+
+
+ +
+ + + + + + + + + + + + + + + + + + + +
+ +
+ + + +
+ + + Propchange: portals/pluto/branches/2.0-spi-refactoring/src/site/resources/portlet-2.0-apidocs/javax/portlet/PortletContext.html ------------------------------------------------------------------------------ svn:keywords = Id Added: portals/pluto/branches/2.0-spi-refactoring/src/site/resources/portlet-2.0-apidocs/javax/portlet/PortletException.html URL: http://svn.apache.org/viewvc/portals/pluto/branches/2.0-spi-refactoring/src/site/resources/portlet-2.0-apidocs/javax/portlet/PortletException.html?rev=709960&view=auto ============================================================================== --- portals/pluto/branches/2.0-spi-refactoring/src/site/resources/portlet-2.0-apidocs/javax/portlet/PortletException.html (added) +++ portals/pluto/branches/2.0-spi-refactoring/src/site/resources/portlet-2.0-apidocs/javax/portlet/PortletException.html Sun Nov 2 14:19:07 2008 @@ -0,0 +1,320 @@ + + + + + + +PortletException + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + +
+ +

+ +javax.portlet +
+Class PortletException

+
+java.lang.Object
+  extended by java.lang.Throwable
+      extended by java.lang.Exception
+          extended by javax.portlet.PortletException
+
+
+
All Implemented Interfaces:
java.io.Serializable
+
+
+
Direct Known Subclasses:
PortletModeException, PortletSecurityException, ReadOnlyException, UnavailableException, ValidatorException, WindowStateException
+
+
+
+
public class PortletException
extends java.lang.Exception
+ + +

+The PortletException class defines a general exception + that a portlet can throw when it is unable to perform its operation + successfully. +

+ +

+

+
See Also:
Serialized Form
+
+ +

+ + + + + + + + + + + + + + + + + + + + +
+Constructor Summary
PortletException() + +
+          Constructs a new portlet exception.
PortletException(java.lang.String text) + +
+          Constructs a new portlet exception with the given text.
PortletException(java.lang.String text, + java.lang.Throwable cause) + +
+          Constructs a new portlet exception when the portlet needs to do + the following: + + throw an exception + include the "root cause" exception + include a description message +
PortletException(java.lang.Throwable cause) + +
+          Constructs a new portlet exception when the portlet needs to throw an + exception.
+  + + + + + + + +
+Method Summary
+ + + + + + + +
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
+ + + + + + + +
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
+  +

+ + + + + + + + +
+Constructor Detail
+ +

+PortletException

+
+public PortletException()
+
+
Constructs a new portlet exception. +

+

+
+ +

+PortletException

+
+public PortletException(java.lang.String text)
+
+
Constructs a new portlet exception with the given text. The + portlet container may use the text write it to a log. +

+

+
Parameters:
text - the exception text
+
+
+ +

+PortletException

+
+public PortletException(java.lang.String text,
+                        java.lang.Throwable cause)
+
+
Constructs a new portlet exception when the portlet needs to do + the following: +
    +
  • throw an exception +
  • include the "root cause" exception +
  • include a description message +
+

+

+
Parameters:
text - the exception text
cause - the root cause
+
+
+ +

+PortletException

+
+public PortletException(java.lang.Throwable cause)
+
+
Constructs a new portlet exception when the portlet needs to throw an + exception. The exception's message is based on the localized message + of the underlying exception. +

+

+
Parameters:
cause - the root cause
+
+ +
+ + + + + + + + + + + + + + + + + + + +
+ +
+ + + +
+ + + Propchange: portals/pluto/branches/2.0-spi-refactoring/src/site/resources/portlet-2.0-apidocs/javax/portlet/PortletException.html ------------------------------------------------------------------------------ svn:keywords = Id