8000 minor #5546 A bunch of doc fixes again (WouterJ) · symfony/symfony-docs@bc14326 · GitHub
[go: up one dir, main page]

Skip to content

Commit bc14326

Browse files
committed
minor #5546 A bunch of doc fixes again (WouterJ)
This PR was merged into the 2.3 branch. Discussion ---------- A bunch of doc fixes again Commits ------- 9a94a41 Review Quick Tour articles once again 63ccd0d Finalize review of reference documentation 74267cd Fixes due to docbot linting docs
2 parents 77555a6 + 9a94a41 commit bc14326

14 files changed

+211
-170
lines changed

reference/configuration/doctrine.rst

Lines changed: 66 additions & 60 deletions
Original file line numberDiff line numberDiff line change
@@ -324,8 +324,8 @@ you can control. The following configuration options exist for a mapping:
324324
type
325325
....
326326

327-
One of ``annotation``, ``xml``, ``yml``, ``php`` or ``staticphp``. This specifies
328-
which type of metadata type your mapping uses.
327+
One of ``annotation``, ``xml``, ``yml``, ``php`` or ``staticphp``. This
328+
specifies which type of metadata type your mapping uses.
329329

330330
dir
331331
...
@@ -339,27 +339,27 @@ that exist in the DIC (for example ``%kernel.root_dir%``).
339339
prefix
340340
......
341341

342-
A common namespace prefix that all entities of this mapping share. This prefix
343-
should never conflict with prefixes of other defined mappings otherwise some
344-
of your entities cannot be found by Doctrine. This option defaults to the
345-
bundle namespace + ``Entity``, for example for an application bundle called
346-
AcmeHelloBundle prefix would be ``Acme\HelloBundle\Entity``.
342+
A common namespace prefix that all entities of this mapping share. This
343+
prefix should never conflict with prefixes of other defined mappings otherwise
344+
some of your entities cannot be found by Doctrine. This option defaults
345+
to the bundle namespace + ``Entity``, for example for an application bundle
346+
called AcmeHelloBundle prefix would be ``Acme\HelloBundle\Entity``.
347347

348348
alias
349349
.....
350350

351351
Doctrine offers a way to alias entity namespaces to simpler, shorter names
352-
to be used in DQL queries or for Repository access. When using a bundle the
353-
alias defaults to the bundle name.
352+
to be used in DQL queries or for Repository access. When using a bundle
353+
the alias defaults to the bundle name.
354354

355355
is_bundle
356356
.........
357357

358358
This option is a derived value from ``dir`` and by default is set to ``true``
359359
if dir is relative proved by a ``file_exists()`` check that returns ``false``.
360360
It is ``false`` if the existence check returns ``true``. In this case an
361-
absolute path was specified and the metadata files are most likely in a directory
362-
outside of a bundle.
361+
absolute path was specified and the metadata files are most likely in a
362+
directory outside of a bundle.
363363

364364
.. index::
365365
single: Configuration; Doctrine DBAL
@@ -448,14 +448,15 @@ The following block shows all possible configuration keys:
448448
449449
.. note::
450450

451-
The ``server_version`` option was added in Doctrine DBAL 2.5, which is used
452-
by DoctrineBundle 1.3. The value of this option should match your database
453-
server version (use ``postgres -V`` or ``psql -V`` command to find
454-
your PostgreSQL version and ``mysql -V`` to get your MySQL version).
451+
The ``server_version`` option was added in Doctrine DBAL 2.5, which
452+
is used by DoctrineBundle 1.3. The value of this option should match
453+
your database server version (use ``postgres -V`` or ``psql -V`` command
454+
to find your PostgreSQL version and ``mysql -V`` to get your MySQL
455+
version).
455456

456-
If you don't define this option and you haven't created your database yet,
457-
you may get ``PDOException`` errors because Doctrine will try to guess the
458-
database server version automatically and none is available.
457+
If you don't define this option and you haven't created your database
458+
yet, you may get ``PDOException`` errors because Doctrine will try to
459+
guess the database server version automatically and none is available.
459460

460461
If you want to configure multiple connections in YAML, put them under the
461462
``connections`` key and give them a unique name:
@@ -524,24 +525,26 @@ Keep in mind that you can't use both syntaxes at the same time.
524525
Custom Mapping Entities in a Bundle
525526
-----------------------------------
526527

527-
Doctrine's ``auto_mapping`` feature loads annotation configuration from the
528-
``Entity/`` directory of each bundle *and* looks for other formats (e.g. YAML, XML)
529-
in the ``Resources/config/doctrine`` directory.
528+
Doctrine's ``auto_mapping`` feature loads annotation configuration from
529+
the ``Entity/`` directory of each bundle *and* looks for other formats (e.g.
530+
YAML, XML) in the ``Resources/config/doctrine`` directory.
530531

531-
If you store metadata somewhere else in your bundle, you can define your own mappings,
532-
where you tell Doctrine exactly *where* to look, along with some other configurations.
532+
If you store metadata somewhere else in your bundle, you can define your
533+
own mappings, where you tell Doctrine exactly *where* to look, along with
534+
some other configurations.
533535

534-
If you're using the ``auto_mapping`` configuration, you just need to overwrite the
535-
configurations you want. In this case it's important that the key of the mapping
536-
configurations corresponds to the name of the bundle.
536+
If you're using the ``auto_mapping`` configuration, you just need to overwrite
537+
the configurations you want. In this case it's important that the key of
538+
the mapping configurations corresponds to the name of the bundle.
537539

538-
For example, suppose you decide to store your ``XML`` configuration for ``AppBundle`` entities
539-
in the ``@AppBundle/SomeResources/config/doctrine`` directory instead:
540+
For example, suppose you decide to store your ``XML`` configuration for
541+
``AppBundle`` entities in the ``@AppBundle/SomeResources/config/doctrine``
542+
directory instead:
540543

541544
.. configuration-block::
542545

543546
.. code-block:: yaml
544-
547+
545548
doctrine:
546549
# ...
547550
orm:
@@ -552,22 +555,22 @@ in the ``@AppBundle/SomeResources/config/doctrine`` directory instead:
552555
AppBundle:
553556
type: xml
554557
dir: SomeResources/config/doctrine
555-
558+
556559
.. code-block:: xml
557-
560+
558561
<?xml version="1.0" charset="UTF-8" ?>
559562
<container xmlns="http://symfony.com/schema/dic/services"
560563
xmlns:doctrine="http://symfony.com/schema/dic/doctrine">
561-
564+
562565
<doctrine:config>
563566
<doctrine:orm auto-mapping="true">
564567
<mapping name="AppBundle" dir="SomeResources/config/doctrine" type="xml" />
565568
</doctrine:orm>
566569
</doctrine:config>
567570
</container>
568-
571+
569572
.. code-block:: php
570-
573+
571574
$container->loadFromExtension('doctrine', array(
572575
'orm' => array(
573576
'auto_mapping' => true,
@@ -582,13 +585,14 @@ Mapping Entities Outside of a Bundle
58258 F987 5

583586
You can also create new mappings, for example outside of the Symfony folder.
584587

585-
For example, the following looks for entity classes in the ``App\Entity`` namespace in the
586-
``src/Entity`` directory and gives them an ``App`` alias (so you can say things like ``App:Post``):
588+
For example, the following looks for entity classes in the ``App\Entity``
589+
namespace in the ``src/Entity`` directory and gives them an ``App`` alias
590+
(so you can say things like ``App:Post``):
587591

588592
.. configuration-block::
589593

590594
.. code-block:: yaml
591-
595+
592596
doctrine:
593597
# ...
594598
orm:
@@ -601,16 +605,16 @@ For example, the following looks for entity classes in the ``App\Entity`` namesp
601605
is_bundle: false
602606
prefix: App\Entity
603607
alias: App
604-
608+
605609
.. code-block:: xml
606-
610+
607611
<?xml version="1.0" charset="UTF-8" ?>
608612
<container xmlns="http://symfony.com/schema/dic/services"
609613
xmlns:doctrine="http://symfony.com/schema/dic/doctrine">
610-
614+
611615
<doctrine:config>
612616
<doctrine:orm>
613-
<mapping name="SomeEntityNamespace"
617+
<mapping name="SomeEntityNamespace"
614618
type="annotation"
615619
dir="%kernel.root_dir%/../src/Entity"
616620
is-bundle="false"
@@ -620,9 +624,9 @@ For example, the following looks for entity classes in the ``App\Entity`` namesp
620624
</doctrine:orm>
621625
</doctrine:config>
622626
</container>
623-
627+
624628
.. code-block:: php
625-
629+
626630
$container->loadFromExtension('doctrine', array(
627631
'orm' => array(
628632
'auto_mapping' => true,
@@ -641,31 +645,33 @@ For example, the following looks for entity classes in the ``App\Entity`` namesp
641645
Detecting a Mapping Configuration Format
642646
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
643647

644-
If the ``type`` on the bundle configuration isn't set,
645-
the DoctrineBundle will try to detect the correct mapping configuration format for
646-
the bundle.
648+
If the ``type`` on the bundle configuration isn't set, the DoctrineBundle
649+
will try to detect the correct mapping configuration format for the bundle.
647650

648-
DoctrineBundle will look for files matching ``*.orm.[FORMAT]`` (e.g. ``Post.orm.yml``)
649-
in the configured ``dir`` of your mapping (if you're mapping a bundle, then ``dir`` is
650-
relative to the bundle's directory).
651+
DoctrineBundle will look for files matching ``*.orm.[FORMAT]`` (e.g.
652+
``Post.orm.yml``) in the configured ``dir`` of your mapping (if you're mapping
653+
a bundle, then ``dir`` is relative to the bundle's directory).
651654

652655
The bundle looks for (in this order) XML, YAML and PHP files.
653-
Using the ``auto_mapping`` feature, every bundle can have only one configuration format.
654-
The bundle will stop as soon as it locates one.
656+
Using the ``auto_mapping`` feature, every bundle can have only one
657+
configuration format. The bundle will stop as soon as it locates one.
655658

656659
If it wasn't possible to determine a configuration format for a bundle,
657-
the DoctrineBundle will check if there is an ``Entity`` folder in the bundle's root directory.
658-
If the folder exist, Doctrine will fall back to using an annotation driver.
660+
the DoctrineBundle will check if there is an ``Entity`` folder in the bundle's
661+
root directory. If the folder exist, Doctrine will fall back to using an
662+
annotation driver.
659663

660-
Default Value of dir
664+
Default Value of Dir
661665
~~~~~~~~~~~~~~~~~~~~
662666

663-
If ``dir`` is not specified, then its default value depends on which configuration driver is being used.
664-
For drivers that rely on the PHP files (annotation, staticphp) it will
665-
be ``[Bundle]/Entity``. For drivers that are using configuration
666-
files (XML, YAML, ...) it will be ``[Bundle]/Resources/config/doctrine``.
667+
If ``dir`` is not specified, then its default value depends on which configuration
668+
driver is being used. For drivers that rely on the PHP files (annotation,
669+
staticphp) it will be ``[Bundle]/Entity``. For drivers that are using
670+
configuration files (XML, YAML, ...) it will be
671+
``[Bundle]/Resources/config/doctrine``.
667672

668-
If the ``dir`` configuration is set and the ``is_bundle`` configuration is ``true``,
669-
the DoctrineBundle will prefix the ``dir`` configuration with the path of the bundle.
673+
If the ``dir`` configuration is set and the ``is_bundle`` configuration
674+
is ``true``, the DoctrineBundle will prefix the ``dir`` configuration with
675+
the path of the bundle.
670676

671677
.. _`DQL User Defined Functions`: http://docs.doctrine-project.org/projects/doctrine-orm/en/latest/cookbook/dql-user-defined-functions.html

reference/configuration/security.rst

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@
44
SecurityBundle Configuration ("security")
55
=========================================
66

7-
The security system is one of the most powerful parts of Symfony, and can
7+
The security system is one of the most powerful parts of Symfony and can
88
largely be controlled via its configuration.
99

10-
Full default Configuration
10+
Full Default Configuration
1111
--------------------------
1212

1313
The following is the full default configuration for the security system.
@@ -306,8 +306,8 @@ post_only
306306
**type**: ``boolean`` **default**: ``true``
307307

308308
By default, you must submit your login form to the ``check_path`` URL as
309-
a POST request. By setting this option to ``false``, you can send a GET request
310-
to the ``check_path`` URL.
309+
a POST request. By setting this option to ``false``, you can send a GET
310+
request to the ``check_path`` URL.
311311

312312
Redirecting after Login
313313
~~~~~~~~~~~~~~~~~~~~~~~
@@ -328,7 +328,8 @@ Using the PBKDF2 Encoder: Security and Speed
328328
The `PBKDF2`_ encoder provides a high level of Cryptographic security, as
329329
recommended by the National Institute of Standards and Technology (NIST).
330330

331-
You can see an example of the ``pbkdf2`` encoder in the YAML block on this page.
331+
You can see an example of the ``pbkdf2`` encoder in the YAML block on this
332+
page.
332333

333334
But using PBKDF2 also warrants a warning: using it (with a high number
334335
of iterations) slows down the process. Thus, PBKDF2 should be used with
@@ -389,10 +390,11 @@ Using the BCrypt Password Encoder
389390
));
390391
391392
The ``cost`` can be in the range of ``4-31`` and determines how long a password
392-
will be encoded. Each increment of ``cost`` *doubles* the time it takes to
393-
encode a password.
393+
will be encoded. Each increment of ``cost`` *doubles* the time it takes
394+
to encode a password.
394395

395-
If you don't provide the ``cost`` option, the default cost of ``13`` is used.
396+
If you don't provide the ``cost`` option, the default cost of ``13`` is
397+
used.
396398

397399
.. note::
398400

@@ -418,8 +420,8 @@ Firewall Context
418420
Most applications will only need one :ref:`firewall <book-security-firewalls>`.
419421
But if your application *does* use multiple firewalls, you'll notice that
420422
if you're authenticated in one firewall, you're not automatically authenticated
421-
in another. In other words, the systems don't share a common "context": each
422-
firewall acts like a separate security system.
423+
in another. In other words, the systems don't share a common "context":
424+
each firewall acts like a separate security system.
423425

424426
However, each firewall has an optional ``context`` key (which defaults to
425427
the name of the firewall), which is used when storing and retrieving security

reference/configuration/swiftmailer.rst

Lines changed: 19 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,9 @@ options, see `Full Default Configuration`_
1111
The ``swiftmailer`` key configures Symfony's integration with Swift Mailer,
1212
which is responsible for creating and delivering email messages.
1313

14-
The following section lists all options that are available to configure a
15-
mailer. It is also possible to configure several mailers (see `Using Multiple Mailers`_).
14+
The following section lists all options that are available to configure
15+
a mailer. It is also possible to configure several mailers (see
16+
`Using Multiple Mailers`_).
1617

1718
Configuration
1819
-------------
@@ -121,9 +122,9 @@ sender_address
121122

122123
**type**: ``string``
123124

124-
If set, all messages will be delivered with this address as the "return path"
125-
address, which is where bounced messages should go. This is handled internally
126-
by Swift Mailer's ``Swift_Plugins_ImpersonatePlugin`` class.
125+
If set, all messages will be delivered with this address as the "return
126+
path" address, which is where bounced messages should go. This is handled
127+
internally by Swift Mailer's ``Swift_Plugins_ImpersonatePlugin`` class.
127128

128129
antiflood
129130
~~~~~~~~~
@@ -149,10 +150,10 @@ delivery_address
149150

150151
**type**: ``string``
151152

152-
If set, all email messages will be sent to this address instead of being sent
153-
to their actual recipients. This is often useful when developing. For example,
154-
by setting this in the ``config_dev.yml`` file, you can guarantee that all
155-
emails sent during development go to a single account.
153+
If set, all email messages will be sent to this address instead of being
154+
sent to their actual recipients. This is often useful when developing. For
155+
example, by setting this in the ``config_dev.yml`` file, you can guarantee
156+
that all emails sent during development go to a single account.
156157

157158
This uses ``Swift_Plugins_RedirectingPlugin``. Original recipients are available
158159
on the ``X-Swift-To``, ``X-Swift-Cc`` and ``X-Swift-Bcc`` headers.
@@ -162,27 +163,28 @@ delivery_whitelist
162163

163164
**type**: ``array``
164165

165-
Used in combination with ``delivery_address``. If set, emails matching any of these
166-
patterns will be delivered like normal, instead of being sent to ``delivery_address``.
167-
For details, see :ref:`the cookbook entry. <sending-to-a-specified-address-but-with-exceptions>`
166+
Used in combination with ``delivery_address``. If set, emails matching any
167+
of these patterns will be delivered like normal, instead of being sent to
168+
``delivery_address``. For details, see
169+
:ref:`the cookbook entry <sending-to-a-specified-address-but-with-exceptions>`.
168170

169171
disable_delivery
170172
~~~~~~~~~~~~~~~~
171173

172174
**type**: ``boolean`` **default**: ``false``
173175

174-
If true, the ``transport`` will automatically be set to ``null``, and no
176+
If true, the ``transport`` will automatically be set to ``null`` and no
175177
emails will actually be delivered.
176178

177179
logging
178180
~~~~~~~
179181

180182
**type**: ``boolean`` **default**: ``%kernel.debug%``
181183

182-
If true, Symfony's data collector will be activated for Swift Mailer and the
183-
information will be available in the profiler.
184+
If true, Symfony's data collector will be activated for Swift Mailer and
185+
the information will be available in the profiler.
184186

185-
Full default Configuration
187+
Full Default Configuration
186188
--------------------------
187189

188190
.. configuration-block::
@@ -240,7 +242,7 @@ Full default Configuration
240242
</swiftmailer:config>
241243
</container>
242244
243-
Using multiple Mailers
245+
Using Multiple Mailers
244246
----------------------
245247

246248
You can configure multiple mailers by grouping them under the ``mailers``

0 commit comments

Comments
 (0)
0