Package org.apache.tiles.request.render

# Class BasicRendererFactory

java.lang.Object
org.apache.tiles.request.render.BasicRendererFactory

All Implemented Interfaces:
  `RendererFactory`

public class BasicRendererFactory extends Object implements RendererFactory
Basic renderer factory implementation.

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `protected Renderer`
  `defaultRenderer`
  The default renderer.
  `protected Map<String,Renderer>`
  `renderers`
  The renderer name/renderer map.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `BasicRendererFactory()`
  Constructor.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `Renderer`
  `getRenderer(String name)`
  Returns a renderer by its name.
  `void`
  `registerRenderer(String name, Renderer renderer)`
  Registers a renderer.
  `void`
  `setDefaultRenderer(Renderer renderer)`
  Sets the default renderer.

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Field Details

  - ### renderers

    protected Map<String,Renderer> renderers
    The renderer name/renderer map.

  - ### defaultRenderer

    protected Renderer defaultRenderer
    The default renderer.

- ## Constructor Details

  - ### BasicRendererFactory

    public BasicRendererFactory()
    Constructor.

- ## Method Details

  - ### getRenderer

    public Renderer getRenderer(String name)
    Returns a renderer by its name.
    Specified by:
      `getRenderer` in interface `RendererFactory`
    Parameters:
      `name` - The name of the renderer.
    Returns:
      The renderer.

  - ### setDefaultRenderer

    public void setDefaultRenderer(Renderer renderer)
    Sets the default renderer.
    Parameters:
      `renderer` - The default renderer.

  - ### registerRenderer

    public void registerRenderer(String name, Renderer renderer)
    Registers a renderer.
    Parameters:
      `name` - The name of the renderer.
      `renderer` - The renderer to register.