You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Sep 13, 2024. It is now read-only.
Copy file name to clipboardExpand all lines: src/SimpleRules.php
+10Lines changed: 10 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -12,6 +12,7 @@ trait SimpleRules
12
12
{
13
13
/**
14
14
* The field under validation must exist in anotherField's values.
15
+
*
15
16
* @param string $anotherFiled
16
17
* @return static
17
18
*/
@@ -22,6 +23,7 @@ public function inArray(string $anotherFiled)
22
23
23
24
/**
24
25
* The field under validation must be included in the given list of values.
26
+
*
25
27
* @param array ...$values
26
28
* @return static
27
29
*/
@@ -33,6 +35,7 @@ public function in(...$values)
33
35
34
36
/**
35
37
* The field under validation must not be included in the given list of values.
38
+
*
36
39
* @param array ...$values
37
40
* @return static
38
41
*/
@@ -44,6 +47,7 @@ public function notIn(...$values)
44
47
45
48
/**
46
49
* The given field must match the field under validation.
50
+
*
47
51
* @param string $anotherField
48
52
* @return static
49
53
*/
@@ -54,6 +58,7 @@ public function same(string $anotherField)
54
58
55
59
/**
56
60
* The field under validation must have a different value than field.
61
+
*
57
62
* @param string $anotherFiled
58
63
* @return static
59
64
*/
@@ -64,6 +69,7 @@ public function different(string $anotherFiled)
64
69
65
70
/**
66
71
* The field under validation must have a minimum value. Strings, numerics, arrays, and files are evaluated in the same fashion as the size rule.
72
+
*
67
73
* @param integer $minimalValue For numeric data, value corresponds to a given integer value.
68
74
* For an array, size corresponds to the count of the array.
69
75
* For string data, value corresponds to the number of characters.
@@ -77,6 +83,7 @@ public function min($minimalValue)
77
83
78
84
/**
79
85
* The field under validation must be less than or equal to a maximum value. Strings, numerics, arrays, and files are evaluated in the same fashion as the size rule.
86
+
*
80
87
* @param integer $maximalValue For numeric data, value corresponds to a given integer value.
81
88
* For an array, size corresponds to the count of the array.
82
89
* For string data, value corresponds to the number of characters.
@@ -90,6 +97,7 @@ public function max($maximalValue)
90
97
91
98
/**
92
99
* The field under validation must have a size between the given min and max. Strings, numerics, arrays, and files are evaluated in the same fashion as the size rule.
100
+
*
93
101
* @param integer $minimalValue For numeric data, value corresponds to a given integer value.
94
102
* For an array, size corresponds to the count of the array.
95
103
* For string data, value corresponds to the number of characters.
@@ -123,6 +131,7 @@ public function size(int $value)
123
131
124
132
/**
125
133
* Run validation checks against a field only if that field is present in the input array.
134
+
*
126
135
* @return static
127
136
*/
128
137
publicfunctionsometimes()
@@ -132,6 +141,7 @@ public function sometimes()
132
141
133
142
/**
134
143
* The field under validation must pass custom validation rule.
0 commit comments