private void _schedule(Activity a,long startTime){
  if (a.isScheduled()) {
    try {
      notifyAll();
    }
 catch (    Exception e) {
    }
    return;
  }
  a.setStartTime(startTime);
synchronized (this) {
    m_activities.add(a);
    a.setScheduled(true);
    if (startTime < m_nextTime) {
      m_nextTime=startTime;
      notify();
    }
  }
}

private void _schedule ( Activity a , long startTime ) { if ( a . isScheduled ( ) ) { try { notifyAll ( ) ; } catch ( Exception e ) { } return ; } a . setStartTime ( startTime ) ; synchronized ( this ) { m_activities . add ( a ) ; a . setScheduled ( true ) ; if ( startTime < m_nextTime ) { m_nextTime = startTime ; notify ( ) ; } } }
schedules an activity with the manager .
