[OptionsResolver] clarify phpdoc

This commit is contained in:
Tobias Schultze 2012-05-25 23:40:38 +02:00
parent 0cac4049f7
commit e673a041be

View File

@ -59,10 +59,11 @@ interface OptionsResolverInterface
/** /**
* Sets optional options. * Sets optional options.
* *
* This method is identical to {@ĺink setDefaults()}, only that no default values * This method declares valid option names without setting default values for them.
* are configured for the options. If these options are not passed to * If these options are not passed to {@link resolve()} and no default has been set
* {@link resolve()}, they will be missing in the final options array. This can be * for them, they will be missing in the final options array. This can be helpful
* helpful if you want to determine whether an option has been set or not. * if you want to determine whether an option has been set or not because otherwise
* {@link resolve()} would trigger an exception for unknown options.
* *
* @param array $optionNames A list of option names. * @param array $optionNames A list of option names.
* *
@ -95,8 +96,9 @@ interface OptionsResolverInterface
* *
* @return OptionsResolverInterface The resolver instance. * @return OptionsResolverInterface The resolver instance.
* *
* @throws Exception\InvalidOptionsException If an option has not been defined for * @throws Exception\InvalidOptionsException If an option has not been defined
* which an allowed value is set. * (see {@link isKnown()}) for which
* an allowed value is set.
*/ */
function setAllowedValues(array $allowedValues); function setAllowedValues(array $allowedValues);