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

Commitf32ee43

Browse files
committed
Minor tweaks
1 parented1c6f8 commitf32ee43

File tree

2 files changed

+11
-10
lines changed

2 files changed

+11
-10
lines changed

‎reference/constraints/Cidr.rst‎

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,17 @@
11
Cidr
2-
==
2+
====
33

4-
Validates that a value is a valid CIDR notation. By default, this will validate
5-
the CIDR's IP and netmask both for version 4 and version 6, with the option of allowing
6-
only one type of IP version to be valid. It also supports a minimum and maximum range
7-
constraint in which the value of the netmask is valid.
4+
..versionadded::5.4
5+
6+
The ``Cidr`` constraint was introduced in Symfony 5.4.
7+
8+
Validates that a value is a valid `CIDR`_ (Classless Inter-Domain Routing) notation.
9+
By default, this will validate the CIDR's IP and netmask both for version 4 and 6,
10+
with the option of allowing only one type of IP version to be valid. It also supports
11+
a minimum and maximum range constraint in which the value of the netmask is valid.
812

913
========== ===================================================================
1014
Applies to:ref:`property or method<validation-property-target>`
11-
Options - `groups`_
12-
- `message`_
13-
- `netmaskRangeViolationMessage`_
14-
- `payload`_
15-
- `version`_
1615
Class:class:`Symfony\\Component\\Validator\\Constraints\\Cidr`
1716
Validator:class:`Symfony\\Component\\Validator\\Constraints\\CidrValidator`
1817
========== ===================================================================
@@ -153,3 +152,4 @@ of a variety of different values:
153152
``all``
154153
Validates all CIDR formats
155154

155+
.. _`CIDR`:https://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing

‎reference/constraints/map.rst.inc‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ String Constraints
2222
* :doc:`Regex</reference/constraints/Regex>`
2323
* :doc:`Hostname</reference/constraints/Hostname>`
2424
* :doc:`Ip</reference/constraints/Ip>`
25+
* :doc:`Cidr</reference/constraints/Cidr>`
2526
* :doc:`Json</reference/constraints/Json>`
2627
* :doc:`Uuid</reference/constraints/Uuid>`
2728
* :doc:`Ulid</reference/constraints/Ulid>`

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp