protected function getObjectByClassname(/*# string */ $classname)
    {
        // mapping exists
        if (isset($this->mappings[$classname])) {
            $classname = $this->mappings[$classname];

            // is it a reference ? #changed
            if (false !== ($ref = $this->isReference($classname))) {
                $classname = $this->getReferenceValue($ref);

                // got a service object
                if (is_object($classname)) {
                    return $classname;
                }
            }
        }

        // try get service by $classname from container
        return $this->delegatedGet($classname);
    }
protected function getObjectByClassname(/*# string */ $classname)
    {
        // mapping exists
        if (isset($this->mappings[$classname])) {
            $classname = $this->mappings[$classname];

            // is it a reference ? #changed
            if (false !== ($ref = $this->isReference($classname))) {
                $classname = $this->getReferenceValue($ref);

                // got a service object
                if (is_object($classname)) {
                    return $classname;
                }
            }
        }

        // try get service by $classname from container
        return $this->delegatedGet($classname);
    }
protected function getObjectByClassname ( /*# string */ $ classname ) { // mapping exists if ( isset ( $ this -> mappings [ $ classname ] ) ) { $ classname = $ this -> mappings [ $ classname ] ; // is it a reference ? #changed if ( false !== ( $ ref = $ this -> isReference ( $ classname ) ) ) { $ classname = $ this -> getReferenceValue ( $ ref ) ; // got a service object if ( is_object ( $ classname ) ) { return $ classname ; } } } // try get service by $classname from container return $ this -> delegatedGet ( $ classname ) ; }
Get an object base on provided classname

@param  string $classname class name
@return object
@throws LogicException
@access protected
@api
Get an object base on provided classname