W3cubDocs

/Drupal 8

public function EntityTypeRepositoryInterface::getEntityTypeLabels

public EntityTypeRepositoryInterface::getEntityTypeLabels($group = FALSE)

Builds a list of entity type labels suitable for a Form API options list.

Parameters

bool $group: (optional) Whether to group entity types by plugin group (e.g. 'content', 'config'). Defaults to FALSE.

Return value

array An array of entity type labels, keyed by entity type name.

File

core/lib/Drupal/Core/Entity/EntityTypeRepositoryInterface.php, line 20

Class

EntityTypeRepositoryInterface
Provides an interface for helper methods for loading entity types.

Namespace

Drupal\Core\Entity

Code

public function getEntityTypeLabels($group = FALSE);

© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/core!lib!Drupal!Core!Entity!EntityTypeRepositoryInterface.php/function/EntityTypeRepositoryInterface::getEntityTypeLabels/8.1.x