Back to Router class

Method processBuildRules

protected void
processBuildRules
(mixed &$uri, mixed $stage = self::PROCESS_DURING)
Process the build uri query data based on custom defined rules
Parameters
  • \Joomla\CMS\Uri\Uri & $uri The URI
  • string $stage The stage that should be processed. Possible values: 'preprocess', 'postprocess' and '' for the main build stage
Returns
  • void
Since
  • 3.2
Class: Router
Project: Joomla

Method processBuildRules - Source code

/**
 * Process the build uri query data based on custom defined rules
 *
 * @param   \Joomla\CMS\Uri\Uri  &$uri   The URI
 * @param   string               $stage  The stage that should be processed.
 *                                       Possible values: 'preprocess', 'postprocess'
 *                                       and '' for the main build stage
 *
 * @return  void
 *
 * @since   3.2
 */
protected function processBuildRules(&$uri, $stage = self::PROCESS_DURING)
{
    if (!\array_key_exists('build' . $stage, $this->rules)) {
        throw new \InvalidArgumentException(sprintf('The %s stage is not registered. (%s)', $stage, __METHOD__));
    }
    foreach ($this->rules['build' . $stage] as $rule) {
        \call_user_func_array($rule, array(&$this, &$uri));
    }
}