JDBC removed...
This commit is contained in:
@ -83,11 +83,15 @@ public final class App {
|
||||
/* Add student in respectibe db */
|
||||
mapper.insert(student);
|
||||
|
||||
if (log.isDebugEnabled()) {
|
||||
log.debug("App.main(), student : " + student + ", is inserted");
|
||||
}
|
||||
|
||||
/* Find this student */
|
||||
final Optional<Student> studentToBeFound = mapper.find(student.getStudentId());
|
||||
|
||||
if (log.isDebugEnabled()) {
|
||||
log.debug("App.main(), db find returned : " + studentToBeFound);
|
||||
log.debug("App.main(), student : " + studentToBeFound + ", is searched");
|
||||
}
|
||||
|
||||
/* Update existing student object */
|
||||
@ -96,7 +100,15 @@ public final class App {
|
||||
/* Update student in respectibe db */
|
||||
mapper.update(student);
|
||||
|
||||
if (log.isDebugEnabled()) {
|
||||
log.debug("App.main(), student : " + student + ", is updated");
|
||||
}
|
||||
|
||||
/* Delete student in db */
|
||||
|
||||
if (log.isDebugEnabled()) {
|
||||
log.debug("App.main(), student : " + student + ", is deleted");
|
||||
}
|
||||
mapper.delete(student);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user