Add PHP-doc comments in new methods (routeIsExists, getRouteByName, getUri).

This commit is contained in:
Alexander Demidov
2012-05-25 16:30:45 +04:00
parent 8efaf2a0a7
commit 1cf82d7442

View File

@ -64,16 +64,29 @@ class Router
return $this->route; return $this->route;
} }
/**
* @param $name
* @return bool
*/
protected function routeIsExists($name) protected function routeIsExists($name)
{ {
return array_key_exists($name, $this->routes); return array_key_exists($name, $this->routes);
} }
/**
* @param $name
* @return Route
*/
protected function getRouteByName($name) protected function getRouteByName($name)
{ {
return $this->routes[$name]; return $this->routes[$name];
} }
/**
* @param null $route_name
* @return string
* @throws ErrorException
*/
public function getUri($route_name = null) public function getUri($route_name = null)
{ {
if (is_null($route_name)) { if (is_null($route_name)) {