class EntityChoiceList extends ObjectChoiceList
A choice list presenting a list of Doctrine entities as choices
__construct(ObjectManager $manager, string $class, string $labelPath = null, EntityLoaderInterface $entityLoader = null, array|Traversable|null $entities = null, array $preferredEntities = array(), string $groupPath = null, PropertyAccessorInterface $propertyAccessor = null) Creates a new entity choice list. | ||
array | getChoices() Returns the list of entities | |
array | getValues() Returns the values for the entities | |
array | getPreferredViews() Returns the choice views of the preferred choices as nested array with the choice groups as top-level keys. | |
array | getRemainingViews() Returns the choice views of the choices that are not preferred as nested array with the choice groups as top-level keys. | |
array | getChoicesForValues(array $values) Returns the entities corresponding to the given values. | |
array | getValuesForChoices(array $entities) Returns the values corresponding to the given entities. | |
array | getIndicesForChoices(array $entities) Returns the indices corresponding to the given entities. | |
array | getIndicesForValues(array $values) Returns the entities corresponding to the given values. |
Creates a new entity choice list.
Returns the list of entities
Returns the values for the entities
Returns the choice views of the preferred choices as nested array with the choice groups as top-level keys.
Returns the choice views of the choices that are not preferred as nested array with the choice groups as top-level keys.
Returns the entities corresponding to the given values.
Returns the values corresponding to the given entities.
Returns the indices corresponding to the given entities.
Returns the entities corresponding to the given values.
© 2004–2016 Fabien Potencier
Licensed under the MIT License.
http://api.symfony.com/2.7/Symfony/Bridge/Doctrine/Form/ChoiceList/EntityChoiceList.html