org.cpsolver.coursett.model

## Class Lecture

- java.lang.Object
- - org.cpsolver.ifs.model.Variable<V,T>
  - - org.cpsolver.ifs.assignment.context.VariableWithContext<Lecture,Placement,Lecture.LectureContext>
    - - org.cpsolver.coursett.model.Lecture

- All Implemented Interfaces:
    Comparable<Lecture>, CanHoldContext, HasAssignmentContext<Lecture,Placement,Lecture.LectureContext>, ConstantVariable<Placement>

      public class Lecture
      extends VariableWithContext<Lecture,Placement,Lecture.LectureContext>
      implements ConstantVariable<Placement>

  Lecture (variable).
  Version:
    CourseTT 1.3 (University Course Timetabling)
    Copyright (C) 2006 - 2014 Tomáš Müller
    muller@unitime.org
    http://muller.unitime.org
    This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.
    This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
    You should have received a copy of the GNU Lesser General Public License along with this library; if not see http://www.gnu.org/licenses/.
  Author:
    Tomáš Müller

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `class` | `Lecture.LectureContext`

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `boolean` | `iCommitted`
    `static boolean` | `sSaveMemory`

    - ### Fields inherited from class org.cpsolver.ifs.model.Variable

      `iId, iIndex, iValue`

    - ### Fields inherited from interface org.cpsolver.ifs.assignment.context.CanHoldContext

      `sMaxSize`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `Lecture(Long id, Long solverGroupId, Long schedulingSubpartId, String name, Collection<TimeLocation> timeLocations, Collection<RoomLocation> roomLocations, int nrRooms, Placement initialPlacement, int minClassLimit, int maxClassLimit, double room2limitRatio)` Constructor
    `Lecture(Long id, Long solverGroupId, String name)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods Deprecated Methods
    Modifier and Type | Method and Description
    --- | ---
    `Set<JenrlConstraint>` | `activeJenrls(Assignment<Lecture,Placement> assignment)` Active jenrl constraints (active mean that there is at least one student between its classes)
    `void` | `addActiveJenrl(Assignment<Lecture,Placement> assignment, JenrlConstraint constr)` Add active jenrl constraint (active mean that there is at least one student between its classes)
    `void` | `addContstraint(Constraint<Lecture,Placement> constraint)` Adds a constraint.
    `void` | `addStudent(Assignment<Lecture,Placement> assignment, Student student)` Add an enrolled student
    `boolean` | `allowBreakHard()`
    `boolean` | `areStudentConflictsHard(Lecture other)`
    `boolean` | `canShareRoom()`
    `boolean` | `canShareRoom(Lecture other)`
    `Set<GroupConstraint>` | `canShareRoomConstraints()`
    `int` | `classLimit(Assignment<Lecture,Placement> assignment)`
    `int` | `classLimit(Assignment<Lecture,Placement> assignment, Placement value, Set<Placement> conflicts)`
    `void` | `clearIgnoreStudentConflictsWithCache()`
    `void` | `clearValueCache()`
    `int` | `compareTo(Lecture o)`
    `List<Placement>` | `computeValues(Assignment<Lecture,Placement> assignment, boolean allowBreakHard)` Domain -- all combinations of room and time locations
    `List<Lecture>` | `conflictLectures(Assignment<Lecture,Placement> assignment, Student student)` Lectures different from this one, where it is student conflict of the given student between this and the lecture
    `Set<Student>` | `conflictStudents(Assignment<Lecture,Placement> assignment)` List of students of this class which are in conflict with any other assignment
    `Set<Student>` | `conflictStudents(Assignment<Lecture,Placement> assignment, Placement value)` List of students of this class in conflict with the given assignment
    `int` | `countCommittedStudentConflicts(Assignment<Lecture,Placement> assignment, Placement value)`
    `int` | `countCommittedStudentConflictsOfTheSameProblem(Assignment<Lecture,Placement> assignment, Placement value)`
    `int` | `countDistanceStudentConflicts(Assignment<Lecture,Placement> assignment, Placement value)`
    `int` | `countDistanceStudentConflictsOfTheSameProblem(Assignment<Lecture,Placement> assignment, Placement value)`
    `int` | `countHardStudentConflicts(Assignment<Lecture,Placement> assignment, Placement value)`
    `int` | `countHardStudentConflictsOfTheSameProblem(Assignment<Lecture,Placement> assignment, Placement value)`
    `int` | `countInitialStudentConflicts()` Number of student conflicts caused by the initial assignment of this lecture
    `int` | `countStudentConflicts(Assignment<Lecture,Placement> assignment, Placement value)` Number of student conflicts caused by the given assignment of this lecture
    `int` | `countStudentConflictsOfTheSameProblem(Assignment<Lecture,Placement> assignment, Placement value)`
    `Lecture.LectureContext` | `createAssignmentContext(Assignment<Lecture,Placement> assignment)` Create a new assignment context for the given assignment.
    `boolean` | `equals(Object o)`
    `int` | `getBestRoomPreference()` Best room preference of this lecture
    `double` | `getBestTimePreference()`
    `Lecture` | `getChild(Student student, Long subpartId)`
    `Map<Long,List<Lecture>>` | `getChildren()`
    `List<Lecture>` | `getChildren(Long subpartId)`
    `Set<Long>` | `getChildrenSubpartIds()`
    `Long` | `getClassId()` Class id
    `ClassLimitConstraint` | `getClassLimitConstraint()`
    `int` | `getCommitedConflicts(Placement placement)`
    `Configuration` | `getConfiguration()`
    `Placement` | `getConstantValue()` Return assignment if constant
    `Long` | `getDepartment()` Controlling Course Offering Department
    `DepartmentSpreadConstraint` | `getDeptSpreadConstraint()` Departmental spreading constraint
    `Set<FlexibleConstraint>` | `getFlexibleGroupConstraints()`
    `long` | `getId()` Class id
    `Map<Lecture,Long>` | `getInitialStudentConflicts()` Table of student conflicts caused by the initial assignment of this lecture in format (another lecture, number)
    `List<InstructorConstraint>` | `getInstructorConstraints()` Instructor constraint
    `String` | `getInstructorName()`
    `List<String>` | `getInstructorNames()` Instructor name
    `int` | `getMaxRoomCombinations()`
    `int[]` | `getMinMaxRoomPreference()`
    `double[]` | `getMinMaxTimePreference()`
    `int` | `getMinWeeks()`
    `String` | `getName()` Class name
    `String` | `getNote()`
    `String` | `getNotValidReason(Assignment<Lecture,Placement> assignment, Placement placement)` Deprecated.
    `String` | `getNotValidReason(Assignment<Lecture,Placement> assignment, Placement placement, boolean useAmPm)`
    `int` | `getNrRooms()`
    `int` | `getOrd()`
    `Lecture` | `getParent()`
    `Long` | `getScheduler()` Scheduler (Managing Department)
    `Long` | `getSchedulingSubpartId()` Scheduling subpart id
    `Long` | `getSolverGroupId()`
    `Set<SpreadConstraint>` | `getSpreadConstraints()`
    `int` | `getSpreadPenalty(Assignment<Lecture,Placement> assignment)`
    `Set<Constraint<Lecture,Placement>>` | `getWeakeningConstraints()`
    `double` | `getWeight()` Get class weight.
    `Set<GroupConstraint>` | `groupConstraints()`
    `Set<GroupConstraint>` | `hardGroupSoftConstraints()`
    `boolean` | `hasAnyChildren()`
    `boolean` | `hasChildren(Long subpartId)`
    `int` | `hashCode()`
    `boolean` | `hasParent()`
    `boolean` | `hasStudent(Student student)` Returns true if the given student is enrolled
    `Set<Student>` | `initialStudentConflicts()` List of student conflicts caused by the initial assignment of this lecture
    `boolean` | `isCommitted()`
    `boolean` | `isConstant()` True, if the variable is constant.
    `int` | `isInConflict(Assignment<Lecture,Placement> assignment, Student student)` True if this lecture is in a student conflict with the given student
    `boolean` | `isSingleSection()`
    `boolean` | `isSingleton()`
    `boolean` | `isSplitAttendance()` When using multiple rooms, split attendance means that the class is split among the given rooms.
    `boolean` | `isToIgnoreStudentConflictsWith(Lecture other)` Returns true if there is `IgnoreStudentConflictsConstraint` between the two lectures.
    `boolean` | `isValid(Placement placement)`
    `JenrlConstraint` | `jenrlConstraint(Lecture another)` All JENRL constraints of this lecture
    `List<JenrlConstraint>` | `jenrlConstraints()` All JENRL constraints of this lecture
    `int` | `maxAchievableClassLimit()`
    `int` | `maxClassLimit()`
    `int` | `maxRoomSize()`
    `int` | `maxRoomUse()`
    `int` | `minClassLimit()`
    `int` | `minRoomSize()`
    `int` | `minRoomUse()`
    `int` | `nrRoomLocations()`
    `int` | `nrTimeLocations()`
    `long` | `nrValues()`
    `int` | `nrValues(List<RoomLocation> rooms)`
    `int` | `nrValues(RoomLocation room)`
    `int` | `nrValues(TimeLocation time)`
    `double` | `nrWeightedStudents()` Total weight of all enrolled students
    `void` | `purgeInvalidValues(boolean interactiveMode)`
    `void` | `removeActiveJenrl(Assignment<Lecture,Placement> assignment, JenrlConstraint constr)` Remove active jenrl constraint (active mean that there is at least one student between its classes)
    `void` | `removeContstraint(Constraint<Lecture,Placement> constraint)` Removes a constraint.
    `void` | `removeStudent(Assignment<Lecture,Placement> assignment, Student student)` Remove an enrolled student
    `List<RoomLocation>` | `roomLocations()` All room locations
    `double` | `roomToLimitRatio()`
    `Set<Student>` | `sameStudents(Lecture lecture)` List of students enrolled in this class as well as in the given class
    `List<Lecture>` | `sameStudentsLectures()`
    `List<Lecture>` | `sameSubpartLectures()` Set of lectures of the same class (only section is different)
    `void` | `setCommitted(boolean committed)`
    `void` | `setConfiguration(Configuration configuration)`
    `void` | `setConstantValue(Placement value)`
    `void` | `setDepartment(Long dept)` Controlling Course Offering Department
    `void` | `setMaxRoomCombinations(int maxRoomCombinations)`
    `void` | `setNote(String note)`
    `void` | `setOrd(int ord)`
    `void` | `setParent(Lecture parent)`
    `void` | `setSameSubpartLectures(List<Lecture> sameSubpartLectures)` Set of lectures of the same class (only section is different)
    `void` | `setScheduler(Long scheduler)` Scheduler (Managing Department)
    `void` | `setSplitAttendance(boolean splitAttendance)` When using multiple rooms, split attendance means that the class is split among the given rooms.
    `void` | `setWeight(double weight)` Set class weight.
    `Set<Student>` | `students()` List of enrolled students
    `List<TimeLocation>` | `timeLocations()` All time locations
    `String` | `toString()`
    `List<Placement>` | `values(Assignment<Lecture,Placement> assignment)` All values

    - ### Methods inherited from class org.cpsolver.ifs.assignment.context.VariableWithContext

      `getAssignmentContextReference, getContext, getContext, setAssignmentContextReference, setModel`

    - ### Methods inherited from class org.cpsolver.ifs.model.Variable

      `addVariableListener, assign, constraints, constraintVariables, getAssignment, getAssignment, getAssignments, getBestAssignment, getBestAssignmentIteration, getDescription, getExtra, getIndex, getInitialAssignment, getLastIteration, getModel, getVariableListeners, hardConstraints, hasAssignment, hasAssignment, hasInitialAssignment, hasValues, removeInitialValue, removeValue, removeVariableListener, setAssignment, setBestAssignment, setExtra, setIndex, setInitialAssignment, setLastIteration, setValues, softConstraints, unassign, values, variableAssigned, variableUnassigned`

    - ### Methods inherited from class java.lang.Object

      `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

- - ### Field Detail

    - #### iCommitted

          public boolean iCommitted

    - #### sSaveMemory

          public static boolean sSaveMemory

  - ### Constructor Detail

    - #### Lecture

          public Lecture(Long id,
                         Long solverGroupId,
                         Long schedulingSubpartId,
                         String name,
                         Collection<TimeLocation> timeLocations,
                         Collection<RoomLocation> roomLocations,
                         int nrRooms,
                         Placement initialPlacement,
                         int minClassLimit,
                         int maxClassLimit,
                         double room2limitRatio)

      Constructor
      Parameters:
        `id` - class unique id
        `solverGroupId` - solver group unique id
        `schedulingSubpartId` - scheduling subpart unique id
        `name` - class name
        `timeLocations` - set of time locations
        `roomLocations` - set of room location
        `nrRooms` - number of rooms into which the class is to be assigned
        `initialPlacement` - initial placement
        `minClassLimit` - minimum class limit
        `maxClassLimit` - maximum class limit
        `room2limitRatio` - room ratio

    - #### Lecture

          public Lecture(Long id,
                         Long solverGroupId,
                         String name)

  - ### Method Detail

    - #### getSolverGroupId

          public Long getSolverGroupId()

    - #### addActiveJenrl

          public void addActiveJenrl(Assignment<Lecture,Placement> assignment,
                                     JenrlConstraint constr)

      Add active jenrl constraint (active mean that there is at least one student between its classes)
      Parameters:
        `assignment` - current assignment
        `constr` - an active jenrl constraint

    - #### activeJenrls

          public Set<JenrlConstraint> activeJenrls(Assignment<Lecture,Placement> assignment)

      Active jenrl constraints (active mean that there is at least one student between its classes)
      Parameters:
        `assignment` - current assignment
      Returns:
        set of active jenrl constraints

    - #### removeActiveJenrl

          public void removeActiveJenrl(Assignment<Lecture,Placement> assignment,
                                        JenrlConstraint constr)

      Remove active jenrl constraint (active mean that there is at least one student between its classes)
      Parameters:
        `assignment` - current assignment
        `constr` - an active jenrl constraint

    - #### getClassId

          public Long getClassId()

      Class id
      Returns:
        class unique id

    - #### getSchedulingSubpartId

          public Long getSchedulingSubpartId()

      Scheduling subpart id
      Returns:
        scheduling subpart unique id

    - #### getName

          public String getName()

      Class name
      Overrides:
        `getName` in class `Variable<Lecture,Placement>`
      Returns:
        variable name

    - #### getId

          public long getId()

      Class id
      Overrides:
        `getId` in class `Variable<Lecture,Placement>`
      Returns:
        variable id

    - #### getInstructorNames

          public List<String> getInstructorNames()

      Instructor name
      Returns:
        list of instructor names

    - #### getInstructorName

          public String getInstructorName()

    - #### students

          public Set<Student> students()

      List of enrolled students
      Returns:
        list of enrolled students

    - #### nrWeightedStudents

          public double nrWeightedStudents()

      Total weight of all enrolled students
      Returns:
        sum of `Student.getOfferingWeight(Configuration)` of each enrolled student

    - #### addStudent

          public void addStudent(Assignment<Lecture,Placement> assignment,
                                 Student student)

      Add an enrolled student
      Parameters:
        `assignment` - current assignment
        `student` - a student to add

    - #### removeStudent

          public void removeStudent(Assignment<Lecture,Placement> assignment,
                                    Student student)

      Remove an enrolled student
      Parameters:
        `assignment` - current assignment
        `student` - a student to remove

    - #### hasStudent

          public boolean hasStudent(Student student)

      Returns true if the given student is enrolled
      Parameters:
        `student` - a student
      Returns:
        true if the given student is enrolled in this class

    - #### setSameSubpartLectures

          public void setSameSubpartLectures(List<Lecture> sameSubpartLectures)

      Set of lectures of the same class (only section is different)
      Parameters:
        `sameSubpartLectures` - list of lectures of the same scheduling subpart

    - #### sameSubpartLectures

          public List<Lecture> sameSubpartLectures()

      Set of lectures of the same class (only section is different)
      Returns:
        list of lectures of the same scheduling subpart

    - #### sameStudents

          public Set<Student> sameStudents(Lecture lecture)

      List of students enrolled in this class as well as in the given class
      Parameters:
        `lecture` - a lecture
      Returns:
        a set of students that are enrolled in both lectures

    - #### conflictStudents

          public Set<Student> conflictStudents(Assignment<Lecture,Placement> assignment,
                                               Placement value)

      List of students of this class in conflict with the given assignment
      Parameters:
        `assignment` - current assignment
        `value` - given placement
      Returns:
        list of student conflicts

    - #### conflictStudents

          public Set<Student> conflictStudents(Assignment<Lecture,Placement> assignment)

      List of students of this class which are in conflict with any other assignment
      Parameters:
        `assignment` - current assignment
      Returns:
        list of student conflicts

    - #### conflictLectures

          public List<Lecture> conflictLectures(Assignment<Lecture,Placement> assignment,
                                                Student student)

      Lectures different from this one, where it is student conflict of the given student between this and the lecture
      Parameters:
        `assignment` - current assignment
        `student` - a student
      Returns:
        list of lectures with a student conflict

    - #### isInConflict

          public int isInConflict(Assignment<Lecture,Placement> assignment,
                                  Student student)

      True if this lecture is in a student conflict with the given student
      Parameters:
        `assignment` - current assignment
        `student` - a student
      Returns:
        number of other lectures with a student conflict

    - #### computeValues

          public List<Placement> computeValues(Assignment<Lecture,Placement> assignment,
                                               boolean allowBreakHard)

      Domain -- all combinations of room and time locations
      Parameters:
        `assignment` - current assignment
        `allowBreakHard` - breaking of hard constraints is allowed
      Returns:
        list of possible placements

    - #### clearValueCache

          public void clearValueCache()

    - #### values

          public List<Placement> values(Assignment<Lecture,Placement> assignment)

      All values
      Overrides:
        `values` in class `Variable<Lecture,Placement>`
      Parameters:
        `assignment` - current assignment (if the domain is dependent on the current assignment)
      Returns:
        all possible values of this variable

    - #### equals

          public boolean equals(Object o)

      Overrides:
        `equals` in class `Variable<Lecture,Placement>`

    - #### getBestTimePreference

          public double getBestTimePreference()

    - #### getBestRoomPreference

          public int getBestRoomPreference()

      Best room preference of this lecture
      Returns:
        best room preference

    - #### countStudentConflicts

          public int countStudentConflicts(Assignment<Lecture,Placement> assignment,
                                           Placement value)

      Number of student conflicts caused by the given assignment of this lecture
      Parameters:
        `assignment` - current assignment
        `value` - a placement
      Returns:
        number of student conflicts if assigned

    - #### countStudentConflictsOfTheSameProblem

          public int countStudentConflictsOfTheSameProblem(Assignment<Lecture,Placement> assignment,
                                                           Placement value)

    - #### countHardStudentConflicts

          public int countHardStudentConflicts(Assignment<Lecture,Placement> assignment,
                                               Placement value)

    - #### countCommittedStudentConflictsOfTheSameProblem

          public int countCommittedStudentConflictsOfTheSameProblem(Assignment<Lecture,Placement> assignment,
                                                                    Placement value)

    - #### countCommittedStudentConflicts

          public int countCommittedStudentConflicts(Assignment<Lecture,Placement> assignment,
                                                    Placement value)

    - #### countHardStudentConflictsOfTheSameProblem

          public int countHardStudentConflictsOfTheSameProblem(Assignment<Lecture,Placement> assignment,
                                                               Placement value)

    - #### countDistanceStudentConflicts

          public int countDistanceStudentConflicts(Assignment<Lecture,Placement> assignment,
                                                   Placement value)

    - #### countDistanceStudentConflictsOfTheSameProblem

          public int countDistanceStudentConflictsOfTheSameProblem(Assignment<Lecture,Placement> assignment,
                                                                   Placement value)

    - #### countInitialStudentConflicts

          public int countInitialStudentConflicts()

      Number of student conflicts caused by the initial assignment of this lecture
      Returns:
        number of student conflicts with the initial assignment of this class

    - #### getInitialStudentConflicts

          public Map<Lecture,Long> getInitialStudentConflicts()

      Table of student conflicts caused by the initial assignment of this lecture in format (another lecture, number)
      Returns:
        table of student conflicts with the initial assignment of this class

    - #### initialStudentConflicts

          public Set<Student> initialStudentConflicts()

      List of student conflicts caused by the initial assignment of this lecture
      Returns:
        a set of students in a conflict with the initial assignment of this class

    - #### addContstraint

          public void addContstraint(Constraint<Lecture,Placement> constraint)

      Description copied from class: `Variable`
      Adds a constraint. Called automatically when the constraint is added to the model, i.e., `Model.addConstraint(Constraint)` is called.
      Overrides:
        `addContstraint` in class `Variable<Lecture,Placement>`
      Parameters:
        `constraint` - added constraint

    - #### removeContstraint

          public void removeContstraint(Constraint<Lecture,Placement> constraint)

      Description copied from class: `Variable`
      Removes a constraint. Called automatically when the constraint is removed from the model, i.e., `Model.removeConstraint(Constraint)` is called.
      Overrides:
        `removeContstraint` in class `Variable<Lecture,Placement>`
      Parameters:
        `constraint` - added constraint

    - #### jenrlConstraint

          public JenrlConstraint jenrlConstraint(Lecture another)

      All JENRL constraints of this lecture
      Parameters:
        `another` - another class
      Returns:
        a join enrollment constraint between this and the given class, if there is one

    - #### jenrlConstraints

          public List<JenrlConstraint> jenrlConstraints()

      All JENRL constraints of this lecture
      Returns:
        list of all join enrollment constraints in which this lecture is involved

    - #### minClassLimit

          public int minClassLimit()

    - #### maxClassLimit

          public int maxClassLimit()

    - #### maxAchievableClassLimit

          public int maxAchievableClassLimit()

    - #### classLimit

          public int classLimit(Assignment<Lecture,Placement> assignment)

    - #### classLimit

          public int classLimit(Assignment<Lecture,Placement> assignment,
                                Placement value,
                                Set<Placement> conflicts)

    - #### roomToLimitRatio

          public double roomToLimitRatio()

    - #### minRoomUse

          public int minRoomUse()

    - #### maxRoomUse

          public int maxRoomUse()

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Variable<Lecture,Placement>`

    - #### getDepartment

          public Long getDepartment()

      Controlling Course Offering Department
      Returns:
        department unique id

    - #### setDepartment

          public void setDepartment(Long dept)

      Controlling Course Offering Department
      Parameters:
        `dept` - department unique id

    - #### getScheduler

          public Long getScheduler()

      Scheduler (Managing Department)
      Returns:
        solver group unique id

    - #### setScheduler

          public void setScheduler(Long scheduler)

      Scheduler (Managing Department)
      Parameters:
        `scheduler` - solver group unique id

    - #### getDeptSpreadConstraint

          public DepartmentSpreadConstraint getDeptSpreadConstraint()

      Departmental spreading constraint
      Returns:
        department spread constraint of this class, if any

    - #### getInstructorConstraints

          public List<InstructorConstraint> getInstructorConstraints()

      Instructor constraint
      Returns:
        instructors of this class

    - #### getClassLimitConstraint

          public ClassLimitConstraint getClassLimitConstraint()

    - #### getSpreadConstraints

          public Set<SpreadConstraint> getSpreadConstraints()

    - #### getFlexibleGroupConstraints

          public Set<FlexibleConstraint> getFlexibleGroupConstraints()

    - #### getWeakeningConstraints

          public Set<Constraint<Lecture,Placement>> getWeakeningConstraints()

    - #### roomLocations

          public List<RoomLocation> roomLocations()

      All room locations
      Returns:
        possible rooms of this class

    - #### timeLocations

          public List<TimeLocation> timeLocations()

      All time locations
      Returns:
        possible times of this class

    - #### nrTimeLocations

          public int nrTimeLocations()

    - #### nrRoomLocations

          public int nrRoomLocations()

    - #### nrValues

          public long nrValues()

    - #### nrValues

          public int nrValues(TimeLocation time)

    - #### nrValues

          public int nrValues(RoomLocation room)

    - #### nrValues

          public int nrValues(List<RoomLocation> rooms)

    - #### allowBreakHard

          public boolean allowBreakHard()

    - #### getNrRooms

          public int getNrRooms()

    - #### getParent

          public Lecture getParent()

    - #### setParent

          public void setParent(Lecture parent)

    - #### hasParent

          public boolean hasParent()

    - #### hasChildren

          public boolean hasChildren(Long subpartId)

    - #### hasAnyChildren

          public boolean hasAnyChildren()

    - #### getChildren

          public List<Lecture> getChildren(Long subpartId)

    - #### getChildrenSubpartIds

          public Set<Long> getChildrenSubpartIds()

    - #### getChildren

          public Map<Long,List<Lecture>> getChildren()

    - #### isSingleSection

          public boolean isSingleSection()

    - #### sameStudentsLectures

          public List<Lecture> sameStudentsLectures()

    - #### getChild

          public Lecture getChild(Student student,
                                  Long subpartId)

    - #### getCommitedConflicts

          public int getCommitedConflicts(Placement placement)

    - #### hardGroupSoftConstraints

          public Set<GroupConstraint> hardGroupSoftConstraints()

    - #### groupConstraints

          public Set<GroupConstraint> groupConstraints()

    - #### minRoomSize

          public int minRoomSize()

    - #### maxRoomSize

          public int maxRoomSize()

    - #### canShareRoom

          public boolean canShareRoom()

    - #### canShareRoom

          public boolean canShareRoom(Lecture other)

    - #### canShareRoomConstraints

          public Set<GroupConstraint> canShareRoomConstraints()

    - #### isSingleton

          public boolean isSingleton()

    - #### isValid

          public boolean isValid(Placement placement)

    - #### getNotValidReason

          public String getNotValidReason(Assignment<Lecture,Placement> assignment,
                                          Placement placement,
                                          boolean useAmPm)

    - #### getNotValidReason

          @Deprecated
          public String getNotValidReason(Assignment<Lecture,Placement> assignment,
                                                      Placement placement)

      Deprecated.

    - #### purgeInvalidValues

          public void purgeInvalidValues(boolean interactiveMode)

    - #### setCommitted

          public void setCommitted(boolean committed)

    - #### isCommitted

          public boolean isCommitted()

    - #### isConstant

          public boolean isConstant()

      Description copied from interface: `ConstantVariable`
      True, if the variable is constant.
      Specified by:
        `isConstant` in interface `ConstantVariable<Placement>`
      Returns:
        true if constant

    - #### getConstantValue

          public Placement getConstantValue()

      Description copied from interface: `ConstantVariable`
      Return assignment if constant
      Specified by:
        `getConstantValue` in interface `ConstantVariable<Placement>`
      Returns:
        constant value (if `ConstantVariable.isConstant()` is true)

    - #### setConstantValue

          public void setConstantValue(Placement value)

    - #### getSpreadPenalty

          public int getSpreadPenalty(Assignment<Lecture,Placement> assignment)

    - #### hashCode

          public int hashCode()

      Overrides:
        `hashCode` in class `Variable<Lecture,Placement>`

    - #### getConfiguration

          public Configuration getConfiguration()

    - #### setConfiguration

          public void setConfiguration(Configuration configuration)

    - #### getMinMaxRoomPreference

          public int[] getMinMaxRoomPreference()

    - #### getMinMaxTimePreference

          public double[] getMinMaxTimePreference()

    - #### setOrd

          public void setOrd(int ord)

    - #### getOrd

          public int getOrd()

    - #### compareTo

          public int compareTo(Lecture o)

      Specified by:
        `compareTo` in interface `Comparable<Lecture>`
      Overrides:
        `compareTo` in class `Variable<Lecture,Placement>`

    - #### getNote

          public String getNote()

    - #### setNote

          public void setNote(String note)

    - #### areStudentConflictsHard

          public boolean areStudentConflictsHard(Lecture other)

    - #### clearIgnoreStudentConflictsWithCache

          public void clearIgnoreStudentConflictsWithCache()

    - #### isToIgnoreStudentConflictsWith

          public boolean isToIgnoreStudentConflictsWith(Lecture other)

      Returns true if there is `IgnoreStudentConflictsConstraint` between the two lectures.
      Parameters:
        `other` - another class
      Returns:
        true if student conflicts between this and the given calls are to be ignored

    - #### getWeight

          public double getWeight()

      Get class weight. This weight is used with the criteria. E.g., class that is not meeting all the semester can have a lower weight. Defaults to 1.0
      Returns:
        class weight

    - #### setWeight

          public void setWeight(double weight)

      Set class weight. This weight is used with the criteria. E.g., class that is not meeting all the semester can have a lower weight.
      Parameters:
        `weight` - class weight

    - #### createAssignmentContext

          public Lecture.LectureContext createAssignmentContext(Assignment<Lecture,Placement> assignment)

      Description copied from interface: `HasAssignmentContext`
      Create a new assignment context for the given assignment. If there are already some variables assigned in the value, the method should make sure that the context is appropriately initialized.
      Specified by:
        `createAssignmentContext` in interface `HasAssignmentContext<Lecture,Placement,Lecture.LectureContext>`
      Parameters:
        `assignment` - an assignment for which there needs to be an assignment context
      Returns:
        a new instance of the assignment context, filled according to the given assignment

    - #### getMaxRoomCombinations

          public int getMaxRoomCombinations()

    - #### setMaxRoomCombinations

          public void setMaxRoomCombinations(int maxRoomCombinations)

    - #### getMinWeeks

          public int getMinWeeks()

    - #### isSplitAttendance

          public boolean isSplitAttendance()

      When using multiple rooms, split attendance means that the class is split among the given rooms.
      Returns:
        true means class is split among rooms, false means each room must be big enough for the class

    - #### setSplitAttendance

          public void setSplitAttendance(boolean splitAttendance)

      When using multiple rooms, split attendance means that the class is split among the given rooms.
      Parameters:
        `splitAttendance` - true means class is split among rooms, false means each room must be big enough for the class