|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objecteschool.ejb._CoursesBean
Constructor Summary | |
_CoursesBean()
|
Method Summary | |
boolean |
addCourse(java.lang.String name,
int owner_id,
java.lang.String summary,
java.lang.String adminPass)
Adds a new course to database. |
void |
addQuestion(int courseID,
int testID,
Question question)
Adds a question to a test |
boolean |
addStudent(Student student,
int courseID,
boolean isNew)
Adds a student to a certain course |
void |
addTest(int courseID,
java.lang.String title,
Question question)
Adds a test to a course. |
boolean |
deleteQuestion(int questionID)
Deletes a question from a test. |
void |
deleteStudent(int studentID)
Deletes a student from database |
void |
deleteTest(int testid)
Deletes a test. |
void |
deleteTests(java.lang.String[] testIDs)
Deletes tests from database |
void |
editSummary(int courseid,
java.lang.String summary)
Changes the summary informatin about a course with the provided string. |
java.util.Vector |
getAllCourses()
|
java.util.Vector |
getAllStudents()
|
java.util.Vector |
getAllStudents(int courseid)
|
java.util.Vector |
getAllTests(int courseID)
|
Course |
getCourseByCourseID(int courseid)
|
Student |
getStudentByID(int id)
|
Student |
getStudentByStudentFN(java.lang.String fn)
|
java.util.Vector |
getStudentCourses(int studentid)
|
java.util.Vector |
getStudentResults(int student_id)
|
Test |
getTestByTestID(int testid)
|
boolean |
isStudentSigned(int courseid,
int studentid)
Checks whether a certain student is signed in a certain course |
boolean |
removeCourses(java.lang.String[] courseIDs,
int ownerid,
java.lang.String adminPass)
Remove courses from database. |
int |
signIn(int courseid,
int studentid)
Signs in a student into a course. |
int |
signOut(int courseid,
int studentid)
Signs out a student from a course. |
void |
test(int i)
internal tests method |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public _CoursesBean()
Method Detail |
public java.util.Vector getAllCourses()
public Course getCourseByCourseID(int courseid)
courseid
-
public void editSummary(int courseid, java.lang.String summary)
courseid
- summary
- public java.util.Vector getAllStudents(int courseid)
courseid
-
public int signIn(int courseid, int studentid)
courseid
- id of the coursestudentid
- id of the student
public int signOut(int courseid, int studentid)
courseid
- id of the coursestudentid
- id of the student
public java.util.Vector getAllTests(int courseID)
courseID
-
public void addTest(int courseID, java.lang.String title, Question question)
courseID
- id of the coursetitle
- title of the testquestion
- first question to the newly created testpublic void deleteTest(int testid)
testid
- id of the testpublic Test getTestByTestID(int testid)
testid
- id of the test
public void addQuestion(int courseID, int testID, Question question)
courseID
- id of the course which test will be edited by adding of this questiontestID
- id of the test which will be edited by adding of this questionquestion
- Question object which will be addedpublic boolean deleteQuestion(int questionID)
questionID
- id of the question
public void deleteStudent(int studentID)
studentID
- id of the studentpublic Student getStudentByStudentFN(java.lang.String fn)
fn
- facultry number (FN) of the student
public boolean addStudent(Student student, int courseID, boolean isNew)
student
- Student to be addedcourseID
- id of the courseisNew
- true if there is no such student in database;
false otherwise
public java.util.Vector getAllStudents()
public Student getStudentByID(int id)
id
- of the student
public boolean isStudentSigned(int courseid, int studentid)
courseid
- id of the coursestudentid
- id of the student
public java.util.Vector getStudentCourses(int studentid)
studentid
- if of the student
public void deleteTests(java.lang.String[] testIDs)
testIDs
- ids of tests that have to be deletedpublic java.util.Vector getStudentResults(int student_id)
student_id
- id of the student
public boolean addCourse(java.lang.String name, int owner_id, java.lang.String summary, java.lang.String adminPass)
name
- name of the new courseowner_id
- id of the lecturer who wants to add the coursesummary
- nummary information about the courseadminPass
- administrator password which allows user to add courses
public boolean removeCourses(java.lang.String[] courseIDs, int ownerid, java.lang.String adminPass)
courseIDs
- ids of courses that have to be removedownerid
- id of lecturer who wants to delete coursesadminPass
- administrator password which allows user to remove courses
public void test(int i)
i
-
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |