view/activities/json.php
public function getRenderer()
    {
        if (!$this->_renderer instanceof KTemplateHelperInterface)
        {
            // Make sure we have an identifier
            if(!($this->_renderer instanceof KObjectIdentifier)) {
                $this->setRenderer($this->_renderer);
            }

            $this->_renderer = $this->getObject($this->_renderer);

            if(!$this->_renderer instanceof ComActivitiesActivityRendererInterface)
            {
                throw new UnexpectedValueException(
                    'Renderer: '.get_class($this->_renderer).' does not implement ComActivitiesActivityRendererInterface'
                );
            }

            $this->_renderer->getTemplate()->registerFunction('url', array($this, 'getUrl'));
        }

        return $this->_renderer;
    }
public function getRenderer()
    {
        if (!$this->_renderer instanceof KTemplateHelperInterface)
        {
            // Make sure we have an identifier
            if(!($this->_renderer instanceof KObjectIdentifier)) {
                $this->setRenderer($this->_renderer);
            }

            $this->_renderer = $this->getObject($this->_renderer);

            if(!$this->_renderer instanceof ComActivitiesActivityRendererInterface)
            {
                throw new UnexpectedValueException(
                    'Renderer: '.get_class($this->_renderer).' does not implement ComActivitiesActivityRendererInterface'
                );
            }

            $this->_renderer->getTemplate()->registerFunction('url', array($this, 'getUrl'));
        }

        return $this->_renderer;
    }
public function getRenderer ( ) { if ( ! $ this -> _renderer instanceof KTemplateHelperInterface ) { // Make sure we have an identifier if ( ! ( $ this -> _renderer instanceof KObjectIdentifier ) ) { $ this -> setRenderer ( $ this -> _renderer ) ; } $ this -> _renderer = $ this -> getObject ( $ this -> _renderer ) ; if ( ! $ this -> _renderer instanceof ComActivitiesActivityRendererInterface ) { throw new UnexpectedValueException ( 'Renderer: ' . get_class ( $ this -> _renderer ) . ' does not implement ComActivitiesActivityRendererInterface' ) ; } $ this -> _renderer -> getTemplate ( ) -> registerFunction ( 'url' , array ( $ this , 'getUrl' ) ) ; } return $ this -> _renderer ; }
Get the activity renderer.

@throws UnexpectedValueException if renderer has the wrong type.
@return ComActivitiesActivityRendererInterface The activity renderer.
Get the activity renderer .