sp.getITurnoPersistente().lockWrite(shift); shift.getAssociatedLessons().add(aula);
InfoShiftServiceResult infoShiftServiceResult = valid(shift, aula);  if (infoShiftServiceResult.isSUCESS()) { sp.getITurnoPersistente().lockWrite(shift); shift.getAssociatedLessons().add(aula); } else { throw new InvalidLoadException(infoShiftServiceResult.toString()); }
	public InfoLessonServiceResult run(		InfoLesson infoLesson,		InfoShift infoShift)		throws FenixServiceException {		InfoLessonServiceResult result = null;		try {			ISuportePersistente sp = SuportePersistenteOJB.getInstance();			ISala sala =				sp.getISalaPersistente().readByName(					infoLesson.getInfoSala().getNome());			IDisciplinaExecucaoPersistente executionCourseDAO =				sp.getIDisciplinaExecucaoPersistente();			IExecutionPeriod executionPeriod =				Cloner.copyInfoExecutionPeriod2IExecutionPeriod(					infoLesson						.getInfoDisciplinaExecucao()						.getInfoExecutionPeriod());			IDisciplinaExecucao executionCourse =				executionCourseDAO					.readByExecutionCourseInitialsAndExecutionPeriod(					infoLesson.getInfoDisciplinaExecucao().getSigla(),					executionPeriod);			IAula aula =				new Aula(					infoLesson.getDiaSemana(),					infoLesson.getInicio(),					infoLesson.getFim(),					infoLesson.getTipo(),					sala,					executionCourse);			result = validTimeInterval(aula);			if (result.getMessageType() == 1) {				throw new InvalidTimeIntervalServiceException();			}			boolean resultB = validNoInterceptingLesson(aula, executionPeriod);			if (result.isSUCESS() && resultB) {				try {					sp.getIAulaPersistente().lockWrite(aula);					ITurno shift =						(ITurno) sp.getITurnoPersistente().readByOID(							Turno.class,							infoShift.getIdInternal());					sp.getITurnoPersistente().lockWrite(shift);					shift.getAssociatedLessons().add(aula);				} catch (ExistingPersistentException ex) {					throw new ExistingServiceException(ex);				}			} else {				result.setMessageType(2);			}		} catch (ExcepcaoPersistencia ex) {			throw new FenixServiceException(ex.getMessage());		}		return result;	}