Class jet.bean.JREngine
java.lang.Object
|
+----java.awt.Component
|
+----java.awt.Container
|
+----java.awt.Panel
|
+----jet.bean.JREngine
- public class JREngine
- extends Panel
- implements externally
vDebug
- The constant for
setShowInfoLevel.
vError
- The constant for
setShowInfoLevel.
vOff
- The constant for
setShowInfoLevel.
JREngine()
- Default constructor.
deleteWherePortion(String)
- Removes the WHERE portion from the current catalog specified by the name String,
updates and saves the catalog after the deleting.
- This method is not available in JReport
Express Engine.
exit()
- Exits the current report engine, the method Calling will delete the temporary file
that is created by the report engine.
exportToHtml(String)
- Exports the JReport result file (with the .rst extension) to a HTML file.
- This method is not available in JReport
Express Engine.
exportToHtml(String,
String)
- Exports the JReport result file (with the .rst extension) to a HTML file.
- This method is not available in JReport
Express Engine.
exportToPdf(String)
- Exports the JReport result file (with the .rst extension) to a PDF file.
- This method is not available in JReport
Express Engine.
exportToPdf(String,
String)
- Exports the JReport result file (with the .rst extension) to a PDF file.
- This method is not available in JReport
Express Engine.
exportToText(String, boolean)
- Exports the JReport result file (with the .rst extension) to a TEXT file.
- This method is not available in JReport
Express Engine.
exportToText(String,
String, boolean)
- Exports the JReport result file (with the .rst extension) to a TEXT file.
- This method is not available in JReport
Express Engine.
getAllHtmlFile()
- Gets all html files that were generated by this engine.
- This method is not available in JReport
Express Engine.
getAvailableQueryFields()
- Gets all the available fields, including DB fields, formulas and parameters in this
query.
- This method is not available in JReport
Express Engine.
getAvailableWherePortions()
- Gets the enumeration of names for all the WHERE portions in the current catalog.
- This method is not available in JReport
Express Engine.
getCatName()
- Gets the name of the current catalog .
getDataDriver()
- Gets the data driver of the report which the engine will run.
- This method is not available in JReport
Express Engine.
getParamFile()
- Gets the name of the parameter value file.
getParamValues()
- Gets the parameter values of the report.
getReportHome()
- Gets the report home path where the report.ini and other JReport system files reside.
getReportName()
- Gets the report name which the engine will run.
getResultFile()
- Gets the name of the result file which will be generated by Engine.
getStatus()
- Gets the status when or after the report engine runs.
readExternal(ObjectInput)
-
runReport()
- Runs current report .
saveWherePortion(String,
String)
- Adds and saves the specified WHERE portion to the current catalog.
- This method is not available in JReport
Express Engine.
setCatName(String)
- Sets the name of the catalog which contains all the required objects used in the report.
setDataDriver(String)
- Sets the data driver of the report which the engine will run.
- This method is not available in JReport
Express Engine.
setLoadReport(String)
- Loads the report, the method calling will make the report engine run.
setLogFile(String)
- Sets the name of the log file.
setNamedWherePortion(String)
- Sets the WHERE portion specified by the where portion name from the report catalog to
current report query.
- This method is not available in JReport
Express Engine.
setParamFile(String)
- Sets the name of the parameter value file.
setParamValues(String)
- Sets the parameter values of the report.
setReportHome(String)
- Sets the report home path where the report.ini and other JReport system files reside.
setReportName(String)
- Sets the report name which the engine will run.
setResultFile(String)
- Specifies the name of the result file which will be generated by Engine.
setShowInfoLevel(int)
- Sets show debug information level.
setWherePortion(String)
- Sets the WHERE portion in string format to the current report query.
- This method is not available in JReport
Express Engine.
writeExternal(ObjectOutput)
-
vOff
public static final int vOff
- The constant for
setShowInfoLevel. specifies a turning off debug and an
error information.
- See Also:
- setShowInfoLevel
vDebug
public static final int vDebug
- The constant for
setShowInfoLevel. specifies a turning on debug
information.
- See Also:
- setShowInfoLevel
vError
public static final int vError
- The constant for
setShowInfoLevel. specifies a turning on error
information.
- See Also:
- setShowInfoLevel
JREngine
public JREngine()
- Default constructor.
getReportHome
public String getReportHome()
- Get the report home path where the report.ini and other JReport system files reside.
- Returns:
- the report home path where the report.ini and other JReport system files reside.
- See Also:
- setReportHome
setReportHome
public void setReportHome(String reportHome)
- Set the report home path where the report.ini and other JReport system files reside.
- Parameters:
- reportHome - the home path where the report.ini and other JReport system files reside.
- See Also:
- getReportHome
getReportName
public String getReportName()
- Get the report name which the engine will run.
- Returns:
- reportName the report name which the engine will run.
- See Also:
- setReportName
setReportName
public void setReportName(String reportName)
- Set the report name which the engine will run.
- Parameters:
- reportName - the report name which the engine will run.
- See Also:
- getReportName
setCatName
public void setCatName(String catName)
- Set the name of the catalog which contains all the required objects used in the report.
- Parameters:
- catName - the name of the catalog which contains all the required objects used in the
report.
- See Also:
- getCatName
getCatName
public String getCatName()
- Get the name of current catalog .
- Returns:
- the name of the catalog which contains all the required objects used in the report.
- See Also:
- setCatName
getParamValues
public String getParamValues()
- Get the parameter values of the report.
- Returns:
- the string containing the parameter values, separated by comma (',').
- See Also:
- setParamValues
setParamValues
public void setParamValues(String paramValues)
- Set the parameter values of the report.
- Parameters:
- paramValues - the string containing the parameter values, separated by comma (',').
- See Also:
- getParamValues
getParamFile
public String getParamFile()
- Get the name of the parameter value file.
- Returns:
- the name of the parameter value file. This will be ignored if paramValues is specified.
- See Also:
- setParamFile
setParamFile
public void setParamFile(String paramFile)
- Set the name of the parameter value file.
- Parameters:
- paramFile - the name of the parameter value file. This will be ignored if paramValues is
specified.
- See Also:
- getParamFile
getResultFile
public String getResultFile()
- Get the name of the result file which will be generated by Engine.
- Returns:
- the name of the result file.
- See Also:
- setResultFile
setResultFile
public void setResultFile(String resultFile)
- Specify the name of the result file which will be generated by Engine.
- Parameters:
- resultFile - the name of the result file.
- See Also:
- getResultFile
setDataDriver
public void setDataDriver(String url)
- Set the data driver of the report which the engine will run.
- Parameters:
- url - the data driver of the report which the engine will run.
- See Also:
- getDataDriver
getDataDriver
public String getDataDriver()
- Get the data driver of the report which the engine will run.
- Returns:
- the data driver of the report which the engine will run.
- See Also:
- setDataDriver
setLoadReport
public void setLoadReport(String loadReport)
- Load the report, the method calling will make the report engine run.
- Parameters:
- loadReport - indicates whether to load the report, if yes, then load.
runReport
public void runReport()
- Run current report .
exit
public void exit()
- Exit the current report engine, the method calling will delete the temporary file
that is created by the report engine.
setShowInfoLevel
public void setShowInfoLevel(int level)
- Set show debug information level.
- Parameters:
- level - the debug level
the debug level are vDebug, vError and vOff used for showing
debug information, error information and turning off debug and error information.
- See Also:
- setLogFile
setLogFile
public boolean setLogFile(String fileName)
- Set the name of the log file. The debug and error information will be saved to this
file.
- Parameters:
- fileName - the log file name
LogFileName specifies where the debug, error and other
information will go. LogFileName contains both the path and the file name. If no path is
specified, the current path is used. If no file name is specified, the file jreport.log is
used
- Returns:
- true if successful
- See Also:
- setShowInfoLevel
getStatus
public String getStatus()
- Get the status when or after the report engine runs.
exportToHtml
public boolean exportToHtml(String rstFileName,
String htmlFileName)
- Export the JReport result file (with the .rst extension) to a HTML file.
- Parameters:
- rstFileName - the input result file name.
- htmlFileName - the output HTML file name.
- Returns:
- true if exportation is successful
- See Also:
- exportToPdf, exportToText
exportToHtml
public boolean exportToHtml(String htmlFileName)
- Export the JReport result file (with the .rst extension) to a HTML file.
- Parameters:
- htmlFileName - the output HTML file name.
- Returns:
- true if exportation is successful
- See Also:
- exportToPdf, exportToText
getAllHtmlFile
public Vector getAllHtmlFile()
- Get all html files that were generated by this engine.
- See Also:
- exportToHtml
exportToPdf
public boolean exportToPdf(String rstFileName,
String pdfFileName)
- Export the JReport result file (with the .rst extension) to a PDF file.
- Parameters:
- rstFileName - the input result file name.
- pdfFileName - the output PDF file name.
- Returns:
- true if exportation is successful
- See Also:
- exportToHtml, exportToText
exportToPdf
public boolean exportToPdf(String pdfFileName)
- Export the JReport result file (with the .rst extension) to a PDF file.
- Parameters:
- pdfFileName - the output PDF file name.
- Returns:
- true if exportation successful
- See Also:
- exportToHtml, exportToText
exportToText
public boolean exportToText(String rstFileName,
String textFileName,
boolean isNormalText)
- Export the JReport result file (with the .rst extension) to a TEXT file.
- Parameters:
- rstFileName - the input result file name.
- textFileName - the output TEXT file name.
- isNormalText - is to set whether this text file is a normal text format or a
standard data format
the standard data format text file is the text file that each row
of it represents each record in the report. It can be used as a text datasource to
exchange data with other applications.
- Returns:
- true if exportation is successful
- See Also:
- exportToHtml, exportToPdf
exportToText
public boolean exportToText(String textFileName,
boolean isNormalText)
- Export the current report to a TEXT file.
- Parameters:
- textFileName - the output TEXT file name.
- isNormalText - is to set whether this text file is a normal text format or a standard
data format
the standard data format text file is a text file that each row of it
represents each record in the report. It can be used as a text datasource to exchange data
with other applications.
- Returns:
- true if exportation is successful
- See Also:
- exportToHtml, exportToPdf
setNamedWherePortion
public void setNamedWherePortion(String name)
- Set the WHERE portion specified by the where portion name from the report catalog to the
current report query.
- Parameters:
- name - the name of one of several WHERE portions saved in the current catalog
This
named WHERE portion will be appended to the end of the QUERY associated with the
definition by either: ADDing the portion of the WHERE clause to any joining statements
that are defined in the QUERY or by adding the WHERE clause where the portion of the WHERE
clause you have specified becomes the entire WHERE clause.
- See Also:
- setWherePortion, saveWherePortion,
deleteWherePortion, getAvailableWherePortions
setWherePortion
public void setWherePortion(String where)
- Set the WHERE portion to the query.
- Parameters:
- where - the WHERE portion in string format
The named WHERE portion will be appended
to the end of the QUERY associated with the definition by either: ADDing the portion of
the WHERE clause to any joining statements that are defined in the QUERY or by adding the
WHERE clause where the portion of the WHERE clause you have specified becomes the entire
WHERE clause.
- See Also:
- setNamedWherePortion
saveWherePortion
public boolean saveWherePortion(String strName,
String strSQL)
- Add and save the specified WHERE portion to the current catalog.
- Parameters:
- strName - the name of WHERE portion.
- strSQL - the WHERE portion string
- Returns:
- true if the where portion saved successfully. Note: this method is required by Novell.
- See Also:
- setNamedWherePortion, deleteWherePortion,
getAvailableWherePortions
deleteWherePortion
public boolean deleteWherePortion(String strName)
- Removes the WHERE portion from the current catalog specified by the name String, updates
and saves the catalog after the deletion.
- Parameters:
- strName, - the name of WHERE portion.
- Returns:
- true if the WHERE portion deleted successfully. Note: this method is required by Novell.
- See Also:
- setNamedWherePortion, saveWherePortion,
getAvailableWherePortions
getAvailableWherePortions
public Enumeration getAvailableWherePortions()
- Gets the enumeration of names for all the WHERE portions from the current catalog.
- Returns:
- a enumeration of the names of WHERE portions. Note: this method is required by Novell.
- See Also:
- setNamedWherePortion, saveWherePortion,
deleteWherePortion
getAvailableQueryFields
public Enumeration getAvailableQueryFields()
- Get all the available fields, including DB fields, formulas and parameters in this
query.
- Parameters:
- strQueryName, - name of the query.
- Returns:
- a enumeration that contains string in format "TableName.FldName", if failed,
return null Note: this method is required by Novell.