function Assert::minCount
Does not check if $array is countable, this can generate a warning on php versions after 7.2.
Parameters
Countable|array $array:
int|float $min:
string $message:
Throws
File
-
vendor/
webmozart/ assert/ src/ Assert.php, line 1759
Class
- Assert
- Efficient assertions to validate the input/output of your methods.
Namespace
Webmozart\AssertCode
public static function minCount($array, $min, $message = '') {
if (\count($array) < $min) {
static::reportInvalidArgument(\sprintf($message ?: 'Expected an array to contain at least %2$d elements. Got: %d', \count($array), $min));
}
}