Example #1
0
 function instantiate(Context $context, $nesting, $graph = null)
 {
     if (!isset($this->instance)) {
         $this->instance = parent::instantiate($context, $nesting, $graph);
     }
     return $this->instance;
 }
Example #2
0
 public function instantiate(Context $context, $nesting, $graph = null)
 {
     $graph = $this->graph ?: ($graph ?: 'default');
     if (!isset($this->instance[$graph])) {
         $this->instance[$graph] = parent::instantiate($context->determineContext($this->class, $graph), $nesting, $graph);
     }
     return $this->instance[$graph];
 }
Example #3
0
 public function instantiate(Context $context, $nesting, $graph = null)
 {
     return parent::instantiate($context->determineContext($this->class, $this->graph), $nesting, $this->graph);
 }