Overview | 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.tiles.context
Class ChainedTilesRequestContextFactory

    java.lang.Object
      org.apache.tiles.context.ChainedTilesRequestContextFactory

All Implemented Interfaces:
  TilesRequestContextFactory, Initializable

    public class ChainedTilesRequestContextFactory

extends java.lang.Object
implements TilesRequestContextFactory

Default implementation for TilesRequestContextFactory, that creates a chain of sub-factories, trying each one until it returns a not-null value.

Since:
  2.1.1
Version:
  $Rev: 904529 $ $Date: 2010-01-29 16:50:30 +0100 (ven, 29 gen 2010) $

Field Summary
`static java.lang.String[]` | `DEFAULT_FACTORY_CLASS_NAMES` The default class names to instantiate that compose the chain..
`static java.lang.String` | `FACTORY_CLASS_NAMES` Factory class names initialization parameter to use.

Constructor Summary
`ChainedTilesRequestContextFactory()`

Method Summary
`TilesRequestContext` | `createRequestContext(TilesApplicationContext context, java.lang.Object... requestItems)` Create a TilesRequestContext for the given context, request, and response.
`void` | `init(java.util.Map<java.lang.String,java.lang.String> configParameters)` Initializes the object.
`protected void` | `injectParentTilesContextFactory()` Injects this context factory to all chained context factories.
`void` | `setFactories(java.util.List<TilesRequestContextFactory> factories)` Sets the factories to be used.

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

Field Detail

### FACTORY_CLASS_NAMES

    public static final java.lang.String FACTORY_CLASS_NAMES

  Factory class names initialization parameter to use.

  Since:
    2.1.1
  See Also:
    Constant Field Values

### DEFAULT_FACTORY_CLASS_NAMES

    public static final java.lang.String[] DEFAULT_FACTORY_CLASS_NAMES

  The default class names to instantiate that compose the chain..

  Since:
    2.1.1

Constructor Detail

### ChainedTilesRequestContextFactory

    public ChainedTilesRequestContextFactory()

Method Detail

### setFactories

    public void setFactories(java.util.List<TilesRequestContextFactory> factories)

  Sets the factories to be used.

  Parameters:
    `factories` - The factories to be used.

### init

    public void init(java.util.Map<java.lang.String,java.lang.String> configParameters)

  Initializes the object.

  Specified by:
    `init` in interface `Initializable`
  Parameters:
    `configParameters` - The map of parameters.

### createRequestContext

    public TilesRequestContext createRequestContext(TilesApplicationContext context,
                                                    java.lang.Object... requestItems)

  Create a TilesRequestContext for the given context, request, and response.

  Specified by:
    `createRequestContext` in interface `TilesRequestContextFactory`
  Parameters:
    `context` - the associated `TilesApplicationContext`
    `requestItems` - the associated request items, typically a request and a response.
  Returns:
    TilesRequestContext

### injectParentTilesContextFactory

    protected void injectParentTilesContextFactory()

  Injects this context factory to all chained context factories.

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

Copyright © 2001-2010 Apache Software Foundation. All Rights Reserved.