throw new Exception(sprintf("Can't connect %s; path has no action.", $path));
}
- $allpaths[] = $path;
+ $this->allpaths[] = $path;
$action = $args[self::ACTION];
}
}
- $regex = $this->makeRegex($path, $paramPatterns);
+ $regex = self::makeRegex($path, $paramPatterns);
$this->variables[] = array($args, $regex, $paramNames);
}
}
- throw new Exception(sprintf('No match for path "%s"', $path));
+ throw new NoRouteMapException($path);
}
function generate($args, $qstring, $fragment)
return $match['name'];
}
- protected function makeRegex($path, $paramPatterns)
+ static function makeRegex($path, $paramPatterns)
{
$pr = new PatternReplacer($paramPatterns);