function __construct() { C::__construct(); $this->p = 11; $this->q = 22; $this->r = 33; }
/** * 构造函数 * * @access public * @return void */ public function __construct() { parent::__construct(); $this->_attach_dir = config_item('site_attach_dir') . DIRECTORY_SEPARATOR; if (@is_dir($this->_attach_dir) === false) { create_dir($this->_attach_dir); } $watermark = $this->input->post('watermark', true); if ($watermark !== false) { $this->_watermark = false; } $temp = $this->input->post('temp', true); if ($temp !== false) { $this->_temp = true; } }
function test() { C::__construct(); $X = "C"; $m = "__construct"; C::$m(); $X::$m(); F::__construct(); I::__construct(); $X = "F"; $m = "__construct"; F::$m(); $X::$m(); $X = "I"; $m = "__construct"; I::$m(); $X::$m(); }
print "In J::J()\n"; } } class K extends H { function K() { print "In K::K()\n"; } function __construct() { print "In K::__construct()\n"; } } $c = new C(); $c->__construct(); $c->sMeth(); $c = new D(); $c->D(); $c = new E(); $c->E(); $c->__construct(); $c = new F(); $c->__construct(); $c = new G(); $c->D(); $c = new H(); $c->E(); $c->__construct(); $c = new I(); $c->__construct();
public function __construct() { parent::__construct(); }
{ print "In J::J()\n"; } } class K extends H { function K() { print "In K::K()\n"; } function __construct() { print "In K::__construct()\n"; } } C::__construct(); D::D(); E::E(); E::__construct(); F::__construct(); G::D(); H::E(); H::__construct(); I::__construct(); J::D(); J::J(); K::E(); K::K(); K::__construct(); $X = "C"; $m = "__construct";
public function __construct() { echo "In D::__construct\n"; C::__construct(); }
public function __construct() { parent::__construct(); var_dump(static::$cls); }
public function __construct() { parent::__construct(); unset($this->property9); }