You are here

public function EventMeta::getRegistrants in RNG - Events and Registrations 3.x

Same name and namespace in other branches
  1. 8.2 src/EventMeta.php \Drupal\rng\EventMeta::getRegistrants()
  2. 8 src/EventMeta.php \Drupal\rng\EventMeta::getRegistrants()

Get all registrants for this event.

Parameters

string $entity_type_id: The registrant entity type, or NULL to get all.

Return value

\Drupal\rng\Entity\RegistrantInterface[] An array of registrant entities.

Overrides EventMetaInterface::getRegistrants

File

src/EventMeta.php, line 476

Class

EventMeta
Meta event wrapper for RNG.

Namespace

Drupal\rng

Code

public function getRegistrants($entity_type_id = NULL) {
  $query = $this
    ->buildRegistrantQuery($entity_type_id);
  return $this->entityManager
    ->getStorage('registrant')
    ->loadMultiple($query
    ->execute());
}