You are here

public function RngEntityModel::__construct in RNG - Events and Registrations 8

Same name and namespace in other branches
  1. 8.2 src/RngEntityModel.php \Drupal\rng\RngEntityModel::__construct()
  2. 3.x src/RngEntityModel.php \Drupal\rng\RngEntityModel::__construct()

Constructs a new RngEntityModel object.

Parameters

\Drupal\Core\Entity\EntityTypeManagerInterface $entity_type_manager: The entity type manager.

\Drupal\rng\EventManagerInterface $event_manager: The RNG event manager.

\Drupal\courier\Service\IdentityChannelManagerInterface $identity_channel_manager: The identity channel manager.

File

src/RngEntityModel.php, line 77

Class

RngEntityModel
Enforces RNG model relationships.

Namespace

Drupal\rng

Code

public function __construct(EntityTypeManagerInterface $entity_type_manager, EventManagerInterface $event_manager, IdentityChannelManagerInterface $identity_channel_manager) {
  $this->registrationStorage = $entity_type_manager
    ->getStorage('registration');
  $this->registrantStorage = $entity_type_manager
    ->getStorage('registrant');
  $this->registrationGroupStorage = $entity_type_manager
    ->getStorage('registration_group');
  $this->ruleStorage = $entity_type_manager
    ->getStorage('rng_rule');
  $this->eventManager = $event_manager;
  $this->identityChannelManager = $identity_channel_manager;
}