private function _toHRef(\Gems_Menu_ParameterCollector $source, &$condition)
    {
        if ($this->get('allowed')) {
            $parameters = array();

            if ($condition = $this->_applyParameterSources($source, $parameters, ! $condition)) {

                if ($this->_hiddenOrgId) {
                    $url = new \Gems_Menu_HiddenOrganizationHrefAttribute($parameters);
                    $url->setHiddenOrgId($this->_hiddenOrgId);
                } else {
                    $url = new \MUtil_Html_HrefArrayAttribute($parameters);
                }
                $url->setRouteReset($this->get('reset_param', true));

                foreach (array('module', 'controller', 'action', 'route') as $name) {
                    if ($this->has($name)) {
                        $url->add($name, $this->get($name));
                        // \MUtil_Echo::r($name . '-' . $this->get($name));
                    // } else {
                        // \MUtil_Echo::r($name);
                    }
                }
                return $url;
            }
        }
    }
private function _toHRef(\Gems_Menu_ParameterCollector $source, &$condition)
    {
        if ($this->get('allowed')) {
            $parameters = array();

            if ($condition = $this->_applyParameterSources($source, $parameters, ! $condition)) {

                if ($this->_hiddenOrgId) {
                    $url = new \Gems_Menu_HiddenOrganizationHrefAttribute($parameters);
                    $url->setHiddenOrgId($this->_hiddenOrgId);
                } else {
                    $url = new \MUtil_Html_HrefArrayAttribute($parameters);
                }
                $url->setRouteReset($this->get('reset_param', true));

                foreach (array('module', 'controller', 'action', 'route') as $name) {
                    if ($this->has($name)) {
                        $url->add($name, $this->get($name));
                        // \MUtil_Echo::r($name . '-' . $this->get($name));
                    // } else {
                        // \MUtil_Echo::r($name);
                    }
                }
                return $url;
            }
        }
    }
private function _toHRef ( \ Gems_Menu_ParameterCollector $ source , & $ condition ) { if ( $ this -> get ( 'allowed' ) ) { $ parameters = array ( ) ; if ( $ condition = $ this -> _applyParameterSources ( $ source , $ parameters , ! $ condition ) ) { if ( $ this -> _hiddenOrgId ) { $ url = new \ Gems_Menu_HiddenOrganizationHrefAttribute ( $ parameters ) ; $ url -> setHiddenOrgId ( $ this -> _hiddenOrgId ) ; } else { $ url = new \ MUtil_Html_HrefArrayAttribute ( $ parameters ) ; } $ url -> setRouteReset ( $ this -> get ( 'reset_param' , true ) ) ; foreach ( array ( 'module' , 'controller' , 'action' , 'route' ) as $ name ) { if ( $ this -> has ( $ name ) ) { $ url -> add ( $ name , $ this -> get ( $ name ) ) ; // \MUtil_Echo::r($name . '-' . $this->get($name)); // } else { // \MUtil_Echo::r($name); } } return $ url ; } } }
Generate a hrf attribute using these sources

@param \Gems_Menu_ParameterCollector $source A parameter source collection
@param boolean $condition When true the system may create a Lazy condition for the url
@return \MUtil_Html_HrefArrayAttribute
Generate a hrf attribute using these sources