<?php
/*PLEASE DO NOT EDIT THIS CODE*/
/*This code was generated using the UMPLE 1.33.0.6934.a386b0a58 modeling language!*/
class Student
{
//------------------------
// MEMBER VARIABLES
//------------------------
//Student Attributes
private $number;
//Student Associations
private $mentor;
//Helper Variables
private $canSetMentor;
//------------------------
// CONSTRUCTOR
//------------------------
public function __construct($aNumber, $aMentor)
{
$this->number = $aNumber;
$this->canSetMentor = true;
$this->setMentor($aMentor);
}
//------------------------
// INTERFACE
//------------------------
public function getNumber()
{
return $this->number;
}
public function getMentor()
{
return $this->mentor;
}
public function hasMentor()
{
$has = $this->mentor != null;
return $has;
}
private function setMentor($aNewMentor)
{
$wasSet = false;
if (!$this->canSetMentor) { return false; }
$this->canSetMentor = false;
$this->mentor = $aNewMentor;
$wasSet = true;
return $wasSet;
}
public function equals($compareTo)
{
return $this == $compareTo;
}
public function delete()
{}
}
?>
<?php
/*PLEASE DO NOT EDIT THIS CODE*/
/*This code was generated using the UMPLE 1.33.0.6934.a386b0a58 modeling language!*/
class Mentor
{
//------------------------
// MEMBER VARIABLES
//------------------------
//Mentor Attributes
private $name;
//------------------------
// CONSTRUCTOR
//------------------------
public function __construct($aName)
{
$this->name = $aName;
}
//------------------------
// INTERFACE
//------------------------
public function getName()
{
return $this->name;
}
public function equals($compareTo)
{
return $this == $compareTo;
}
public function delete()
{}
}
?>