|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.sf.cpsolver.studentsct.model.Course
public class Course
Representation of a course offering. A course offering contains id, subject
area, course number and an instructional offering.
Each instructional offering (see Offering) is offered under one or
more course offerings.
| Constructor Summary | |
|---|---|
Course(long id,
String subjectArea,
String courseNumber,
Offering offering)
Constructor |
|
Course(long id,
String subjectArea,
String courseNumber,
Offering offering,
int limit,
int projected)
Constructor |
|
| Method Summary | |
|---|---|
void |
assigned(Enrollment enrollment)
Called when an enrollment with this course is assigned to a request |
boolean |
equals(Object o)
|
String |
getCourseNumber()
Course number |
Set<Enrollment> |
getEnrollments()
Set of assigned enrollments |
double |
getEnrollmentWeight(Request excludeRequest)
Enrollment weight -- weight of all requests that are enrolled into this course, excluding the given one. |
long |
getId()
Course offering unique id |
int |
getLimit()
Course offering limit |
String |
getName()
Course offering name: subject area + course number |
String |
getNote()
Course note |
Offering |
getOffering()
Instructional offering which is offered under this course offering. |
int |
getProjected()
Course offering projected number of students |
Set<CourseRequest> |
getRequests()
Set of course requests requesting this course |
String |
getSubjectArea()
Subject area |
int |
hashCode()
|
void |
setLimit(int limit)
Set course offering limit |
void |
setNote(String note)
Course note |
String |
toString()
|
void |
unassigned(Enrollment enrollment)
Called when an enrollment with this course is unassigned from a request |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public Course(long id,
String subjectArea,
String courseNumber,
Offering offering)
id - course offering unique idsubjectArea - subject area (e.g., MA, CS, ENGL)courseNumber - course number under the given subject areaoffering - instructional offering which is offered under this course
offering
public Course(long id,
String subjectArea,
String courseNumber,
Offering offering,
int limit,
int projected)
id - course offering unique idsubjectArea - subject area (e.g., MA, CS, ENGL)courseNumber - course number under the given subject areaoffering - instructional offering which is offered under this course
offeringlimit - course offering limit (-1 for unlimited)projected - projected demand| Method Detail |
|---|
public long getId()
public String getSubjectArea()
public String getCourseNumber()
public String getName()
public String toString()
toString in class Objectpublic Offering getOffering()
public int getLimit()
public void setLimit(int limit)
public int getProjected()
public void assigned(Enrollment enrollment)
public void unassigned(Enrollment enrollment)
public double getEnrollmentWeight(Request excludeRequest)
Request.getWeight().
public Set<Enrollment> getEnrollments()
public Set<CourseRequest> getRequests()
public String getNote()
public void setNote(String note)
public boolean equals(Object o)
equals in class Objectpublic int hashCode()
hashCode in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||