2012-07-09 17:10:44 +00:00
|
|
|
<?php
|
2012-08-20 13:52:35 +00:00
|
|
|
/*
|
|
|
|
* Callback container that handles doing the actual callback
|
|
|
|
*/
|
2012-07-09 17:10:44 +00:00
|
|
|
class Callback {
|
|
|
|
private $who;
|
|
|
|
private $func;
|
|
|
|
|
|
|
|
function Callback($who,$func) {
|
|
|
|
$this->who = $who;
|
|
|
|
$this->func = $func;
|
|
|
|
}
|
|
|
|
|
2012-08-20 13:52:35 +00:00
|
|
|
function call($what) { // now call it
|
2012-07-09 17:10:44 +00:00
|
|
|
eval(''.$this->func.'($what,$this->who,$this);');
|
|
|
|
}
|
|
|
|
}
|
|
|
|
?>
|