private IScheduledActivity _getPresentation() { if (_presentation == null) { IScheduledActivity lastActivity = _activites.Last(); DateTime lastTime = lastActivity.getEnd(); _presentation = new ScheduledActivity( new Activity("Staff Motivation Presentation"), lastActivity.getEnd() ); } return(_presentation); }
private DateTime getNextSlot(IActivity activity) { DateTime nextTime = _scheduleManager.getStartTime(); if (_activites.Count > 0) { IScheduledActivity lastActivity = _activites.Last(); if (lastActivity != null) { DateTime lastTime = lastActivity.getEnd(); int duration = activity.getDuration(); nextTime = _scheduleManager.getTimeSlot(lastTime, duration); } } return(nextTime); }