Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit2a084c9

Browse files
committed
add validation config reference section
1 parent87365fa commit2a084c9

File tree

1 file changed

+44
-0
lines changed

1 file changed

+44
-0
lines changed

‎reference/configuration/framework.rst‎

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,11 @@ Configuration
4848
* `translator`_
4949
*:ref:`enabled<translator.enabled>`
5050
* `fallback`_
51+
* `validation`_
52+
* `cache`_
53+
* `enable_annotations`_
54+
* `translation_domain`_
55+
* `strict_email`_
5156

5257
secret
5358
~~~~~~
@@ -517,6 +522,44 @@ This option is used when the translation key for the current locale wasn't found
517522

518523
For more details, see:doc:`/book/translation`.
519524

525+
validation
526+
~~~~~~~~~~
527+
528+
cache
529+
.....
530+
531+
**type**: ``string``
532+
533+
This value is used to determine the service that is used to persist class
534+
metadata in a cache. The actual service name is built by prefix the configured
535+
value with ``validator.mapping.cache.`` (e.g. if the value is ``apc``, the
536+
``validator.mapping.cache.apc`` service will be injected). The service has
537+
to implement the:class:`Symfony\\Component\\Validator\\Mapping\\Cache\\CacheInterface`.
538+
539+
enable_annotations
540+
..................
541+
542+
**type**: ``Boolean`` **default**: ``false``
543+
544+
If this option is enabled, validation constraints can be defined using annotations.
545+
546+
translation_domain
547+
..................
548+
549+
**type**: ``string`` **default**: ``validators``
550+
551+
The translation domain that is used when translating validation constraint
552+
error messages.
553+
554+
strict_email
555+
............
556+
557+
**type**: ``Boolean`` **default**: ``false``
558+
559+
If this option is enabled, the `egulias/email-validator`_ library will be
560+
used by the:doc:`/reference/constraints/Email` constraint validator. Otherwise,
561+
the validator uses a simple regular expression to validate email addresses.
562+
520563
Full default Configuration
521564
--------------------------
522565

@@ -646,3 +689,4 @@ Full default Configuration
646689
647690
.. _`protocol-relative`:http://tools.ietf.org/html/rfc3986#section-4.2
648691
.. _`PhpStormOpener`:https://github.com/pinepain/PhpStormOpener
692+
.. _`egulias/email-validator`:https://github.com/egulias/EmailValidator

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp