8000 --- · symfony/symfony-docs@3a49101 · GitHub
[go: up one dir, main page]

Skip to content

Commit 3a49101

Browse files
committed
---
yaml --- r: 73447 b: refs/heads/5.x c: 2e5f7f4 h: refs/heads/5.x i: 73445: ad4f961 73443: e8be31a 73439: 121d4d1
1 parent 91fd88f commit 3a49101

23 files changed

+386
-105
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,4 +92,4 @@ refs/heads/3.3: 93587037fef6a2f40e0cbdea41754e1e76255fe6
9292
refs/heads/weaverryan-patch-1: a52aee3dceba3357dd59558677811a2ff86d1357
9393
refs/heads/4.0: e887a8b5e5d102235545837506f1d4e883f051a5
9494
refs/heads/4.1: 67f3845bc17a81379c609af1944099706e5b429e
95-
refs/heads/5.x: 45d6b28fe370d4be1a6bb003f93655dff2d79d69
95+
refs/heads/5.x: 2e5f7f4b5157ad97c368fc90ac79d17d4affd8de

trunk/_build/redirection_map

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -427,3 +427,4 @@
427427
/contributing/community/other /contributing/community
428428
/profiler/storage /profiler
429429
/setup/composer /setup
430+
/security/security_checker /setup
22.6 KB
Loading

trunk/components/lock.rst

Lines changed: 22 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -24,16 +24,21 @@ Locks are used to guarantee exclusive access to some shared resource. In
2424
Symfony applications, you can use locks for example to ensure that a command is
2525
not executed more than once at the same time (on the same or different servers).
2626

27-
Locks are created using a :class:`Symfony\\Component\\Lock\\Factory` class,
27+
Locks are created using a :class:`Symfony\\Component\\Lock\\LockFactory` class,
2828
which in turn requires another class to manage the storage of locks::
2929

30-
use Symfony\Component\Lock\Factory;
30+
use Symfony\Component\Lock\LockFactory;
3131
use Symfony\Component\Lock\Store\SemaphoreStore;
3232

3333
$store = new SemaphoreStore();
34-
$factory = new Factory($store);
34+
$factory = new LockFactory($store);
3535

36-
The lock is created by calling the :method:`Symfony\\Component\\Lock\\Factory::createLock`
36+
.. versionadded:: 4.4
37+
38+
The ``Symfony\Component\Lock\LockFactory`` class was introduced in Symfony
39+
4.4. In previous versions it was called ``Symfony\Component\Lock\Factory``.
40+
41+
The lock is created by calling the :method:`Symfony\\Component\\Lock\\LockFactory::createLock`
3742
method. Its first argument is an arbitrary string that represents the locked
3843
resource. Then, a call to the :method:`Symfony\\Component\\Lock\\LockInterface::acquire`
3944
method will try to acquire the lock::
@@ -56,7 +61,7 @@ method can be safely called repeatedly, even if the lock is already acquired.
5661
Unlike other implementations, the Lock Component distinguishes locks
5762
instances even when they are created for the same resource. If a lock has
5863
to be used by several services, they should share the same ``Lock`` instance
59-
returned by the ``Factory::createLock`` method.
64+
returned by the ``LockFactory::createLock`` method.
6065

6166
.. tip::
6267

@@ -77,13 +82,13 @@ until the lock is acquired.
7782
Some of the built-in ``Store`` classes support this feature. When they don't,
7883
they can be decorated with the ``RetryTillSaveStore`` class::
7984

80-
use Symfony\Component\Lock\Factory;
85+
use Symfony\Component\Lock\LockFactory;
8186
use Symfony\Component\Lock\Store\RedisStore;
8287
use Symfony\Component\Lock\Store\RetryTillSaveStore;
8388

8489
$store = new RedisStore(new \Predis\Client('tcp://localhost:6379'));
8590
$store = new RetryTillSaveStore($store);
86-
$factory = new Factory($store);
91+
$factory = new LockFactory($store);
8792

8893
$lock = $factory->createLock('notification-flush');
8994
$lock->acquire(true);
@@ -208,8 +213,10 @@ Available Stores
208213
----------------
209214

210215
Locks are created and managed in ``Stores``, which are classes that implement
211-
:class:`Symfony\\Component\\Lock\\StoreInterface`. The component includes the
212-
following built-in store types:
216+
:class:`Symfony\\Component\\Lock\\PersistStoreInterface` and, optionally,
217+
:class:`Symfony\\Component\\Lock\\BlockingStoreInterface`.
218+
219+
The component includes the following built-in store types:
213220

214221
============================================ ====== ======== ========
215222
Store Scope Blocking Expiring
@@ -222,6 +229,12 @@ Store Scope Blocking Expiring
222229
:ref:`ZookeeperStore <lock-store-zookeeper>` remote no no
223230
============================================ ====== ======== ========
224231

232+
.. versionadded:: 4.4
233+
234+
The ``PersistStoreInterface`` and ``BlockingStoreInterface`` interfaces were
235+
introduced in Symfony 4.4. In previous versions there was only one interface
236+
called ``Symfony\Component\Lock\StoreInterface``.
237+
225238
.. _lock-store-flock:
226239

227240
FlockStore

trunk/components/mime.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -254,6 +254,8 @@ MIME types and file name extensions::
254254
These methods return arrays with one or more elements. The element position
255255
indicates its priority, so the first returned extension is the preferred one.
256256

257+
.. _components-mime-type-guess:
258+
257259
Guessing the MIME Type
258260
~~~~~~~~~~~~~~~~~~~~~~
259261

trunk/components/phpunit_bridge.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -521,6 +521,7 @@ constraint to test the validity of the email domain::
521521
$result = $validator->validate('foo@example.com', $constraint);
522522

523523
// ...
524+
}
524525
}
525526

526527
In order to avoid making a real network connection, add the ``@dns-sensitive``
@@ -545,6 +546,7 @@ the data you expect to get for the given hosts::
545546
$result = $validator->validate('foo@example.com', $constraint);
546547

547548
// ...
549+
}
548550
}
549551

550552
The ``withMockedHosts()`` method configuration is defined as an array. The keys

trunk/components/property_info.rst

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -351,8 +351,9 @@ ReflectionExtractor
351351

352352
Using PHP reflection, the :class:`Symfony\\Component\\PropertyInfo\\Extractor\\ReflectionExtractor`
353353
provides list, type and access information from setter and accessor methods.
354-
It can also give the type of a property, and if it is initializable through the
355-
constructor. It supports return and scalar types for PHP 7::
354+
It can also give the type of a property (even extracting it from the constructor
355+
arguments), and if it is initializable through the constructor. It supports
356+
return and scalar types for PHP 7::
356357

357358
use Symfony\Component\PropertyInfo\Extractor\ReflectionExtractor;
358359

@@ -371,6 +372,11 @@ constructor. It supports return and scalar types for PHP 7::
371372
// Initializable information
372373
$reflectionExtractor->isInitializable($class, $property);
373374

375+
.. versionadded:: 4.1
376+
377+
The feature to extract the property types from constructor arguments was
378+
introduced in Symfony 4.1.
379+
374380
.. note::
375381

376382
When using the Symfony framework, this service is automatically registered

trunk/components/var_dumper.rst

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -224,6 +224,13 @@ option. Read more about this and other options in
224224
are supported (``Ctrl. + G`` or ``Cmd. + G``, ``F3``, etc.) When
225225
finished, press ``Esc.`` to hide the box again.
226226

227+
If you want to use your browser search input, press ``Ctrl. + F`` or
228+
``Cmd. + F`` again while having focus on VarDumper's search input.
229+
230+
.. versionadded:: 4.4
231+
232+
The feature to use the browser search input was introduced in Symfony 4.4.
233+
227234
Using the VarDumper Component in your PHPUnit Test Suite
228235
--------------------------------------------------------
229236

trunk/contributing/code/security.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,8 @@ Security Advisories
169169
.. tip::
170170

171171
You can check your Symfony application for known security vulnerabilities
172-
using the ``security:check`` command (see :doc:`/security/security_checker`).
172+
using the ``security:check`` command provided by the
173+
:ref:`Symfony security checker <security-checker>`.
173174

174175
Check the `Security Advisories`_ blog category for a list of all security
175176
vulnerabilities that were fixed in Symfony releases, starting from Symfony

trunk/contributing/documentation/format.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -210,9 +210,9 @@ Symfony 5.0 were released today, 4.0 to 4.4 ``versionadded`` and ``deprecated``
210210
tags would be removed from the new ``5.0`` branch.
211211

212212
.. _reStructuredText: http://docutils.sourceforge.net/rst.html
213-
.. _Sphinx: http://sphinx-doc.org/
213+
.. _Sphinx: https://www.sphinx-doc.org/
214214
.. _`Symfony documentation`: https://github.com/symfony/symfony-docs
215-
.. _`reStructuredText Primer`: http://sphinx-doc.org/rest.html
215+
.. _`reStructuredText Primer`: https://www.sphinx-doc.org/en/master/usage/restructuredtext/basics.html
216216
.. _`reStructuredText Reference`: http://docutils.sourceforge.net/docs/user/rst/quickref.html
217-
.. _`Sphinx Markup Constructs`: http://sphinx-doc.org/markup/
217+
.. _`Sphinx Markup Constructs`: https://www.sphinx-doc.org/en/1.7/markup/index.html
218218
.. _`supported languages`: http://pygments.org/languages/

0 commit comments

Comments
 (0)
0