|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface ReportServerRMIWrapper
| Field Summary | |
|---|---|
static int |
OOME
|
static java.lang.String |
RMI_SERVER_WRAPPER
The remote object name in the rmi registry. |
static int |
RUNNING
|
static int |
UNKNOWN
Defines some constants to denote the status of the remote server. |
| Method Summary | |
|---|---|
ExportedFileList |
exportResult(java.lang.String userID,
java.lang.String resultFileName,
java.util.Properties props)
Exports a report result to RST, HTML, PDF, TEXT, Excel and PS. |
Member[] |
getAllMembers()
Returns all members in the cluster. |
Member[] |
getPredefinedServers()
Gets all servers predefined. |
java.util.Properties |
getScheduledTask(java.lang.String taskID)
Gets the properties of a scheduled task by the task ID. |
java.util.Vector |
getScheduledTasks()
Gets the scheduled tasks. |
int |
getServerStatus()
Gets the status of the remote server. |
boolean |
isTempResultReady(java.lang.String tempResultName)
Tests if the temporary result is ready. |
void |
removeLargeReport(java.lang.String tempResultName,
boolean isStop)
Deprecated. As of v8, No replacement. |
boolean |
removeScheduledTask(java.lang.String taskID)
Removes a scheduled task by the task ID. |
java.lang.String |
runReport(java.lang.String userID,
java.lang.String catalog,
java.lang.String report,
java.util.Properties propParams)
Runs a report immediately. |
java.lang.String |
runReportWithTimeouts(java.lang.String userID,
java.lang.String catalog,
java.lang.String report,
java.util.Properties propParams,
long timeouts)
Runs a report immediately with timeouts. |
void |
shutdown()
Shuts down the report server. |
java.lang.String |
submitScheduledTask(java.lang.String userID,
java.util.Properties propScheduledTask)
Submits a scheduled task and returns the task ID. |
java.lang.String |
waitTempResultReady(java.lang.String tempResultName)
Waits for the temporary result to be ready. |
| Field Detail |
|---|
static final java.lang.String RMI_SERVER_WRAPPER
static final int UNKNOWN
UNKNOWN will be returned to RMI client, if the server's status cannot be known
because the server's error, or network failure.
RUNNING denotes the remote server is normally running.
OOME denotes OOME occurred on the remote server.
static final int RUNNING
static final int OOME
| Method Detail |
|---|
void shutdown()
throws java.rmi.RemoteException
java.rmi.RemoteException - if communication-related error occurs during RMI call execution.
java.lang.String runReport(java.lang.String userID,
java.lang.String catalog,
java.lang.String report,
java.util.Properties propParams)
throws java.rmi.RemoteException
userID - the user ID.catalog - the catalog path in the report server, for example, /SunVMDemo/SunVMDemo.cat.report - the report name, for example, invoice.cls.propParams - the properties that contain APIConst.TAG_WHERE_PORTION, APIConst.TAG_NAMED_WHERE_PORTION,
APIConst.TAG_WHERE_CLAUSE, APIConst.TAG_USE_DEF_DB_USER, APIConst.TAG_USE_NEW_DB_PSWD,
APIConst.TAG_DB_USER, APIConst.TAG_DB_PSWD, APIConst.TAG_JDBC_URL,
APIConst.TAG_JDBC_DRIVER, APIConst.TAG_JDBC_CONNECTION_OBJECT and
the parameter values of the report.
Example: Running a report with user's JDBC connection object (APIConst.TAG_JDBC_CONNECTION_OBJECT).
//creates the java.sql.Connection object.
java.sql.Connection myCon = java.sql.DriverManager.getConnection(dbUrl);
//sets the parameter APIConst.TAG_JDBC_CONNECTION_OBJECT(jrs.jdbc_connection_object) to run a report.
propParams.put(APIConst.TAG_JDBC_CONNECTION_OBJECT, myCon);
//runs the report using this java.sql.Connection object instead of
//the default DB settings in the catalog.
rptServer.runReport(userID, catalog, report, propParams);
java.rmi.RemoteException - if communication-related error occurs during RMI call execution.
java.lang.String runReportWithTimeouts(java.lang.String userID,
java.lang.String catalog,
java.lang.String report,
java.util.Properties propParams,
long timeouts)
throws java.rmi.RemoteException
isTempResultReady(...) and waitTempResultReady(...) to check/wait until the
temporary result is ready.
userID - the user ID.catalog - the catalog path in the report server, for example, /SunVMDemo/SunVMDemo.cat.report - the report name, for example, invoice.cls.propParams - the properties that contain APIConst.TAG_WHERE_PORTION, APIConst.TAG_NAMED_WHERE_PORTION,
APIConst.TAG_WHERE_CLAUSE, APIConst.TAG_USE_DEF_DB_USER, APIConst.TAG_USE_NEW_DB_PSWD,
APIConst.TAG_DB_USER, APIConst.TAG_DB_PSWD, APIConst.TAG_JDBC_URL,
APIConst.TAG_JDBC_DRIVER, APIConst.TAG_JDBC_CONNECTION_OBJECT and the parameter values of the report.APIConst.TAG_PARAM_PREFIX + PARAMETER_NAME,
the value is the value of the parameter.
Example: Running a report with user's JDBC connection object (APIConst.TAG_JDBC_CONNECTION_OBJECT).
//creates the java.sql.Connection object.
java.sql.Connection myCon = java.sql.DriverManager.getConnection(dbUrl);
//sets the parameter APIConst.TAG_JDBC_CONNECTION_OBJECT(jrs.jdbc_connection_object) to run a report.
propParams.put(APIConst.TAG_JDBC_CONNECTION_OBJECT, myCon);
//runs the report using this java.sql.Connection object instead of
//the default DB settings in the catalog.
rptServer.runReportWithTimeouts(userID, catalog, report, propParams, jet.server.api.http.HttpUtil.getReportWaitTimeouts());
timeouts - the timeouts in milliseconds.
java.rmi.RemoteException - if communication-related error occurs during RMI call execution.
boolean isTempResultReady(java.lang.String tempResultName)
throws java.rmi.RemoteException
tempResultName - the temporary result name.
java.rmi.RemoteException - if communication-related error occurs during RMI call execution.
java.lang.String waitTempResultReady(java.lang.String tempResultName)
throws java.rmi.RemoteException
tempResultName - the temporary result name.
java.rmi.RemoteException - if communication-related error occurs during RMI call execution.
ExportedFileList exportResult(java.lang.String userID,
java.lang.String resultFileName,
java.util.Properties props)
throws java.rmi.RemoteException
userID - the user ID.resultFileName - the real file name of the result, for example, c:\jrserver\temp\18238181130.temp.props - the properties APIConst.TAG_RST, APIConst.TAG_PDF,
APIConst.TAG_TEXT, APIConst.TAG_EXCEL and APIConst.TAG_PS. The value of these properties is true or false.
The properties APIConst.TAG_HTML and APIConst.TAG_RTF. The value of these properties is the file name without path (for example: invoice and invoice.rtf).java.rmi.RemoteException - if communication-related error occurs during RMI call execution.
java.lang.String submitScheduledTask(java.lang.String userID,
java.util.Properties propScheduledTask)
throws java.rmi.RemoteException
userID - the user ID.propScheduledTask - the properties of the scheduled task. Please see the
java.rmi.RemoteException - if communication-related error occurs during RMI call execution.
java.util.Vector getScheduledTasks()
throws java.rmi.RemoteException
Vector contains Properties objects. Each Properties
object includes the properties of a scheduled task.
java.rmi.RemoteException - if communication-related error occurs during RMI call execution.
java.util.Properties getScheduledTask(java.lang.String taskID)
throws java.rmi.RemoteException
taskID - the task ID.
java.rmi.RemoteException - if communication-related error occurs during RMI call execution.
boolean removeScheduledTask(java.lang.String taskID)
throws java.rmi.RemoteException
taskID - the task ID.
java.rmi.RemoteException - if communication-related error occurs during RMI call execution.
void removeLargeReport(java.lang.String tempResultName,
boolean isStop)
throws java.rmi.RemoteException
tempResultName - the temporary result name.isStop - whether to stop the running large reports.
java.rmi.RemoteException - if communication-related error occurs during RMI call execution.
Member[] getPredefinedServers()
throws java.rmi.RemoteException
java.rmi.RemoteException - if communication-related error occurs during RMI call execution.
Member[] getAllMembers()
throws java.rmi.RemoteException
java.rmi.RemoteException - if communication-related error occurs during RMI call execution.
int getServerStatus()
throws java.rmi.RemoteException
RemoteException, - if communication-related error occurs during RMI call execution.
java.rmi.RemoteException
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||