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.turbine.services.template.mapper
Class BaseTemplateMapper

    java.lang.Object
      org.apache.turbine.services.template.mapper.BaseMapper
          org.apache.turbine.services.template.mapper.BaseTemplateMapper

Direct Known Subclasses:
  DirectTemplateMapper, LayoutTemplateMapper, ScreenDefaultTemplateMapper, ScreenTemplateMapper

    public abstract class BaseTemplateMapper

extends BaseMapper

This is a mapper like the BaseMapper but it returns its results with the extension of the template names passed or (if no extension is passed), the default extension.

Version:
  $Id: BaseTemplateMapper.java 615328 2008-01-25 20:25:05Z tv $
Author:
  Henning P. Schmiedehausen

Field Summary
`protected String` | `prefix` A prefix which is used to separate the various template types (screen, layouts, navigation)

Fields inherited from class org.apache.turbine.services.template.mapper.BaseMapper
`defaultProperty, separator`

Constructor Summary
`BaseTemplateMapper()` Default C'tor.

Method Summary
`String` | `getDefaultName(String template)` Returns the default name for the passed Template.
`String` | `getPrefix()` Get the Prefix value.
`void` | `setPrefix(String prefix)` Set the Prefix value.

Methods inherited from class org.apache.turbine.services.template.mapper.BaseMapper
`doMapping, getCacheSize, getDefaultProperty, getMappedName, getSeparator, init, isUseCache, setCacheSize, setDefaultProperty, setSeparator, setUseCache`

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

Field Detail

### prefix

    protected String prefix

  A prefix which is used to separate the various template types (screen, layouts, navigation)

Constructor Detail

### BaseTemplateMapper

    public BaseTemplateMapper()

  Default C'tor. If you use this C'tor, you must use the bean setter to set the various properties needed for this mapper before first usage.

Method Detail

### getPrefix

    public String getPrefix()

  Get the Prefix value.

  Returns:
    the Prefix value.

### setPrefix

    public void setPrefix(String prefix)

  Set the Prefix value.

  Parameters:
    `prefix` - The new Prefix value.

### getDefaultName

    public String getDefaultName(String template)

  Returns the default name for the passed Template. If the template has no extension, the default extension is added. If the template is empty, the default template is returned.

  Overrides:
    `getDefaultName` in class `BaseMapper`
  Parameters:
    `template` - The template name.
  Returns:
    the mapped default name for the template.

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 © 2000-2011 The Apache Software Foundation. All Rights Reserved.