<?PHP


class Foo {
	/**
	* adadada
	* 
	*/
	public function __call($method, $args) {

		if (isset($this->$method) === true) {

			$func = $this->$method;
			return $func($args[0]);
		}
	}
	/**
	* adada
	*/
	*/
	function show(){

		$c = new foo2;
		$c->some();
		if($c->call){

			foreach($c->call as $v){

				$this->$v = $c->$v;
			}
		}
		print '<pre>';
		print_R ($this);
	}
}
/**
* adadada
*/
class foo2{

	var $call = array('go');

	/**
	* adada
	*/
	function some(){

		$this->go = function($args){

			print '<pre>';
			print_r ($args);
			return 'GO GO GO '.$s.' a '.$a;
		};
	}

	function jaja(){
	}
}

$foo = new Foo();
$foo->show();
echo $foo->go('jah');

?>