Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.portals.bridges.portletfilter
Class PortletFilterConfig

    java.lang.Object
      org.apache.portals.bridges.portletfilter.PortletFilterConfig

public class PortletFilterConfig
extends Object

A filter configuration object used by FilterPortlet to pass information to a filter during initialization. The initialization parameter provided by getInitParameter(String) is specified in the portlet descriptor(portlet.xml) with the target PortletFilter name and a separator(:). Example:

     <portlet-app id="example-portlets" version="1.0">
        <portlet id="ExamplePortlet">
     ...
            <init-param>
                <name>portlet-class</name>
                <value>org.apache.myfaces.portlet.MyFacesGenericPortlet</value>
            </init-param>
            <init-param>
                <name>portlet-filters</name>
                <value>org.apache.myfaces.portlet.TomahawkPortletFilter</value>
            </init-param>
            <init-param>
                <name>org.apache.myfaces.portlet.TomahawkPortletFilter:upload-threshold-size</name>
                <value>1m</value>
            </init-param>
            <init-param>
                <name>org.apache.myfaces.portlet.TomahawkPortletFilter:upload-max-file-size</name>
                <value>10m</value>
            </init-param>
     ...

Author:
  Shinsuke Sugaya

Nested Class Summary
`class` | `PortletFilterConfig.Enumerator` Uitlity class to wraps an `Iterator`

Field Summary
`private String` | `filterName`
`private static org.apache.commons.logging.Log` | `log` Logger for this class
`private String` | `PARAMETER_SEPRATOR`
`private Map` | `parameters`
`private javax.portlet.PortletConfig` | `portletConfig`
`private PortletFilter` | `portletFilter`

Constructor Summary
`PortletFilterConfig(String filterName, javax.portlet.PortletConfig config)`

Method Summary
`String` | `getFilterName()`
`String` | `getInitParameter(String name)` Return a `String` containing the value of the named initialization parameter, or `null` if the parameter does not exist.
`Enumeration` | `getInitParameterNames()` Return an `Enumeration` of the names of the initialization parameters for this Filter.
`javax.portlet.PortletConfig` | `getPortletConfig()`
`PortletFilter` | `getPortletFilter()` Returns the PortletFilter instance.
`private void` | `parseParameters()` Parses initialization parameters in a portlet descriptor(portlet.xml).
`void` | `release()`
`void` | `setFilterName(String filterName)`
`void` | `setPortletConfig(javax.portlet.PortletConfig portletConfig)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### log

    private static final org.apache.commons.logging.Log log

  Logger for this class

### PARAMETER_SEPRATOR

    private String PARAMETER_SEPRATOR

### portletFilter

    private PortletFilter portletFilter

### portletConfig

    private javax.portlet.PortletConfig portletConfig

### filterName

    private String filterName

### parameters

    private Map parameters

Constructor Detail

### PortletFilterConfig

    public PortletFilterConfig(String filterName,
                               javax.portlet.PortletConfig config)
                        throws javax.portlet.PortletException

Method Detail

### parseParameters

    private void parseParameters()

  Parses initialization parameters in a portlet descriptor(portlet.xml).

### getInitParameter

    public String getInitParameter(String name)

  Return a `String` containing the value of the named initialization parameter, or `null` if the parameter does not exist.

  Parameters:
    `name` - Name of the requested initialization parameter

### getInitParameterNames

    public Enumeration getInitParameterNames()

  Return an `Enumeration` of the names of the initialization parameters for this Filter.

### getPortletFilter

    public PortletFilter getPortletFilter()

  Returns the PortletFilter instance.

  Returns:

### getPortletConfig

    public javax.portlet.PortletConfig getPortletConfig()

  Returns:
    Returns the portletConfig.

### setPortletConfig

    public void setPortletConfig(javax.portlet.PortletConfig portletConfig)

  Parameters:
    `portletConfig` - The portletConfig to set.

### release

    public void release()

### getFilterName

    public String getFilterName()

  Returns:
    Returns the filterName.

### setFilterName

    public void setFilterName(String filterName)

  Parameters:
    `filterName` - The filterName to set.

Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2005-2007 Apache Software Foundation. All Rights Reserved.