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