|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.turbine.services.template.TurbineTemplate
public abstract class TurbineTemplate
This is a simple static accessor to common TemplateService tasks such as getting a Screen that is associated with a screen template.
Constructor Summary | |
---|---|
TurbineTemplate()
|
Method Summary | |
---|---|
static String |
getDefaultExtension()
Get the default extension given in the properties file. |
static String |
getDefaultLayout()
Get the default layout module name of the template engine service corresponding to the default template name extension. |
static String |
getDefaultLayoutName(RunData data)
Find the default layout module name for the given request. |
static String |
getDefaultLayoutName(String template)
Get the default layout module name of the template engine service corresponding to the template name extension of the named template. |
static String |
getDefaultLayoutTemplate()
Get the default layout template given in the properties file. |
static String |
getDefaultLayoutTemplateName(String template)
Get the default layout template name of the template engine service corresponding to the template name extension of the named template. |
static String |
getDefaultNavigation()
Get the default Navigation given in the properties file. |
static String |
getDefaultNavigationName(String template)
Get the default navigation module name of the template engine service corresponding to the template name extension of the named template. |
static String |
getDefaultPage()
Get the default page module name of the template engine service corresponding to the default template name extension. |
static String |
getDefaultPageName(RunData data)
Find the default page module name for the given request. |
static String |
getDefaultPageName(String template)
Get the default page module name of the template engine service corresponding to the template name extension of the named template. |
static String |
getDefaultScreen()
Get the Screen template given in the properties file. |
static String |
getDefaultScreenName(String template)
Get the default screen module name of the template engine service corresponding to the template name extension of the named template. |
static String |
getDefaultTemplate()
Returns the Default Template Name with the Default Extension. |
static String |
getExtension(String template)
Return Extension for a supplied template |
static String |
getLayoutName(String template)
Locate and return the name of the layout module to be used with the named layout template. |
static String |
getLayoutTemplateName(String name)
Locate and return the name of a layout template. |
static String |
getNavigationName(String template)
Locate and return the name of the navigation module to be used with the named navigation template. |
static String |
getNavigationTemplateName(String key)
Locate and return the name of a navigation template. |
static String |
getScreenName(String name)
Locate and return the name of a Screen module. |
static String |
getScreenTemplateName(String key)
Locate and return the name of a screen template. |
static TemplateService |
getService()
Utility method for accessing the service implementation |
static TemplateEngineService |
getTemplateEngineService(String template)
The TemplateEngineService
associated with the specified template's file extension. |
static boolean |
isCaching()
Returns true if the Template Service has caching activated |
static void |
registerTemplateEngineService(TemplateEngineService service)
Registers the provided template engine for use by the TemplateService . |
static boolean |
templateExists(String template,
String[] templatePaths)
Deprecated. Use templateExists from the various Templating Engines |
static String[] |
translateTemplatePaths(String[] templatePaths)
Deprecated. Each template engine service should know how to translate a request onto a file. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public TurbineTemplate()
Method Detail |
---|
public static TemplateService getService()
public static final boolean isCaching()
public static final String getDefaultExtension()
public static final String getExtension(String template)
template
- The template name
public static final String getDefaultTemplate()
public static final String getDefaultPage()
public static final String getDefaultScreen()
public static final String getDefaultLayout()
public static final String getDefaultNavigation()
public static final String getDefaultLayoutTemplate()
public static final String getDefaultPageName(String template)
template
- The template name.
public static final String getDefaultScreenName(String template)
template
- The template name.
public static final String getDefaultLayoutName(String template)
template
- The template name.
public static final String getDefaultNavigationName(String template)
template
- The template name.
public static final String getDefaultLayoutTemplateName(String template)
template
- The template name.
public static final String getDefaultPageName(RunData data)
data
- The encapsulation of the request to retrieve the
default page for.
public static final String getDefaultLayoutName(RunData data)
data
- The encapsulation of the request to retrieve the
default layout for.
public static final String getScreenName(String name) throws Exception
name
- A String with the name of the template.
Exception,
- a generic exception.
Exception
public static final String getLayoutName(String template) throws Exception
template
- The layout template name.
Exception,
- a generic exception.
Exception
public static final String getNavigationName(String template) throws Exception
template
- The navigation template name.
Exception,
- a generic exception.
Exception
public static final String getScreenTemplateName(String key) throws Exception
key
- A String which is the key to the template.
Exception,
- a generic exception.
Exception
public static final String getLayoutTemplateName(String name) throws Exception
name
- A String with the name of the template.
Exception,
- a generic exception.
Exception
public static final String getNavigationTemplateName(String key) throws Exception
key
- A String which is the key to the template.
Exception,
- a generic exception.
Exception
public static final String[] translateTemplatePaths(String[] templatePaths)
templatePaths
- An array of template paths.
public static final boolean templateExists(String template, String[] templatePaths)
TemplateEngineService
to
check the existance of the specified template.
template
- The template to check for the existance of.templatePaths
- The paths to check for the template.public static final void registerTemplateEngineService(TemplateEngineService service)
TemplateService
.
service
- The TemplateEngineService
to register.public static final TemplateEngineService getTemplateEngineService(String template)
TemplateEngineService
associated with the specified template's file extension.
template
- The template name.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |