quicktime.app.time
Interface Taskable

All Known Implementing Classes:
Tasking

public interface Taskable

An object can implement this interface to have a managed periodic call of the task method from the TaskThread class


Field Summary
static TaskThread tasker
          The "system" creates a default TaskThread for all taskable objects.
 
Method Summary
 void addedToTasker(TaskThread t)
          This is called by a TaskThread when an object is added to a TaskThread.
 TaskThread getTasker()
          This should return the task thread that the Taskable object is currently being tasked by or null if not being tasked.
 void removedFromTasker()
          This is called by a TaskThread when an object is removed from a TaskThread.
 void startTasking()
          This will start tasking the Timeable object.
 void stopTasking()
          This will stop tasking the Timeable object.
 void task()
          This method is defined as a method that is called periodically to perform tasks.
 

Field Detail

tasker

public static final TaskThread tasker
The "system" creates a default TaskThread for all taskable objects.
Method Detail

task

public void task()
          throws QTException
This method is defined as a method that is called periodically to perform tasks. For example MoviePlayer's task method calls MoviesTask to draw the movie to the screen.

getTasker

public TaskThread getTasker()
This should return the task thread that the Taskable object is currently being tasked by or null if not being tasked.
Returns:
a TaskThread object or null.

addedToTasker

public void addedToTasker(TaskThread t)
This is called by a TaskThread when an object is added to a TaskThread. The parameter is the TaskThread that the object is being added to.
Parameters:
t - the TaskThread

removedFromTasker

public void removedFromTasker()
This is called by a TaskThread when an object is removed from a TaskThread. It is removedFrom the TaskThread that it was added to and a Taskable can only be in one TaskThread object.
Parameters:
t - the TaskThread

startTasking

public void startTasking()
This will start tasking the Timeable object.

stopTasking

public void stopTasking()
This will stop tasking the Timeable object.