OptionsResolverInterface deprecated::setDefaults()

OptionsResolverInterface setDefaults(array $defaultValues)

Sets default option values.

The options can either be values of any types or closures that evaluate the option value lazily. These closures must have one of the following signatures:

function (Options $options) function (Options $options, $value)

The second parameter passed to the closure is the previously set default value, in case you are overwriting an existing default value.

The closures should return the lazily created option value.

Parameters

array $defaultValues A list of option names as keys and default values or closures as values.

Return Value

OptionsResolverInterface The resolver instance.
doc_Symfony
2016-10-28 06:25:21
Comments
Leave a Comment

Please login to continue.