function Assert::strlen
4 calls to Assert::strlen()
- Assert::length in vendor/
webmozart/ assert/ src/ Assert.php - @psalm-pure
- Assert::lengthBetween in vendor/
webmozart/ assert/ src/ Assert.php - Inclusive , so Assert::lengthBetween('asd', 3, 5); passes the assertion.
- Assert::maxLength in vendor/
webmozart/ assert/ src/ Assert.php - Inclusive max.
- Assert::minLength in vendor/
webmozart/ assert/ src/ Assert.php - Inclusive min.
File
-
vendor/
webmozart/ assert/ src/ Assert.php, line 2051
Class
- Assert
- Efficient assertions to validate the input/output of your methods.
Namespace
Webmozart\AssertCode
protected static function strlen($value) {
if (!\function_exists('mb_detect_encoding')) {
return \strlen($value);
}
if (false === ($encoding = \mb_detect_encoding($value))) {
return \strlen($value);
}
return \mb_strlen($value, $encoding);
}