Class Scheduler

java.lang.Object
  |
  +--Scheduler

public class Scheduler
extends java.lang.Object

Scheduler is a class that allows addition, removal, and retrieval of a list of events, sorted by their occurrence time.

Version:
1.0

Constructor Summary
Scheduler()
           This will initialize the storage.
 
Method Summary
 boolean addEvent(java.lang.String eventName, java.util.Date eventTime)
           This will add the requested event.
 java.util.Vector getListOfEvents()
           This will return the current listing of events.
 boolean removeEvent(java.lang.String eventName)
           This will remove the requested event.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Scheduler

public Scheduler()

This will initialize the storage.

Method Detail

addEvent

public boolean addEvent(java.lang.String eventName,
                        java.util.Date eventTime)

This will add the requested event.

Parameters:
eventName - String name of event to add.
eventTime - Date of event.
Returns:
boolean - indication of if event was added.

removeEvent

public boolean removeEvent(java.lang.String eventName)

This will remove the requested event.

Parameters:
eventName - String name of event to remove.
Returns:
boolean - indication of if event was removed.

getListOfEvents

public java.util.Vector getListOfEvents()

This will return the current listing of events.

Returns:
Vector - list of events.