|
Style Intelligence v12.0 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectinetsoft.sree.BasicReplet
inetsoft.sree.TemplateReplet
public class TemplateReplet
The TemplateReplet handles all replets that uses report templates for creating a report. No additional programming is required to use this class. To create a replet from a template, register a replet with the 'Template' option selected and specify the template file resource name. The TemplateReplet automatically loads in the template and processes any data binding defined in the template.
If a replet uses a template to load in a report but needs to add additional logic for handling a report request, it can use TemplateReplet as the base class. The derived class must call setTemplate() in its init() method and pass in the template file resource path. In the subclass' createReport() method, it should call super.createReport() to get a ReportSheet.
| Nested Class Summary | |
|---|---|
static class |
TemplateReplet.ReportInfo
|
| Field Summary | |
|---|---|
protected boolean |
cache
|
protected ReportSheet |
initReport
|
protected String |
template
|
| Fields inherited from class inetsoft.sree.BasicReplet |
|---|
catalog, destroyed, fieldelems, lastreq, principal |
| Fields inherited from interface inetsoft.sree.Replet |
|---|
DESIGN_MODE, RUN_MODE |
| Constructor Summary | |
|---|---|
TemplateReplet()
|
|
| Method Summary | |
|---|---|
ReportSheet |
createReport(RepletRequest req)
Generate a report. |
void |
destroy()
Remove the cached template file. |
ReportSheet |
fetchTemplate()
Obtain a template from cache or file. |
ReportSheet |
getReport()
Get the report object. |
long |
getReportLastModified()
Get the report last modified time. |
String |
getTemplate()
Get the template resource name or URL. |
void |
init(RepletRequest req)
Initialize the replet. |
void |
setReport(ReportSheet report)
Set the report in this replet. |
void |
setTemplate(String template)
Set the template file resource name or URL. |
void |
waitForLoaded()
Wait until report is loaded. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected String template
protected boolean cache
protected ReportSheet initReport
| Constructor Detail |
|---|
public TemplateReplet()
| Method Detail |
|---|
public ReportSheet getReport()
getReport in interface RepletgetReport in class BasicRepletpublic void setReport(ReportSheet report)
setReport in class BasicReplet
public ReportSheet createReport(RepletRequest req)
throws RepletException
createReport in class BasicRepletreq - replet request, including replet parameter values.
RepletException
public void waitForLoaded()
throws RepletException
waitForLoaded in interface RepletwaitForLoaded in class BasicRepletRepletException
public void init(RepletRequest req)
throws RepletException
init in interface Repletinit in class BasicRepletreq - initialization request.
RepletExceptionpublic void setTemplate(String template)
public String getTemplate()
public ReportSheet fetchTemplate()
throws Exception
Exceptionpublic long getReportLastModified()
getReportLastModified in interface RepletgetReportLastModified in class BasicRepletpublic void destroy()
destroy in interface Repletdestroy in class BasicReplet
|
Copyright © 1996-2014 InetSoft Technology Corp. All Rights Reserved. | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||