public function IdentityChannelManager::getCourierIdentityPluginID in Courier 8
Same name and namespace in other branches
- 2.x src/Service/IdentityChannelManager.php \Drupal\courier\Service\IdentityChannelManager::getCourierIdentityPluginID()
Get IdentityChannel plugin ID bridging a identity and message combination.
Parameters
string $channel_type_id: An channel entity type ID.
string $identity_type_id: An identity entity type ID.
Return value
string|NULL IdentityChannel plugin ID, or NULL if no plugin was found.
Overrides IdentityChannelManagerInterface::getCourierIdentityPluginID
1 call to IdentityChannelManager::getCourierIdentityPluginID()
- IdentityChannelManager::getCourierIdentity in src/
Service/ IdentityChannelManager.php - Instantiate a CourierIdentity plugin instance.
File
- src/
Service/ IdentityChannelManager.php, line 36
Class
- IdentityChannelManager
- Manages discovery and instantiation of CourierIdentity plugins.
Namespace
Drupal\courier\ServiceCode
public function getCourierIdentityPluginID($channel_type_id, $identity_type_id) {
foreach ($this
->getNonFallbackDefinitions() as $plugin_id => $plugin) {
if ($plugin['channel'] == $channel_type_id && $identity_type_id == $plugin['identity']) {
return $plugin_id;
}
}
return NULL;
}