[YAML] Refine the return value of Yaml::parse()

This commit is contained in:
Jakub Zalas 2016-01-27 16:53:33 +00:00
parent 828fba4e1d
commit 6a806e32b7

View File

@ -21,10 +21,7 @@ use Symfony\Component\Yaml\Exception\ParseException;
class Yaml class Yaml
{ {
/** /**
* Parses YAML into a PHP array. * Parses YAML into a PHP value.
*
* The parse method, when supplied with a YAML stream (string or file),
* will do its best to convert YAML in a file into a PHP array.
* *
* Usage: * Usage:
* <code> * <code>
@ -40,7 +37,7 @@ class Yaml
* @param bool $exceptionOnInvalidType True if an exception must be thrown on invalid types false otherwise * @param bool $exceptionOnInvalidType True if an exception must be thrown on invalid types false otherwise
* @param bool $objectSupport True if object support is enabled, false otherwise * @param bool $objectSupport True if object support is enabled, false otherwise
* *
* @return array The YAML converted to a PHP array * @return mixed The YAML converted to a PHP value
* *
* @throws ParseException If the YAML is not valid * @throws ParseException If the YAML is not valid
*/ */