.equals(currentExecutionPeriod.getIdInternal()) || klass.getExecutionPeriod() .getIdInternal().equals(nextExecutionPeriod.getIdInternal()))
.equals(currentExecutionPeriod.getIdInternal()) || (nextExecutionPeriod != null && klass.getExecutionPeriod() .getIdInternal().equals(nextExecutionPeriod.getIdInternal())))
    private boolean isInPeriodsAndForDegree(ITurma klass, ICurso degree,            IExecutionPeriod currentExecutionPeriod, IExecutionPeriod nextExecutionPeriod) {        return (klass.getExecutionPeriod().getIdInternal()                .equals(currentExecutionPeriod.getIdInternal()) || klass.getExecutionPeriod()                .getIdInternal().equals(nextExecutionPeriod.getIdInternal()))                && klass.getExecutionDegree().getCurricularPlan().getDegree().getIdInternal().equals(                        degree.getIdInternal());    }