All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class oncore.FacadSession

java.lang.Object
   |
   +----oncore.Session
           |
           +----oncore.FacadSession

public class FacadSession
extends Session

Constructor Index

 o FacadSession(HttpServletRequest, Connection)

Method Index

 o printFirst(PrintWriter)
Prints the page the Facad sees on logging in, as well as the all the pages seen subsequently by the Fac-ad.
 o processQuery(HttpServletRequest, PrintWriter)
This method is called whenever the fac-ad submits a form.

Constructors

 o FacadSession
 public FacadSession(HttpServletRequest req,
                     Connection con) throws ValidationException, SQLException

Methods

 o printFirst
 public void printFirst(PrintWriter out) throws SQLException
Prints the page the Facad sees on logging in, as well as the all the pages seen subsequently by the Fac-ad. It prints a list of all students under the fac_ad along with an unchecked checkbox for each course taken by the student.

Parameters:
out - PrintWriter where the output html is written
Throws: SQLException
Thrown in case of sql exceptions while accessing database.
Overrides:
printFirst in class Session
 o processQuery
 public void processQuery(HttpServletRequest req,
                          PrintWriter out) throws SQLException
This method is called whenever the fac-ad submits a form. It first khatches all those student-course registrations for whom the fac_ad has checked the khatch checkbox. In case phase is 2, it also sets fac_ad consent in the regconsent student to Yes, for all checked checkboxes. In case after giving consent to a student for a particular course, it sees that the student also has instructor consent for the same course, it deletes the student-course entry from the regconsent table, adds it to the registration table and sends a mail to the student informing him that his registration is confirmed. Also, any student khatched from any course receives a mail informing him of the fac-ad's decision.

Parameters:
req - The HttpServletRequest
Throws: SQLException
Thrown in case of sql exceptions while accessing database.
Overrides:
processQuery in class Session

All Packages  Class Hierarchy  This Package  Previous  Next  Index