Merge branch '2.3' into 2.7

* 2.3:
  [DependencyInjection] Remove YAML check in CrossCheckTest
  [DependencyInjection] fix phpDoc
This commit is contained in:
Fabien Potencier 2016-04-14 17:17:41 +02:00
commit 44efeaaa27
22 changed files with 16 additions and 82 deletions

View File

@ -17,8 +17,6 @@ class Alias
private $public; private $public;
/** /**
* Constructor.
*
* @param string $id Alias identifier * @param string $id Alias identifier
* @param bool $public If this alias is public * @param bool $public If this alias is public
*/ */

View File

@ -34,8 +34,6 @@ class AnalyzeServiceReferencesPass implements RepeatablePassInterface
private $onlyConstructorArguments; private $onlyConstructorArguments;
/** /**
* Constructor.
*
* @param bool $onlyConstructorArguments Sets this Service Reference pass to ignore method calls * @param bool $onlyConstructorArguments Sets this Service Reference pass to ignore method calls
*/ */
public function __construct($onlyConstructorArguments = false) public function __construct($onlyConstructorArguments = false)

View File

@ -25,9 +25,6 @@ class Compiler
private $loggingFormatter; private $loggingFormatter;
private $serviceReferenceGraph; private $serviceReferenceGraph;
/**
* Constructor.
*/
public function __construct() public function __construct()
{ {
$this->passConfig = new PassConfig(); $this->passConfig = new PassConfig();

View File

@ -35,9 +35,6 @@ class PassConfig
private $optimizationPasses; private $optimizationPasses;
private $removingPasses; private $removingPasses;
/**
* Constructor.
*/
public function __construct() public function __construct()
{ {
$this->mergePass = new MergeExtensionConfigurationPass(); $this->mergePass = new MergeExtensionConfigurationPass();

View File

@ -32,8 +32,6 @@ class RepeatedPass implements CompilerPassInterface
private $passes; private $passes;
/** /**
* Constructor.
*
* @param RepeatablePassInterface[] $passes An array of RepeatablePassInterface objects * @param RepeatablePassInterface[] $passes An array of RepeatablePassInterface objects
* *
* @throws InvalidArgumentException when the passes don't implement RepeatablePassInterface * @throws InvalidArgumentException when the passes don't implement RepeatablePassInterface

View File

@ -25,8 +25,6 @@ class ServiceReferenceGraphEdge
private $value; private $value;
/** /**
* Constructor.
*
* @param ServiceReferenceGraphNode $sourceNode * @param ServiceReferenceGraphNode $sourceNode
* @param ServiceReferenceGraphNode $destNode * @param ServiceReferenceGraphNode $destNode
* @param string $value * @param string $value

View File

@ -29,8 +29,6 @@ class ServiceReferenceGraphNode
private $value; private $value;
/** /**
* Constructor.
*
* @param string $id The node identifier * @param string $id The node identifier
* @param mixed $value The node value * @param mixed $value The node value
*/ */

View File

@ -77,8 +77,6 @@ class Container implements IntrospectableContainerInterface
private $underscoreMap = array('_' => '', '.' => '_', '\\' => '_'); private $underscoreMap = array('_' => '', '.' => '_', '\\' => '_');
/** /**
* Constructor.
*
* @param ParameterBagInterface $parameterBag A ParameterBagInterface instance * @param ParameterBagInterface $parameterBag A ParameterBagInterface instance
*/ */
public function __construct(ParameterBagInterface $parameterBag = null) public function __construct(ParameterBagInterface $parameterBag = null)

View File

@ -24,9 +24,7 @@ abstract class ContainerAware implements ContainerAwareInterface
protected $container; protected $container;
/** /**
* Sets the container. * {@inheritdoc}
*
* @param ContainerInterface|null $container A ContainerInterface instance or null
*/ */
public function setContainer(ContainerInterface $container = null) public function setContainer(ContainerInterface $container = null)
{ {

View File

@ -42,8 +42,6 @@ class Definition
protected $arguments; protected $arguments;
/** /**
* Constructor.
*
* @param string|null $class The service class * @param string|null $class The service class
* @param array $arguments An array of arguments to pass to the service constructor * @param array $arguments An array of arguments to pass to the service constructor
*/ */

View File

@ -25,8 +25,6 @@ class DefinitionDecorator extends Definition
private $changes = array(); private $changes = array();
/** /**
* Constructor.
*
* @param string $parent The id of Definition instance to decorate. * @param string $parent The id of Definition instance to decorate.
*/ */
public function __construct($parent) public function __construct($parent)

View File

@ -23,8 +23,6 @@ abstract class Dumper implements DumperInterface
protected $container; protected $container;
/** /**
* Constructor.
*
* @param ContainerBuilder $container The service container to dump * @param ContainerBuilder $container The service container to dump
*/ */
public function __construct(ContainerBuilder $container) public function __construct(ContainerBuilder $container)

View File

@ -24,8 +24,6 @@ class ParameterNotFoundException extends InvalidArgumentException
private $alternatives; private $alternatives;
/** /**
* Constructor.
*
* @param string $key The requested parameter key * @param string $key The requested parameter key
* @param string $sourceId The service id that references the non-existent parameter * @param string $sourceId The service id that references the non-existent parameter
* @param string $sourceKey The parameter key that references the non-existent parameter * @param string $sourceKey The parameter key that references the non-existent parameter

View File

@ -27,9 +27,7 @@ use Symfony\Component\Config\Definition\ConfigurationInterface;
abstract class Extension implements ExtensionInterface, ConfigurationExtensionInterface abstract class Extension implements ExtensionInterface, ConfigurationExtensionInterface
{ {
/** /**
* Returns the base path for the XSD files. * {@inheritdoc}
*
* @return string The XSD base path
*/ */
public function getXsdValidationBasePath() public function getXsdValidationBasePath()
{ {
@ -37,9 +35,7 @@ abstract class Extension implements ExtensionInterface, ConfigurationExtensionIn
} }
/** /**
* Returns the namespace to be used for this extension (XML namespace). * {@inheritdoc}
*
* @return string The XML namespace
*/ */
public function getNamespace() public function getNamespace()
{ {

View File

@ -26,8 +26,6 @@ class ClosureLoader extends Loader
private $container; private $container;
/** /**
* Constructor.
*
* @param ContainerBuilder $container A ContainerBuilder instance * @param ContainerBuilder $container A ContainerBuilder instance
*/ */
public function __construct(ContainerBuilder $container) public function __construct(ContainerBuilder $container)

View File

@ -25,8 +25,6 @@ abstract class FileLoader extends BaseFileLoader
protected $container; protected $container;
/** /**
* Constructor.
*
* @param ContainerBuilder $container A ContainerBuilder instance * @param ContainerBuilder $container A ContainerBuilder instance
* @param FileLocatorInterface $locator A FileLocator instance * @param FileLocatorInterface $locator A FileLocator instance
*/ */

View File

@ -21,8 +21,6 @@ class Parameter
private $id; private $id;
/** /**
* Constructor.
*
* @param string $id The parameter key * @param string $id The parameter key
*/ */
public function __construct($id) public function __construct($id)
@ -31,8 +29,6 @@ class Parameter
} }
/** /**
* __toString.
*
* @return string The parameter key * @return string The parameter key
*/ */
public function __toString() public function __toString()

View File

@ -21,8 +21,6 @@ use Symfony\Component\DependencyInjection\Exception\LogicException;
class FrozenParameterBag extends ParameterBag class FrozenParameterBag extends ParameterBag
{ {
/** /**
* Constructor.
*
* For performance reasons, the constructor assumes that * For performance reasons, the constructor assumes that
* all keys are already lowercased. * all keys are already lowercased.
* *

View File

@ -26,8 +26,6 @@ class ParameterBag implements ParameterBagInterface
protected $resolved = false; protected $resolved = false;
/** /**
* Constructor.
*
* @param array $parameters An array of parameters * @param array $parameters An array of parameters
*/ */
public function __construct(array $parameters = array()) public function __construct(array $parameters = array())
@ -56,9 +54,7 @@ class ParameterBag implements ParameterBagInterface
} }
/** /**
* Gets the service container parameters. * {@inheritdoc}
*
* @return array An array of parameters
*/ */
public function all() public function all()
{ {
@ -66,13 +62,7 @@ class ParameterBag implements ParameterBagInterface
} }
/** /**
* Gets a service container parameter. * {@inheritdoc}
*
* @param string $name The parameter name
*
* @return mixed The parameter value
*
* @throws ParameterNotFoundException if the parameter is not defined
*/ */
public function get($name) public function get($name)
{ {
@ -109,11 +99,7 @@ class ParameterBag implements ParameterBagInterface
} }
/** /**
* Returns true if a parameter name is defined. * {@inheritdoc}
*
* @param string $name The parameter name
*
* @return bool true if the parameter name is defined, false otherwise
*/ */
public function has($name) public function has($name)
{ {
@ -131,7 +117,7 @@ class ParameterBag implements ParameterBagInterface
} }
/** /**
* Replaces parameter placeholders (%name%) by their values for all parameters. * {@inheritdoc}
*/ */
public function resolve() public function resolve()
{ {
@ -266,6 +252,9 @@ class ParameterBag implements ParameterBagInterface
return $value; return $value;
} }
/**
* {@inheritdoc}
*/
public function unescapeValue($value) public function unescapeValue($value)
{ {
if (is_string($value)) { if (is_string($value)) {

View File

@ -23,8 +23,6 @@ class Reference
private $strict; private $strict;
/** /**
* Constructor.
*
* @param string $id The service identifier * @param string $id The service identifier
* @param int $invalidBehavior The behavior when the service does not exist * @param int $invalidBehavior The behavior when the service does not exist
* @param bool $strict Sets how this reference is validated * @param bool $strict Sets how this reference is validated
@ -39,8 +37,6 @@ class Reference
} }
/** /**
* __toString.
*
* @return string The service identifier * @return string The service identifier
*/ */
public function __toString() public function __toString()

View File

@ -73,24 +73,17 @@ class CrossCheckTest extends \PHPUnit_Framework_TestCase
public function crossCheckLoadersDumpers() public function crossCheckLoadersDumpers()
{ {
$tests = array( return array(
array('services1.xml', 'xml'), array('services1.xml', 'xml'),
array('services2.xml', 'xml'), array('services2.xml', 'xml'),
array('services6.xml', 'xml'), array('services6.xml', 'xml'),
array('services8.xml', 'xml'), array('services8.xml', 'xml'),
array('services9.xml', 'xml'), array('services9.xml', 'xml'),
array('services1.yml', 'yaml'),
array('services2.yml', 'yaml'),
array('services6.yml', 'yaml'),
array('services8.yml', 'yaml'),
array('services9.yml', 'yaml'),
); );
if (class_exists('Symfony\Component\Yaml\Yaml')) {
$tests = array_merge($tests, array(
array('services1.yml', 'yaml'),
array('services2.yml', 'yaml'),
array('services6.yml', 'yaml'),
array('services8.yml', 'yaml'),
array('services9.yml', 'yaml'),
));
}
return $tests;
} }
} }

View File

@ -29,8 +29,6 @@ class Variable
private $name; private $name;
/** /**
* Constructor.
*
* @param string $name * @param string $name
*/ */
public function __construct($name) public function __construct($name)