E hecho este codigo para saber si el grado introducido existe en la interface general grade existe pero quiero saber si se puede reducir el if del errorGrade
public class Student implements DataGeneral, ErrorDataGeneral, ErrorLenghtData, ErrorGrade, GeneralGrade{
public Student(String gradeStudent) {
this.gradeStudent = gradeStudent;
}
@Override
public void errorGrade() throws GradeException {
if (!(GeneralGrade.GRADE_CUARTO.equals(gradeStudent) || GeneralGrade.GRADE_DECIMO.equals(gradeStudent)
|| GeneralGrade.GRADE_KINDER.equals(gradeStudent) || GeneralGrade.GRADE_NOVENO.equals(gradeStudent)
|| GeneralGrade.GRADE_OCTAVO.equals(gradeStudent) || GeneralGrade.GRADE_ONCE.equals(gradeStudent)
|| GeneralGrade.GRADE_PRIMERO.equals(gradeStudent) || GeneralGrade.GRADE_QUINTO.equals(gradeStudent)
|| GeneralGrade.GRADE_SEGUNDO.equals(gradeStudent) || GeneralGrade.GRADE_SEPTIMO.equals(gradeStudent)
|| GeneralGrade.GRADE_SEXTO.equals(gradeStudent) || GeneralGrade.GRADE_TERCERO.equals(gradeStudent)
|| GeneralGrade.GRADE_TRANSICION.equals(gradeStudent))) {
throw new GradeException("El grado en el que estas no esta disponible");
}
}
private String gradeStudent = "";}