class EntryImpl implements ISchedulerEntry {

    @Override
    public void scheduleNext(final long time)
            throws EntryScheduleException {
        try {
            ITimerTask tt = timerTask.get();

            if (null == tt) {
                if (isCancelled) {
                    // This entry is a "zombie"
                    try {
                        storage.delete(this);
                    } catch (EntryNotFoundException ignore) {
                        // Someone else has killed this zombie
                    }

                    return;
                }

                tt = this.timerTask.getAndSet(storage.getTimer().schedule(this.task, time));

                if (null != tt) {
                    tt.cancel();
                }
            } else {
                tt.reschedule(time);
            }

            lastScheduledTime = time;

            // Will create "zombie" if this entry was cancelled after timerTask.get() call
            storage.notifyActive(this);
        } catch (TaskScheduleException | EntryStorageAccessException e) {
            throw new EntryScheduleException("Could not reschedule entry.", e);
        }
    }

      EntryImpl(
            final IObject state,
            final ISchedulingStrategy strategy,
            final ISchedulerEntryStorage storage,
            final ISchedulerAction action,
            final boolean isSavedRemotely);

}