public function getDependency(string $index)
    {
        if (! isset($this->container[$index])) {
            throw $this->unbound($index);
        }
        $dependency = $this->container[$index];

        return $dependency->inject($this);
    }
public function getDependency(string $index)
    {
        if (! isset($this->container[$index])) {
            throw $this->unbound($index);
        }
        $dependency = $this->container[$index];

        return $dependency->inject($this);
    }
public function getDependency ( string $ index ) { if ( ! isset ( $ this -> container [ $ index ] ) ) { throw $ this -> unbound ( $ index ) ; } $ dependency = $ this -> container [ $ index ] ; return $ dependency -> inject ( $ this ) ; }
Return dependency injected instance

@throws Unbound
Return dependency injected instance