(**** * * Module StudentTesting defines the objects and operations related Student users * such as completing a test, submitting a test and viewing options. * * Note: The overall modeling of Testtool is still in progress. The organization * of various modules, objects and operations are subject to change. I included some * imports and exports but these are likely to change as we restructure our modeling. * *) module StudentTesting; from Proctoring import Proctor_Comments, Test_Comments; from Publish import PublishedTest; export CompletedTest; object CompletedTest inherits from PublishedTest components: completed_qs:CompletedQuestion* and test_qs:TestQuestions and student_ID:StudentID and proctor_ID:ProctorID and student_comments:StudentComment* and proctor_comments:ProctorComment* and test_comments:TestComment* and start_time:StartTime and submit_time:SubmitTime; description: (* The CompletedTest adds several components to the PublishedTest. The CompletedQuestions include the Student's answer to a question. THe TestQuestions are any questions left unanswered by a student. The StudentID and ProctorID identify the student who completed the exam and the proctor who administered it respectively. StudentComments are created by students while TestComments are from the Proctor. Both of these comment type are directed to the instructor and pertain to the exam. ProctorComments are also from Proctors but they are directed at the students and are included with the exam for reference. StartTime is the time that a proctored test is distributed or when a take-home test is downloaded. SubmitTime is the time that the test is collected by the proctor or submitted by the student. *); end CompletedTest; object CompletedQuestions is (* *); object StudentID is string description: (* The unique id of a Student user. *); end; object ProctorID is string description: (* The unique id of a Proctor user. *); end; object StudentComments is components: sc_type:StudentCommentType and c_body:CommentBody; description: (* The student comments are either general (about overall test) or specific (related to specific questions), as specified by student. The text of the comment is contained in CommentBody. *); end; object CommentBody is string description: (* The text of a comment. *); end; object StudentCommentType is GeneralSC or SpecificSC description: (* StudentCommentType can be specified as a general comment or as a specific comment. *); end; object GeneralSC description: (* Built-in type of Student comment. (A comment which does not refer to a specific part of a test *); end; object SpecificSC components: q_IDs:QuestionID*; description: (* Built-in type of Student comment. SpecificSC comments refer to QuestionIDs to specific questions on a test which are identified by the QuestionIDs. *); end; object QuestionID is string description: (* The unique id of a question. *); end; object StartTime is DateTime description: (* The time and date at which a take-home test was downloaded or when a proctored test was released to students. *); end StartTime; object SubmitTime is DateTime description: (* The time and date at which a take-home or proctored test was released to students. *); end SubmitTime; object DateTime is components: Date and Time; description: (* Combination of the date and time. *); end DateTime; object Date is day:DayNumber and month:MonthNumber and year:Year description: (* A Date is the basic unit of calendar time keeping, consisting of numeric date, month, and year. *); end Date; object DayNumber is integer description: (* The two-digit number for the day. *); end DayNumber; object MonthNumber is integer description: (* The two-digit number for the month. (Yes, this Calendar Tool has a Y10K problem.) *); end MonthNumber; object Year is integer description: (* The four-digit year number. *); end Year; object Time is hour:Hour and minute:Minute and am_or_pm:AmOrPm description: (* A Time consists of an hour, minute, and AM or PM indicator. A time value is expressed using a 12-hour or 24-hour clock style. The clock style is set as an option by the user. If the clock style is 24-hour, the AmOrPm indicator is nil. *); end Time; object Hour is integer description: (* The hour component of a time value, between 1 and 12 or 0 and 24 based on the clock style in use. *); end Hour; object Minute is integer description: (* The minute component of a time value, between 0 and 59. *); end Minute; object AmOrPm is AM or PM description: (* Standard suffix used in 12-hour time value. *); end AmOrPm; object AM description: (* The 12-hour time suffix indicating a morning time. *); end; object PM description: (* The 12-hour time suffix indicating an afternoon time. *); end; operation AnswerQuestion is inputs: test_q:TestQuestion; outputs: complete_q:CompletedQuestion; description: (* Changes the TestQuestion by adding the Student's answer. *); precondition: ; postcondition: ; end AnswerQuestion; operation SubmitTest is inputs: PublishedTest; outputs: CompletedTest; end; end StudentTesting;