function Escaper::requiresDoubleQuoting
Determines if a PHP value would require double quoting in YAML.
Parameters
string $value A PHP value:
1 call to Escaper::requiresDoubleQuoting()
- Inline::dump in vendor/
symfony/ yaml/ Inline.php - Dumps a given PHP variable to a YAML string.
File
-
vendor/
symfony/ yaml/ Escaper.php, line 53
Class
- Escaper
- Escaper encapsulates escaping rules for single and double-quoted YAML strings.
Namespace
Symfony\Component\YamlCode
public static function requiresDoubleQuoting(string $value) : bool {
return 0 < preg_match('/' . self::REGEX_CHARACTER_TO_ESCAPE . '/u', $value);
}