added methods to add end time.