Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- class myobjProxy {
- private $subjClass = 'myobj';
- public function __construct(\Auryn\Injector $inj){ $this->inj = $inj; }
- private createSubjectClass()
- {
- return $this->inj->make($this->subjClass);
- }
- public function __get($k){
- $r = $this->createSubjectClass();
- return $r->$k;
- }
- // same for all othe methods
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement