railo.runtime.schedule
Interface Scheduler

All Known Implementing Classes:
SchedulerImpl

public interface Scheduler

Scheduler interface


Method Summary
 void addScheduleTask(ScheduleTask task, boolean allowOverwrite)
          Adds a Task to the scheduler
 void execute()
          Deprecated. task are self controlled no longer controlled by a controller thread
 ScheduleTask[] getAllScheduleTasks()
          returns all schedule tasks valid or not
 LogAndSource getLogger()
           
 long getNextExecutionTime()
          Deprecated. task are self controlled no longer controlled by a controller thread
 ScheduleTask getScheduleTask(String name)
          returns a schedule tasks matching given name or throws a exception
 ScheduleTask getScheduleTask(String name, ScheduleTask defaultValue)
          returns a schedule tasks matching given name or null
 void removeScheduleTask(String name, boolean throwWhenNotExist)
          removes a task from scheduler
 void runScheduleTask(String name, boolean throwWhenNotExist)
          runs a scheduler task
 

Method Detail

getScheduleTask

ScheduleTask getScheduleTask(String name)
                             throws ScheduleException
returns a schedule tasks matching given name or throws a exception

Parameters:
name - Task name of Schedule Task to get
Returns:
matching task
Throws:
ScheduleException

getAllScheduleTasks

ScheduleTask[] getAllScheduleTasks()
returns all schedule tasks valid or not

Returns:
all tasks

getScheduleTask

ScheduleTask getScheduleTask(String name,
                             ScheduleTask defaultValue)
returns a schedule tasks matching given name or null

Parameters:
name - Task name of Schedule Task to get
defaultValue -
Returns:
matching task

addScheduleTask

void addScheduleTask(ScheduleTask task,
                     boolean allowOverwrite)
                     throws ScheduleException,
                            IOException
Adds a Task to the scheduler

Parameters:
task -
allowOverwrite -
Throws:
ScheduleException
IOException

removeScheduleTask

void removeScheduleTask(String name,
                        boolean throwWhenNotExist)
                        throws IOException,
                               ScheduleException
removes a task from scheduler

Parameters:
name - name of the task to remove
throwWhenNotExist - define if method throws a exception if task doesn't exist
Throws:
IOException
ScheduleException

runScheduleTask

void runScheduleTask(String name,
                     boolean throwWhenNotExist)
                     throws IOException,
                            ScheduleException
runs a scheduler task

Parameters:
name -
throwWhenNotExist -
Throws:
IOException
ScheduleException

execute

void execute()
Deprecated. task are self controlled no longer controlled by a controller thread

execute all containing tasks


getNextExecutionTime

long getNextExecutionTime()
Deprecated. task are self controlled no longer controlled by a controller thread

Returns:
Returns the nextExecutionTime.

getLogger

LogAndSource getLogger()
Returns:
Returns the logFile.


Copyright © 2012 Railo