if(summary.getProfessorship() != null && !summary.getProfessorship().equals(professorshipLogged)){ System.out.println("************************111111111111111111111");
if(summary.getProfessorship() != null && !summary.getProfessorship().equals(professorshipLogged)){
    private boolean isTeacherExecutionCourseMember(List teachers, Object[] arguments, IUserView userView) throws ExcepcaoPersistencia {               ISummary summary = getSummary(arguments);        ISuportePersistente sp = SuportePersistenteOJB.getInstance();        IPersistentTeacher persistentTeacher = sp.getIPersistentTeacher();               IPersistentProfessorship persistentProfessorship = sp.getIPersistentProfessorship();        IPersistentExecutionCourse persistentExecutionCourse = sp.getIPersistentExecutionCourse();                ITeacher teacherLogged = persistentTeacher.readTeacherByUsername(userView.getUtilizador());        IExecutionCourse executionCourse = (IExecutionCourse) persistentExecutionCourse.readByOID(ExecutionCourse.class,  ((Integer)arguments[0]));        IProfessorship professorshipLogged = persistentProfessorship.readByTeacherAndExecutionCourse(teacherLogged, executionCourse);                       if(summary.getProfessorship() != null && !summary.getProfessorship().equals(professorshipLogged)){            System.out.println("************************111111111111111111111");            return true;        }        if(summary.getTeacher() != null){            IProfessorship professorship = persistentProfessorship.readByTeacherAndExecutionCourse(summary.getTeacher(), executionCourse);            if(teachers.contains(professorship) && !summary.getTeacher().equals(teacherLogged)){                System.out.println("************************222222222222222222222");                return true;            }        }       return false;    }