|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectscheduler.db.coursedb.Course
public class Course
This class will contain the information necessary to represent a course available to the instructor, such as its name and required equipment.
Nested Class Summary | |
---|---|
class |
Course.RequiredEquipment
This class specifies the required equipment for a course. |
Field Summary | |
---|---|
(package private) java.lang.String |
courseName
Name of course. |
(package private) java.lang.String |
courseType
Type of course. |
(package private) int |
id
Id of course |
(package private) Course |
labPairing
Corresponding lab. |
(package private) int |
maxEnrollment
Maximum enrollment of course. |
(package private) int |
numOfSections
Number of sections for course. |
(package private) Course.RequiredEquipment |
requiredEquipment
Required equipment in course. |
(package private) int |
scu
Student Course Units. |
(package private) int |
wtu
Work-Time Units. |
Constructor Summary | |
---|---|
Course(Course c)
Returns a new course, whose fields are an exact copy of the given course |
|
Course(java.lang.String courseName,
int id,
int wtu,
int scu,
java.lang.String courseType,
int maxEnrollment,
int numOfSections,
Course labPairing,
boolean smartroom,
boolean overhead,
boolean connectivity)
This constructor will create a course with all required information. |
|
Course(java.lang.String courseName,
int id,
int wtu,
int scu,
java.lang.String courseType,
int maxEnrollment,
int numOfSections,
Course labPairing,
Course.RequiredEquipment requiredEquipment)
Constructs the Course with the complete required information. |
Method Summary | |
---|---|
boolean |
equals(java.lang.Object o)
Returns whether this course is equal to the given object. |
java.lang.String |
getCourseName()
Returns the coursename as a string |
java.lang.String |
getCourseType()
Returns the type of this course. |
int |
getId()
Returns the id of the class |
Course |
getLabPairing()
Returns the lab pairing. |
int |
getMaxEnrollment()
Returns the maximum enrollment. |
int |
getNumberOfSections()
Returns the number of sections. |
Course.RequiredEquipment |
getRequiredEquipment()
Returns the class container for required equipment in course. |
int |
getSCUs()
Get the scu for this course. |
int |
getSection()
Returns the section for this course. |
int |
getWTU()
Returns the work time unit |
int |
getWTUs()
Returns the wtus |
boolean |
hasLab()
Returns whether the given course has a lab. |
boolean |
isLab()
Returns whether the given course is a lab. |
boolean |
isValidCourse(Course course)
Returns whether this is a valid course. |
boolean |
isValidCourseDB()
Returns whether the current database is valid. |
void |
setSection(int num)
This method sets the section for a course. |
int |
sumOfSections()
Returns how many sections are available for this course. |
java.lang.String |
toString()
Returns the string representation of this course. |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
java.lang.String courseName
int id
int wtu
int scu
java.lang.String courseType
int maxEnrollment
int numOfSections
Course labPairing
Course.RequiredEquipment requiredEquipment
Constructor Detail |
---|
public Course(java.lang.String courseName, int id, int wtu, int scu, java.lang.String courseType, int maxEnrollment, int numOfSections, Course labPairing, Course.RequiredEquipment requiredEquipment)
courseName
- the name of this course.id
- the id of this course.wtu
- the work-time units of this course.scu
- the scu of this course.courseType
- the course type.maxEnrollment
- the maximum enrollment.numOfSections
- the numer of sections for this course.labPairing
- the lab pairing, if required.requiredEquipment
- the required equipment for htis course.public Course(java.lang.String courseName, int id, int wtu, int scu, java.lang.String courseType, int maxEnrollment, int numOfSections, Course labPairing, boolean smartroom, boolean overhead, boolean connectivity)
courseName
- the name of this course.id
- the id of this course.wtu
- the work-time units of this course.scu
- the scu of this course.courseType
- the course type.maxEnrollment
- the maximum enrollment.numOfSections
- the numer of sections for this course.labPairing
- the lab pairing, if required.smartroom
- whether this has a smart room.overhead
- whether this has an overhead.connectivity
- whether this need laptop connectivity.public Course(Course c)
c
- Course to copyMethod Detail |
---|
public boolean isLab()
public boolean hasLab()
public java.lang.String getCourseName()
public int getId()
public int getWTUs()
public int getSCUs()
public java.lang.String getCourseType()
public int getMaxEnrollment()
public int getNumberOfSections()
public Course getLabPairing()
public int getWTU()
public boolean isValidCourse(Course course)
public boolean isValidCourseDB()
public int sumOfSections()
public Course.RequiredEquipment getRequiredEquipment()
public java.lang.String toString()
toString
in class java.lang.Object
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public void setSection(int num)
num
- the section number.public int getSection()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |