Package ejava.examples.webtier.bl
Class RegistrarImpl
- java.lang.Object
-
- ejava.examples.webtier.bl.RegistrarImpl
-
-
Field Summary
Fields Modifier and Type Field Description private StudentDAO
dao
private static String
GRAD_QUERY
(package private) org.slf4j.Logger
logger
private static String
NEW_STUDENT_QUERY
-
Constructor Summary
Constructors Constructor Description RegistrarImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Student
addStudent(Student student)
Student
completeCourse(Student student, Grade grade)
Student
dropStudent(Student student)
List<Student>
getGraduatingStudents(int index, int count)
List<Student>
getNewStudents(int index, int count)
Student
getStudent(long id)
List<Student>
getStudents(int index, int count)
List<Student>
getStudents(String queryName, Map<String,Object> params, int index, int count)
void
setStudentDAO(StudentDAO dao)
-
-
-
Field Detail
-
logger
org.slf4j.Logger logger
-
NEW_STUDENT_QUERY
private static final String NEW_STUDENT_QUERY
- See Also:
- Constant Field Values
-
GRAD_QUERY
private static final String GRAD_QUERY
- See Also:
- Constant Field Values
-
dao
private StudentDAO dao
-
-
Method Detail
-
setStudentDAO
public void setStudentDAO(StudentDAO dao)
-
addStudent
public Student addStudent(Student student) throws RegistrarException
- Specified by:
addStudent
in interfaceRegistrar
- Throws:
RegistrarException
-
completeCourse
public Student completeCourse(Student student, Grade grade) throws RegistrarException
- Specified by:
completeCourse
in interfaceRegistrar
- Throws:
RegistrarException
-
dropStudent
public Student dropStudent(Student student) throws RegistrarException
- Specified by:
dropStudent
in interfaceRegistrar
- Throws:
RegistrarException
-
getStudents
public List<Student> getStudents(int index, int count) throws RegistrarException
- Specified by:
getStudents
in interfaceRegistrar
- Throws:
RegistrarException
-
getGraduatingStudents
public List<Student> getGraduatingStudents(int index, int count) throws RegistrarException
- Specified by:
getGraduatingStudents
in interfaceRegistrar
- Throws:
RegistrarException
-
getNewStudents
public List<Student> getNewStudents(int index, int count) throws RegistrarException
- Specified by:
getNewStudents
in interfaceRegistrar
- Throws:
RegistrarException
-
getStudent
public Student getStudent(long id) throws RegistrarException
- Specified by:
getStudent
in interfaceRegistrar
- Throws:
RegistrarException
-
getStudents
public List<Student> getStudents(String queryName, Map<String,Object> params, int index, int count) throws RegistrarException
- Specified by:
getStudents
in interfaceRegistrar
- Throws:
RegistrarException
-
-