/** * Constructor * * @param object Group $group * @return void * @access public * @since 8/20/07 */ public function __construct(Group $group) { parent::__construct($group); $groups = $group->getGroups(false); while ($groups->hasNext()) { $this->sections[] = new SegueCourseSection($groups->next()); } $propType = new Type("segue", "edu.middlebury", "coursegroup"); $properties = $group->getPropertiesByType($propType); $idMgr = Services::getService("Id"); $this->id = $idMgr->getId($properties->getProperty("CourseGroupId")); }
/** * Answer the Id objects of the owners of this slot. * This method has been over-ridden to allow lazy loading of slot owners from * a course object rather than forcing that to be done at instance creation time. * * @return array * @access public * @since 7/30/07 */ public function getOwners() { if (!$this->mergedWithExternal) { $this->mergeWithExternal(); $this->mergedWithExternal = true; } // Lazily load the slot owners. if (!$this->ownersPopulated && isset($this->course)) { foreach ($this->course->getInstructors() as $instructor) { $this->populateOwnerId($instructor); } $this->ownersPopulated = true; } return parent::getOwners(); }