2010-09-18 11:11:44 -04:00
|
|
|
<?php
|
|
|
|
namespace Moserware\Skills\FactorGraphs;
|
|
|
|
|
|
|
|
class Message
|
|
|
|
{
|
2010-09-27 08:00:22 -04:00
|
|
|
private $_name;
|
2010-09-18 11:11:44 -04:00
|
|
|
private $_value;
|
|
|
|
|
2010-09-30 08:25:31 -04:00
|
|
|
public function __construct(&$value = null, $name = null)
|
2010-09-18 11:11:44 -04:00
|
|
|
{
|
2010-09-27 08:00:22 -04:00
|
|
|
$this->_name = $name;
|
2010-09-18 11:11:44 -04:00
|
|
|
$this->_value = $value;
|
|
|
|
}
|
|
|
|
|
2010-09-28 08:12:06 -04:00
|
|
|
public function& getValue()
|
2010-09-18 11:11:44 -04:00
|
|
|
{
|
2010-09-30 08:25:31 -04:00
|
|
|
$value = &$this->_value;
|
|
|
|
return $value;
|
2010-09-18 11:11:44 -04:00
|
|
|
}
|
|
|
|
|
2010-09-28 08:12:06 -04:00
|
|
|
public function setValue(&$value)
|
2010-10-03 19:21:55 -04:00
|
|
|
{
|
2010-09-28 08:12:06 -04:00
|
|
|
$this->_value = &$value;
|
|
|
|
}
|
|
|
|
|
2010-09-18 11:11:44 -04:00
|
|
|
public function __toString()
|
|
|
|
{
|
2010-09-27 08:00:22 -04:00
|
|
|
return $this->_name;
|
2010-09-18 11:11:44 -04:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
?>
|