EspressReport 6.6

quadbase.scheduler
Class ScheduleModifier

java.lang.Object
  extended by quadbase.scheduler.ScheduleModifier

public class ScheduleModifier
extends java.lang.Object

Contains static API methods to manage tasks in the scheduler. A typical use of this class involves the following:

 
      // first connect to Espress Manager
      ScheduleModifier.connectServer(null);
 
      // allocate the ScheduleObject
 ScheduleObject sObj = ...;
      // set the desired settings for this schedule task
 sObj.setFileLocation("Templates/SAMPLE.rpt");
      // ...
      // add the task (ScheduleObject) to the scheduler
 ScheduleModifier.addScheduleTask(sObj);
 
 


Constructor Summary
ScheduleModifier()
           
 
Method Summary
static void addScheduleTask(ScheduleObject schObj)
          Adds Schedule Task into Scheduler
static void connectServer(java.lang.Object object)
          Connects to server
static java.util.Vector<ScheduleObject> getScheduleList()
          Returns Vector of ScheduleObject which are waiting to export
static java.util.Vector<ScheduleObject> getScheduleList(java.lang.String searchTips)
          Returns Vector of ScheduleObject which are waiting to export and contains the searchTips in either export location or schedule job name
static java.lang.String getServletContext()
          Returns servlet context
static void modifyScheduleTask(ScheduleObject schObj, int idx)
          Modifies ScheduleObject in specific index
static void removeScheduleTask(ScheduleObject schObj)
          Removes Schedule Object from scheduler
static void saveScheduleTask()
          Asks server to write the schedule task job to file so schedule job remains when user restarts server
static void setServerAddress(java.lang.String address)
          Sets the server address of EspressManager.
static void setServerHosts(java.util.Vector<java.lang.String> hostnames)
          Sets the list of host names for EspressManager when tunneling is used.
static void setServerPortNumber(int port)
          Sets the port number of EspressManager.
static void setServletContext(java.lang.String context)
          Sets servlet context
static void setServletRunner(java.lang.String comm_url)
          Sets servlet runner hostname and port number
static void useServlet(boolean b)
          Determines whether to use SOCKET or HTTP or SERVLET for chart server connection
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ScheduleModifier

public ScheduleModifier()
Method Detail

connectServer

public static void connectServer(java.lang.Object object)
Connects to server

Parameters:
object - can be null, applet or frame

setServerAddress

public static void setServerAddress(java.lang.String address)
                             throws java.net.UnknownHostException
Sets the server address of EspressManager. Use this address instead of the one provided in the espressmanager.cfg file. It also eliminates the need of the espressmanager.cfg file in the working directory.

Throws:
java.net.UnknownHostException

setServerPortNumber

public static void setServerPortNumber(int port)
Sets the port number of EspressManager. Use this port number instead of the one provided in the espressmanager.cfg file. It also eliminates the need of the espressmanager.cfg file in the working directory.


setServerHosts

public static void setServerHosts(java.util.Vector<java.lang.String> hostnames)
Sets the list of host names for EspressManager when tunneling is used. Use these hosts along with the ones provided in the espressmanager.cfg file. If the espressmanager.cfg file is not present, then only these hosts will be used.


setServletRunner

public static void setServletRunner(java.lang.String comm_url)
Sets servlet runner hostname and port number

Parameters:
comm_url - servlet runner hostname and port number

useServlet

public static void useServlet(boolean b)
Determines whether to use SOCKET or HTTP or SERVLET for chart server connection

Parameters:
b - If true use SERVLET connection, otherwise use other connection The default value is false.

getServletContext

public static java.lang.String getServletContext()
Returns servlet context


setServletContext

public static void setServletContext(java.lang.String context)
Sets servlet context


getScheduleList

public static java.util.Vector<ScheduleObject> getScheduleList()
                                                        throws java.lang.Exception
Returns Vector of ScheduleObject which are waiting to export

Throws:
java.lang.Exception

getScheduleList

public static java.util.Vector<ScheduleObject> getScheduleList(java.lang.String searchTips)
                                                        throws java.lang.Exception
Returns Vector of ScheduleObject which are waiting to export and contains the searchTips in either export location or schedule job name

Throws:
java.lang.Exception

modifyScheduleTask

public static void modifyScheduleTask(ScheduleObject schObj,
                                      int idx)
                               throws java.lang.Exception
Modifies ScheduleObject in specific index

Parameters:
schObj - new ScheduleObject
Throws:
java.lang.Exception

addScheduleTask

public static void addScheduleTask(ScheduleObject schObj)
                            throws java.lang.Exception
Adds Schedule Task into Scheduler

Parameters:
schObj - new ScheduleObject
Throws:
java.lang.Exception

removeScheduleTask

public static void removeScheduleTask(ScheduleObject schObj)
                               throws java.lang.Exception
Removes Schedule Object from scheduler

Parameters:
schObj - the scheduleObject that user wants to remove
Throws:
java.lang.Exception

saveScheduleTask

public static void saveScheduleTask()
                             throws java.lang.Exception
Asks server to write the schedule task job to file so schedule job remains when user restarts server

Throws:
java.lang.Exception

EspressReport 6.6