Skip to content

Commit

Permalink
Merge pull request sonata-project#3403 from Soullivaneuh/routes-colle…
Browse files Browse the repository at this point in the history
…ction-phpdoc

Fix PHPDoc for route collection
  • Loading branch information
soullivaneuh committed Nov 4, 2015
2 parents f7d772b + 66e9eb7 commit 267c65e
Showing 1 changed file with 21 additions and 6 deletions.
27 changes: 21 additions & 6 deletions Route/RouteCollection.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,29 @@

class RouteCollection
{
/**
* @var Route[]
*/
protected $elements = array();

/**
* @var string
*/
protected $baseCodeRoute;

/**
* @var string
*/
protected $baseRouteName;

/**
* @var string
*/
protected $baseControllerName;

/**
* @var string
*/
protected $baseRoutePattern;

/**
Expand All @@ -46,7 +61,7 @@ public function __construct($baseCodeRoute, $baseRouteName, $baseRoutePattern, $
* @param array $requirements
* @param array $options
*
* @return \Sonata\AdminBundle\Route\RouteCollection
* @return RouteCollection
*/
public function add($name, $pattern = null, array $defaults = array(), array $requirements = array(), array $options = array())
{
Expand Down Expand Up @@ -88,7 +103,7 @@ public function getCode($name)
/**
* @param RouteCollection $collection
*
* @return \Sonata\AdminBundle\Route\RouteCollection
* @return RouteCollection
*/
public function addCollection(RouteCollection $collection)
{
Expand All @@ -114,7 +129,7 @@ private function resolve($element)
}

/**
* @return array
* @return Route[]
*/
public function getElements()
{
Expand Down Expand Up @@ -158,7 +173,7 @@ public function get($name)
/**
* @param string $name
*
* @return \Sonata\AdminBundle\Route\RouteCollection
* @return RouteCollection
*/
public function remove($name)
{
Expand All @@ -172,7 +187,7 @@ public function remove($name)
*
* @param array $routeList
*
* @return \Sonata\AdminBundle\Route\RouteCollection
* @return RouteCollection
*/
public function clearExcept(array $routeList)
{
Expand All @@ -194,7 +209,7 @@ public function clearExcept(array $routeList)
/**
* Remove all routes.
*
* @return \Sonata\AdminBundle\Route\RouteCollection
* @return RouteCollection
*/
public function clear()
{
Expand Down

0 comments on commit 267c65e

Please sign in to comment.