All Packages Class Hierarchy This Package Previous Next Index
Class distans.ReadAnswerApplet
java.lang.Object
|
+----java.awt.Component
|
+----java.awt.Container
|
+----java.awt.Panel
|
+----java.applet.Applet
|
+----distans.ReadAnswerApplet
- public class ReadAnswerApplet
- extends Applet
The MakePageApplet is the Applet that lets the teatcher read the students answers.
When starting the Applet the following is done.
1. The password dialog is shown, which the user except for username/password confirmation uses to choose a subject.
2. The Information of the QuestionPages and the students answers are loaded from the server.
-
button1
-
-
cedula
-
-
correctLabel
-
-
currentPage
- The pageTitle of the QuestionPage currently beeing displayed
-
currentPanel
-
-
currentShowPanel
- A Panel that implements interface ShowPanelInterface.
-
currentType
- The currentType of QuestionPage
-
dl
- The Dataloader object responsible for communication with the server as well as having references to the data stuctures.
-
msgBox
- A message box
-
next
-
-
overview
-
-
overviewTA
- The textArea used to diplay the overview
-
pageSelect
-
-
pageTitleLabel
-
-
prev
-
-
pw
- The password dialog
-
studentLabel
-
-
studentSelect
-
-
tabPanel1
-
-
totAlt
-
-
totAnsweredLabel
-
-
totCorrectLabel
-
-
totCross
-
-
totPanel
-
-
wPanel
- The panel used for displaying QuestionPages of type written
-
ReadAnswerApplet()
-
-
cedula_ItemStateChanged(ItemEvent)
-
-
getNoOfCorrects(String, String)
-
-
giveOverview()
- Presents an overview of all the students answers for the selected QuestionPage.
-
init()
- This method is called by the browser when the applet starts.
-
initPages()
- Adds QuestionPages already created for the given subject to the page select list
This is only called on startup
-
initStudents()
- Called at startup, this method puts all the students loaded by the datalaoder into the student selection list
-
next_ActionPerformed(ActionEvent)
-
-
overview_ItemStateChanged(ItemEvent)
-
-
pageSelect_DblClicked(ActionEvent)
-
-
prev_ActionPerformed(ActionEvent)
-
-
putPage()
- If the overview checkbox is marked giveOverview is called otherwise the current
QuestionPage and student answer are displayed
-
putPage(String, String)
- Puts a new QuestionPage on the screen.
-
setAllEnabled(boolean)
- Help method for setting the buttons enabled or not enabled.
-
showTotalCorrects(String)
- Calculates and displays the total number of correct answers for the total panel
-
studentSelect_DblClicked(ActionEvent)
-
-
summeryButton_Clicked(ActionEvent)
- Calls the script getAllAnswers.perl and displays the returned HTML in a new browser window
currentType
private int currentType
- The currentType of QuestionPage
dl
private DataLoader dl
- The Dataloader object responsible for communication with the server as well as having references to the data stuctures.
currentPage
private String currentPage
- The pageTitle of the QuestionPage currently beeing displayed
currentShowPanel
private ShowPanelInterface currentShowPanel
- A Panel that implements interface ShowPanelInterface.
The Panel is currently one of the following ThreeCrossPanel TwoALtPanel or WrittenPAnel.
The Panel handles flipping between the subquestions i.e. button ">" & "<".
msgBox
private MsgBox msgBox
- A message box
pw
private pwBean pw
- The password dialog
tabPanel1
TabPanel tabPanel1
currentPanel
Panel currentPanel
correctLabel
Label correctLabel
totPanel
Panel totPanel
totAnsweredLabel
Label totAnsweredLabel
totCorrectLabel
Label totCorrectLabel
studentLabel
Label studentLabel
pageTitleLabel
Label pageTitleLabel
studentSelect
List studentSelect
pageSelect
List pageSelect
prev
Button prev
next
Button next
cedula
Checkbox cedula
button1
Button button1
overview
Checkbox overview
totCross
ThreeCrossPanels totCross
totAlt
TwoAltPanels totAlt
wPanel
writtenPanel wPanel
- The panel used for displaying QuestionPages of type written
overviewTA
TextArea overviewTA
- The textArea used to diplay the overview
ReadAnswerApplet
public ReadAnswerApplet()
init
public void init()
- This method is called by the browser when the applet starts. All graphical components are added here, even though all three Panels
are added to the Applet they are not visible.
- Overrides:
- init in class Applet
putPage
public void putPage()
- If the overview checkbox is marked giveOverview is called otherwise the current
QuestionPage and student answer are displayed
putPage
public void putPage(String pageTitle,
String cedulaNo)
- Puts a new QuestionPage on the screen. If the new QuestionPage is of a different page type than then the old, the old one is hidden and the new one shown.
Some buttons enable mode are changed depending on the QuestionPage. e.g. only pages of type Cross will have the RandomButton enabled.
- Parameters:
- pageTitle - the page to display.
giveOverview
void giveOverview()
- Presents an overview of all the students answers for the selected QuestionPage.
Only the students grade are shown.
summeryButton_Clicked
void summeryButton_Clicked(ActionEvent event)
- Calls the script getAllAnswers.perl and displays the returned HTML in a new browser window
setAllEnabled
private void setAllEnabled(boolean enabl)
- Help method for setting the buttons enabled or not enabled.
initStudents
protected void initStudents()
- Called at startup, this method puts all the students loaded by the datalaoder into the student selection list
initPages
protected void initPages()
- Adds QuestionPages already created for the given subject to the page select list
This is only called on startup
getNoOfCorrects
int getNoOfCorrects(String pageTitle,
String cedulaNo)
- Returns:
- s the number of correctly answered subquestions that a student has made for a QuestionPage
showTotalCorrects
void showTotalCorrects(String cedulaNo)
- Calculates and displays the total number of correct answers for the total panel
- Parameters:
- cedulaNo - the cedula of the student whos data shall be displayed.
next_ActionPerformed
void next_ActionPerformed(ActionEvent event)
prev_ActionPerformed
void prev_ActionPerformed(ActionEvent event)
pageSelect_DblClicked
void pageSelect_DblClicked(ActionEvent event)
studentSelect_DblClicked
void studentSelect_DblClicked(ActionEvent event)
cedula_ItemStateChanged
void cedula_ItemStateChanged(ItemEvent event)
overview_ItemStateChanged
void overview_ItemStateChanged(ItemEvent event)
All Packages Class Hierarchy This Package Previous Next Index