EntityChoiceList deprecated
class EntityChoiceList extends ObjectChoiceList
deprecated
A choice list presenting a list of Doctrine entities as choices.
Methods
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.
Details
at line line 114
__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.
at line line 155
array
getChoices()
Returns the list of entities.
at line line 171
array
getValues()
Returns the values for the entities.
at line line 188
array
getPreferredViews()
Returns the choice views of the preferred choices as nested array with the choice groups as top-level keys.
at line line 205
array
getRemainingViews()
Returns the choice views of the choices that are not preferred as nested array with the choice groups as top-level keys.
at line line 223
array
getChoicesForValues(array $values)
Returns the entities corresponding to the given values.
at line line 276
array
getValuesForChoices(array $entities)
Returns the values corresponding to the given entities.
at line line 317
array
getIndicesForChoices(array $entities)
deprecated
deprecated
Returns the indices corresponding to the given entities.
at line line 360
array
getIndicesForValues(array $values)
deprecated
deprecated
Returns the entities corresponding to the given values.