Symfony\Component\Form\Extension\Core\ChoiceList\SimpleChoiceList::addChoices
Recursively adds the given choices to the list.
Takes care of splitting the single $choices array passed in the constructor into choices and labels.
Signature
protected function addChoices(array&
$bucketForPreferred,
array&
$bucketForRemaining,
Traversable
$choices,
array
$labels,
array
$preferredChoices )
Parameters
$bucketForPreferred
— array- The bucket where to store the preferred
view objects. $bucketForRemaining
— array- The bucket where to store the
non-preferred view objects. $choices
— object- The list of choices.
$labels
— array- Ignored.
$preferredChoices
— array- The preferred choices.