be keen to newcomers
This commit is contained in:
parent
848a83078c
commit
c008ee046a
@ -230,7 +230,7 @@ DependencyInjection
|
|||||||
supported.
|
supported.
|
||||||
|
|
||||||
* The ``strict`` attribute in service arguments has been removed.
|
* The ``strict`` attribute in service arguments has been removed.
|
||||||
The attribute is ignored since 3.0, so you can simply remove it.
|
The attribute is ignored since 3.0, you can remove it.
|
||||||
|
|
||||||
* Top-level anonymous services in XML are no longer supported.
|
* Top-level anonymous services in XML are no longer supported.
|
||||||
|
|
||||||
|
@ -24,8 +24,8 @@ use Symfony\Component\DependencyInjection\Reference;
|
|||||||
* The compiler pass is meant to register the mappings with the metadata
|
* The compiler pass is meant to register the mappings with the metadata
|
||||||
* chain driver corresponding to one of the object managers.
|
* chain driver corresponding to one of the object managers.
|
||||||
*
|
*
|
||||||
* For concrete implementations that are easy to use, see the
|
* For concrete implementations, see the RegisterXyMappingsPass classes
|
||||||
* RegisterXyMappingsPass classes in the DoctrineBundle resp.
|
* in the DoctrineBundle resp.
|
||||||
* DoctrineMongodbBundle, DoctrineCouchdbBundle and DoctrinePhpcrBundle.
|
* DoctrineMongodbBundle, DoctrineCouchdbBundle and DoctrinePhpcrBundle.
|
||||||
*
|
*
|
||||||
* @author David Buchmann <david@liip.ch>
|
* @author David Buchmann <david@liip.ch>
|
||||||
|
@ -20,7 +20,7 @@ use Symfony\Component\Security\Core\User\UserProviderInterface;
|
|||||||
/**
|
/**
|
||||||
* Wrapper around a Doctrine ObjectManager.
|
* Wrapper around a Doctrine ObjectManager.
|
||||||
*
|
*
|
||||||
* Provides easy to use provisioning for Doctrine entity users.
|
* Provides provisioning for Doctrine entity users.
|
||||||
*
|
*
|
||||||
* @author Fabien Potencier <fabien@symfony.com>
|
* @author Fabien Potencier <fabien@symfony.com>
|
||||||
* @author Johannes M. Schmitt <schmittjoh@gmail.com>
|
* @author Johannes M. Schmitt <schmittjoh@gmail.com>
|
||||||
|
@ -225,7 +225,7 @@ abstract class Descriptor implements DescriptorInterface
|
|||||||
return $builder->getDefinition($serviceId);
|
return $builder->getDefinition($serviceId);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Some service IDs don't have a Definition, they're simply an Alias
|
// Some service IDs don't have a Definition, they're aliases
|
||||||
if ($builder->hasAlias($serviceId)) {
|
if ($builder->hasAlias($serviceId)) {
|
||||||
return $builder->getAlias($serviceId);
|
return $builder->getAlias($serviceId);
|
||||||
}
|
}
|
||||||
|
@ -54,7 +54,7 @@ class CacheClearCommandTest extends TestCase
|
|||||||
// Ensure that all *.meta files are fresh
|
// Ensure that all *.meta files are fresh
|
||||||
$finder = new Finder();
|
$finder = new Finder();
|
||||||
$metaFiles = $finder->files()->in($this->kernel->getCacheDir())->name('*.php.meta');
|
$metaFiles = $finder->files()->in($this->kernel->getCacheDir())->name('*.php.meta');
|
||||||
// simply check that cache is warmed up
|
// check that cache is warmed up
|
||||||
$this->assertNotEmpty($metaFiles);
|
$this->assertNotEmpty($metaFiles);
|
||||||
$configCacheFactory = new ConfigCacheFactory(true);
|
$configCacheFactory = new ConfigCacheFactory(true);
|
||||||
|
|
||||||
|
@ -332,10 +332,10 @@ class ArrayNodeDefinition extends NodeDefinition implements ParentNodeDefinition
|
|||||||
* Allows extra config keys to be specified under an array without
|
* Allows extra config keys to be specified under an array without
|
||||||
* throwing an exception.
|
* throwing an exception.
|
||||||
*
|
*
|
||||||
* Those config values are simply ignored and removed from the
|
* Those config values are ignored and removed from the resulting
|
||||||
* resulting array. This should be used only in special cases where
|
* array. This should be used only in special cases where you want
|
||||||
* you want to send an entire configuration array through a special
|
* to send an entire configuration array through a special tree that
|
||||||
* tree that processes only part of the array.
|
* processes only part of the array.
|
||||||
*
|
*
|
||||||
* @param bool $remove Whether to remove the extra keys
|
* @param bool $remove Whether to remove the extra keys
|
||||||
*
|
*
|
||||||
|
@ -301,7 +301,7 @@ class PrototypedArrayNode extends ArrayNode
|
|||||||
}
|
}
|
||||||
|
|
||||||
foreach ($rightSide as $k => $v) {
|
foreach ($rightSide as $k => $v) {
|
||||||
// prototype, and key is irrelevant, so simply append the element
|
// prototype, and key is irrelevant, append the element
|
||||||
if (null === $this->keyAttribute) {
|
if (null === $this->keyAttribute) {
|
||||||
$leftSide[] = $v;
|
$leftSide[] = $v;
|
||||||
continue;
|
continue;
|
||||||
|
@ -17,7 +17,7 @@ use Symfony\Component\DependencyInjection\Definition;
|
|||||||
/**
|
/**
|
||||||
* {@inheritdoc}
|
* {@inheritdoc}
|
||||||
*
|
*
|
||||||
* Noop proxy instantiator - simply produces the real service instead of a proxy instance.
|
* Noop proxy instantiator - produces the real service instead of a proxy instance.
|
||||||
*
|
*
|
||||||
* @author Marco Pivetta <ocramius@gmail.com>
|
* @author Marco Pivetta <ocramius@gmail.com>
|
||||||
*/
|
*/
|
||||||
|
@ -968,7 +968,7 @@ class Crawler implements \Countable, \IteratorAggregate
|
|||||||
$expressions = [];
|
$expressions = [];
|
||||||
|
|
||||||
// An expression which will never match to replace expressions which cannot match in the crawler
|
// An expression which will never match to replace expressions which cannot match in the crawler
|
||||||
// We cannot simply drop
|
// We cannot drop
|
||||||
$nonMatchingExpression = 'a[name() = "b"]';
|
$nonMatchingExpression = 'a[name() = "b"]';
|
||||||
|
|
||||||
$xpathLen = \strlen($xpath);
|
$xpathLen = \strlen($xpath);
|
||||||
|
@ -29,7 +29,7 @@ use Symfony\Component\Finder\Iterator\SortableIterator;
|
|||||||
*
|
*
|
||||||
* All rules may be invoked several times.
|
* All rules may be invoked several times.
|
||||||
*
|
*
|
||||||
* All methods return the current Finder object to allow easy chaining:
|
* All methods return the current Finder object to allow chaining:
|
||||||
*
|
*
|
||||||
* $finder = Finder::create()->files()->name('*.php')->in(__DIR__);
|
* $finder = Finder::create()->files()->name('*.php')->in(__DIR__);
|
||||||
*
|
*
|
||||||
|
@ -78,7 +78,7 @@ class ArrayChoiceList implements ChoiceListInterface
|
|||||||
// If a deterministic value generator was passed, use it later
|
// If a deterministic value generator was passed, use it later
|
||||||
$this->valueCallback = $value;
|
$this->valueCallback = $value;
|
||||||
} else {
|
} else {
|
||||||
// Otherwise simply generate incrementing integers as values
|
// Otherwise generate incrementing integers as values
|
||||||
$i = 0;
|
$i = 0;
|
||||||
$value = function () use (&$i) {
|
$value = function () use (&$i) {
|
||||||
return $i++;
|
return $i++;
|
||||||
|
@ -32,7 +32,7 @@ class LazyChoiceList implements ChoiceListInterface
|
|||||||
/**
|
/**
|
||||||
* The callable creating string values for each choice.
|
* The callable creating string values for each choice.
|
||||||
*
|
*
|
||||||
* If null, choices are simply cast to strings.
|
* If null, choices are cast to strings.
|
||||||
*
|
*
|
||||||
* @var callable|null
|
* @var callable|null
|
||||||
*/
|
*/
|
||||||
|
@ -42,9 +42,9 @@ use Symfony\Component\PropertyAccess\PropertyPath;
|
|||||||
*
|
*
|
||||||
* In most cases, format (1) and format (2) will be the same. For example,
|
* In most cases, format (1) and format (2) will be the same. For example,
|
||||||
* a checkbox field uses a Boolean value for both internal processing and
|
* a checkbox field uses a Boolean value for both internal processing and
|
||||||
* storage in the object. In these cases you simply need to set a view
|
* storage in the object. In these cases you need to set a view transformer
|
||||||
* transformer to convert between formats (2) and (3). You can do this by
|
* to convert between formats (2) and (3). You can do this by calling
|
||||||
* calling addViewTransformer().
|
* addViewTransformer().
|
||||||
*
|
*
|
||||||
* In some cases though it makes sense to make format (1) configurable. To
|
* In some cases though it makes sense to make format (1) configurable. To
|
||||||
* demonstrate this, let's extend our above date field to store the value
|
* demonstrate this, let's extend our above date field to store the value
|
||||||
|
@ -163,7 +163,7 @@ class FormRenderer implements FormRendererInterface
|
|||||||
// "form_widget" in this example (again, no matter in which theme).
|
// "form_widget" in this example (again, no matter in which theme).
|
||||||
// If the designer wants to explicitly fallback to "form_widget" in their
|
// If the designer wants to explicitly fallback to "form_widget" in their
|
||||||
// custom "choice_widget", for example because they only want to wrap
|
// custom "choice_widget", for example because they only want to wrap
|
||||||
// a <div> around the original implementation, they can simply call the
|
// a <div> around the original implementation, they can call the
|
||||||
// widget() function again to render the block for the parent type.
|
// widget() function again to render the block for the parent type.
|
||||||
//
|
//
|
||||||
// The second kind is implemented in the following blocks.
|
// The second kind is implemented in the following blocks.
|
||||||
|
@ -80,7 +80,7 @@ class InlineFragmentRenderer extends RoutableFragmentRenderer
|
|||||||
return SubRequestHandler::handle($this->kernel, $subRequest, HttpKernelInterface::SUB_REQUEST, false);
|
return SubRequestHandler::handle($this->kernel, $subRequest, HttpKernelInterface::SUB_REQUEST, false);
|
||||||
} catch (\Exception $e) {
|
} catch (\Exception $e) {
|
||||||
// we dispatch the exception event to trigger the logging
|
// we dispatch the exception event to trigger the logging
|
||||||
// the response that comes back is simply ignored
|
// the response that comes back is ignored
|
||||||
if (isset($options['ignore_errors']) && $options['ignore_errors'] && $this->dispatcher) {
|
if (isset($options['ignore_errors']) && $options['ignore_errors'] && $this->dispatcher) {
|
||||||
$event = new GetResponseForExceptionEvent($this->kernel, $request, HttpKernelInterface::SUB_REQUEST, $e);
|
$event = new GetResponseForExceptionEvent($this->kernel, $request, HttpKernelInterface::SUB_REQUEST, $e);
|
||||||
|
|
||||||
|
@ -157,7 +157,7 @@ class LocaleDataGenerator
|
|||||||
// the name sorting
|
// the name sorting
|
||||||
// $name = $this->langBundle->getLanguageName($displayLocale, $lang, $region);
|
// $name = $this->langBundle->getLanguageName($displayLocale, $lang, $region);
|
||||||
|
|
||||||
// Some languages are simply not translated
|
// Some languages are not translated
|
||||||
// Example: "az" (Azerbaijani) has no translation in "af" (Afrikaans)
|
// Example: "az" (Azerbaijani) has no translation in "af" (Afrikaans)
|
||||||
if (null === ($name = $this->languageDataProvider->getName($lang, $displayLocale))) {
|
if (null === ($name = $this->languageDataProvider->getName($lang, $displayLocale))) {
|
||||||
return;
|
return;
|
||||||
|
@ -79,7 +79,7 @@ class Regex extends Constraint
|
|||||||
// Unescape the delimiter
|
// Unescape the delimiter
|
||||||
$pattern = str_replace('\\'.$delimiter, $delimiter, substr($this->pattern, 1, -1));
|
$pattern = str_replace('\\'.$delimiter, $delimiter, substr($this->pattern, 1, -1));
|
||||||
|
|
||||||
// If the pattern is inverted, we can simply wrap it in
|
// If the pattern is inverted, we can wrap it in
|
||||||
// ((?!pattern).)*
|
// ((?!pattern).)*
|
||||||
if (!$this->match) {
|
if (!$this->match) {
|
||||||
return '((?!'.$pattern.').)*';
|
return '((?!'.$pattern.').)*';
|
||||||
|
@ -86,8 +86,8 @@ interface ClassMetadataInterface extends MetadataInterface
|
|||||||
/**
|
/**
|
||||||
* Returns all metadata instances for the given named property.
|
* Returns all metadata instances for the given named property.
|
||||||
*
|
*
|
||||||
* If your implementation does not support properties, simply throw an
|
* If your implementation does not support properties, throw an exception
|
||||||
* exception in this method (for example a <tt>BadMethodCallException</tt>).
|
* in this method (for example a <tt>BadMethodCallException</tt>).
|
||||||
*
|
*
|
||||||
* @param string $property The property name
|
* @param string $property The property name
|
||||||
*
|
*
|
||||||
|
@ -94,7 +94,7 @@ class StateMachineValidatorTest extends TestCase
|
|||||||
|
|
||||||
(new StateMachineValidator())->validate($definition, 'foo');
|
(new StateMachineValidator())->validate($definition, 'foo');
|
||||||
|
|
||||||
// the test simply ensures that the validation does not fail (i.e. it does not throw any exceptions)
|
// the test ensures that the validation does not fail (i.e. it does not throw any exceptions)
|
||||||
$this->addToAssertionCount(1);
|
$this->addToAssertionCount(1);
|
||||||
|
|
||||||
// The graph looks like:
|
// The graph looks like:
|
||||||
|
@ -29,7 +29,7 @@ class WorkflowValidatorTest extends TestCase
|
|||||||
|
|
||||||
(new WorkflowValidator(true))->validate($definition, 'foo');
|
(new WorkflowValidator(true))->validate($definition, 'foo');
|
||||||
|
|
||||||
// the test simply ensures that the validation does not fail (i.e. it does not throw any exceptions)
|
// the test ensures that the validation does not fail (i.e. it does not throw any exceptions)
|
||||||
$this->addToAssertionCount(1);
|
$this->addToAssertionCount(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -64,7 +64,7 @@ class WorkflowValidatorTest extends TestCase
|
|||||||
|
|
||||||
(new WorkflowValidator())->validate($definition, 'foo');
|
(new WorkflowValidator())->validate($definition, 'foo');
|
||||||
|
|
||||||
// the test simply ensures that the validation does not fail (i.e. it does not throw any exceptions)
|
// the test ensures that the validation does not fail (i.e. it does not throw any exceptions)
|
||||||
$this->addToAssertionCount(1);
|
$this->addToAssertionCount(1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user