private Collection transferAttends(final IPersistentObject persistentObject, final Integer[] curricularCourseIdsToTransfer, Collection attends, final IExecutionCourse destinationExecutionCourse) throws ExcepcaoPersistencia {  final Set transferedStudents = new HashSet();  for (IAttends attend : (List<IAttends>) attends) { if (attend.getEnrolment() != null && contains(curricularCourseIdsToTransfer, attend.getEnrolment() .getCurricularCourse().getIdInternal())) { persistentObject.simpleLockWrite(attend); attend.setDisciplinaExecucao(destinationExecutionCourse);  transferedStudents.add(attend.getAluno().getIdInternal());
private void transferAttends(final IExecutionCourse originExecutionCourse, final IExecutionCourse destinationExecutionCourse) { final List<ICurricularCourse> curricularCourses = destinationExecutionCourse.getAssociatedCurricularCourses(); for (int i = 0; i < originExecutionCourse.getAttends().size(); i++) { final IAttends attends = originExecutionCourse.getAttends().get(i); final IEnrolment enrolment = attends.getEnrolment(); if (enrolment != null && curricularCourses.contains(enrolment.getCurricularCourse())) { attends.setDisciplinaExecucao(destinationExecutionCourse); i--;
    private Collection transferAttends(final IPersistentObject persistentObject,            final Integer[] curricularCourseIdsToTransfer, Collection attends,            final IExecutionCourse destinationExecutionCourse) throws ExcepcaoPersistencia {        final Set transferedStudents = new HashSet();        for (IAttends attend : (List<IAttends>) attends) {            if (attend.getEnrolment() != null                    && contains(curricularCourseIdsToTransfer, attend.getEnrolment()                            .getCurricularCourse().getIdInternal())) {                persistentObject.simpleLockWrite(attend);                attend.setDisciplinaExecucao(destinationExecutionCourse);                transferedStudents.add(attend.getAluno().getIdInternal());            }        }        return transferedStudents;    }