Go to the documentation of this file.00001 <?php
00010 class response_proxy extends object {
00011
00017 protected $call = array();
00018
00024 private $response;
00025
00026 protected function afterInit() {
00027 $this->response = response::getInstance();
00028 }
00029
00030 public function getProxy() {
00031 return $this;
00032 }
00033
00039 public function hasCall() {
00040 return !empty($this->call);
00041 }
00042
00048 public function getCall() {
00049 return $this->call;
00050 }
00051
00055 public function initCall() {
00056 $this->call = array();
00057 }
00058
00064 public function doCalls(array $calls) {
00065 foreach($calls as $c) {
00066 call_user_func_array(array($this->response, $c[0]), $c[1]);
00067 }
00068 }
00069
00070 public function getAttr($name) {
00071 return $this->response->getAttr($name);
00072 }
00073
00074 public function setAttr($name, $value) {
00075 $this->call[] = array('setAttr', array($name, $value));
00076 $this->response->setAttr($name, $value);
00077 parent::setAttr($name, $value);
00078 }
00079
00087 public function __call($name, $prm) {
00088 if (substr($name, 0, 3) != 'get')
00089 $this->call[] = array($name, $prm);
00090 return call_user_func_array(array($this->response, $name), $prm);
00091 }
00092
00093 public function __toString() {
00094 return '';
00095 }
00096
00097 }