org.norther.tammi.spray.servlet
Interface ForwardEngine

All Superinterfaces:
CacheClient<String,String>, Configurable, Refreshable, Startable, TemplateEngine
All Known Subinterfaces:
JSPEngine
All Known Implementing Classes:
DefaultForwardEngine, DefaultJSPEngine

public interface ForwardEngine
extends TemplateEngine, CacheClient<String,String>

Extends TemplateEngine for rendering templates with the RequestDispatcher mechanism.

Version:
$Id: ForwardEngine.java,v 1.2 2009/09/28 15:08:27 cvsimp Exp $
Author:
Ilkka Priha

Field Summary
static String CONTEXT_NAME_PROPERTY
          The context name property.
static String FOLDER_PATHS_PROPERTY
          The folder paths property.
static String FORWARDED_PROPERTY
          The forwarded property.
static String TEMPLATE_KEY_PROPERTY
          The template key property.
 
Method Summary
 void addFolderPath(int index, String path)
          Adds a template folder path at the specified index.
 void addFolderPath(String path)
          Adds a template folder path.
 void clearFolders()
          Clears all template folders.
 ObjectName getContextName()
          Gets the startup context name.
 String[] getFolderPaths()
          Gets the template folder paths.
 String getTemplateKey()
          Gets the path finder key for resolving template paths.
 boolean isForwarded()
          Gets the forwarded option.
 void removeFolderPath(String path)
          Removes a template folder path.
 void setContextName(ObjectName servlet)
          Sets the startup context name.
 void setFolderPaths(String[] paths)
          Sets the template folder paths.
 void setForwarded(boolean option)
          Sets the forwarded option.
 void setTemplateKey(String key)
          Sets the path finder key for resolving template paths.
 
Methods inherited from interface org.norther.tammi.spray.engine.TemplateEngine
evaluate, evaluate, evaluate, execute, execute, execute, getDefaultEncoding, resolveLocalizedTemplate, setDefaultEncoding, templateExists
 
Methods inherited from interface org.norther.tammi.core.config.Configurable
addProperty, addProperty, addPropertyFilePath, addPropertyFilePath, clearProperties, containsProperty, getConfigKey, getProperties, getProperty, getPropertyFilePath, getPropertyFilePaths, indexOfProperty, propertyMap, propertyMap, removeProperty, removeProperty, removePropertyFilePath, setConfigKey, setProperties, setProperty, setPropertyFilePath, setPropertyFilePath, setPropertyFilePaths, setPropertyFilePaths, storeProperties
 
Methods inherited from interface org.norther.tammi.core.base.Startable
isStarted, start, stop
 
Methods inherited from interface org.norther.tammi.core.cache.CacheClient
clearCached, expireCached, expireFraction, getCache, getSharedCacheName, isCachingDisabled, removeCache, setCachingDisabled, setSharedCacheName
 
Methods inherited from interface org.norther.tammi.core.base.Refreshable
getRefreshed, refresh
 

Field Detail

TEMPLATE_KEY_PROPERTY

static final String TEMPLATE_KEY_PROPERTY
The template key property.

See Also:
Constant Field Values

FORWARDED_PROPERTY

static final String FORWARDED_PROPERTY
The forwarded property.

See Also:
Constant Field Values

CONTEXT_NAME_PROPERTY

static final String CONTEXT_NAME_PROPERTY
The context name property.

See Also:
Constant Field Values

FOLDER_PATHS_PROPERTY

static final String FOLDER_PATHS_PROPERTY
The folder paths property.

See Also:
Constant Field Values
Method Detail

getTemplateKey

String getTemplateKey()
Gets the path finder key for resolving template paths.

Returns:
the path finder key.

setTemplateKey

void setTemplateKey(String key)
Sets the path finder key for resolving template paths.

Parameters:
key - the path finder key.

isForwarded

boolean isForwarded()
Gets the forwarded option.

Returns:
true if the forwarded option is set, otherwise false.

setForwarded

void setForwarded(boolean option)
Sets the forwarded option. If set, incoming requests are forwarded to the JSP servlet, otherwise the JSP template is included in requests.

Parameters:
option - true to set the forwarded option, otherwise false.

getContextName

ObjectName getContextName()
Gets the startup context name.

Returns:
the name of the context or a query.

setContextName

void setContextName(ObjectName servlet)
Sets the startup context name.

Parameters:
servlet - the name of the context or a query.

getFolderPaths

String[] getFolderPaths()
Gets the template folder paths.

Returns:
an array of folder paths.

setFolderPaths

void setFolderPaths(String[] paths)
Sets the template folder paths.

Parameters:
paths - an array of folder paths.

addFolderPath

void addFolderPath(String path)
Adds a template folder path.

Parameters:
path - the folder path.

addFolderPath

void addFolderPath(int index,
                   String path)
Adds a template folder path at the specified index.

Parameters:
index - the index.
path - the folder path.

removeFolderPath

void removeFolderPath(String path)
Removes a template folder path.

Parameters:
path - the folder path.

clearFolders

void clearFolders()
Clears all template folders.



Copyright © 2004 The Norther Organization. All rights reserved.