code/libraries/joomlatools/library/object/manager/manager.php
public function getObject($identifier, array $config = array())
    {
        $identifier = $this->getIdentifier($identifier);

        if (!$instance = $this->isRegistered($identifier))
        {
            //Instantiate the identifier
            $instance = $this->_instantiate($identifier, $config);

            //Mixins's are early mixed in KObject::_construct()
            //$instance = $this->_mixin($identifier, $instance);

            //Decorate the object
            $instance = $this->_decorate($identifier, $instance);

            //Auto register the object
            if($this->isMultiton($identifier)) {
                $this->setObject($identifier, $instance);
            }
        }

        return $instance;
    }
public function getObject($identifier, array $config = array())
    {
        $identifier = $this->getIdentifier($identifier);

        if (!$instance = $this->isRegistered($identifier))
        {
            //Instantiate the identifier
            $instance = $this->_instantiate($identifier, $config);

            //Mixins's are early mixed in KObject::_construct()
            //$instance = $this->_mixin($identifier, $instance);

            //Decorate the object
            $instance = $this->_decorate($identifier, $instance);

            //Auto register the object
            if($this->isMultiton($identifier)) {
                $this->setObject($identifier, $instance);
            }
        }

        return $instance;
    }
public function getObject ( $ identifier , array $ config = array ( ) ) { $ identifier = $ this -> getIdentifier ( $ identifier ) ; if ( ! $ instance = $ this -> isRegistered ( $ identifier ) ) { //Instantiate the identifier $ instance = $ this -> _instantiate ( $ identifier , $ config ) ; //Mixins's are early mixed in KObject::_construct() //$instance = $this->_mixin($identifier, $instance); //Decorate the object $ instance = $ this -> _decorate ( $ identifier , $ instance ) ; //Auto register the object if ( $ this -> isMultiton ( $ identifier ) ) { $ this -> setObject ( $ identifier , $ instance ) ; } } return $ instance ; }
Get an object instance based on an object identifier

If the object implements the ObjectInstantiable interface the manager will delegate object instantiation
to the object itself.

@param   mixed $identifier An KObjectIdentifier, identifier string or object implementing KObjectInterface
@param   array $config     An optional associative array of configuration settings
@return  KObjectInterface  Return object on success, throws exception on failure
@throws  KObjectExceptionInvalidIdentifier If the identifier is not valid
@throws  KObjectExceptionInvalidObject     If the object doesn't implement the KObjectInterface
@throws  KObjectExceptionNotFound          If object cannot be loaded
@throws  KObjectExceptionNotInstantiated   If object cannot be instantiated
Get an object instance based on an object identifier