public function DeleteHandler::__construct in Salesforce Suite 8.4
Same name and namespace in other branches
- 8.3 modules/salesforce_pull/src/DeleteHandler.php \Drupal\salesforce_pull\DeleteHandler::__construct()
- 5.0.x modules/salesforce_pull/src/DeleteHandler.php \Drupal\salesforce_pull\DeleteHandler::__construct()
Constructor.
Parameters
\Drupal\salesforce\Rest\RestClientInterface $sfapi: RestClient object.
\Drupal\Core\Entity\EntityTypeManagerInterface $entity_type_manager: Entity Manager service.
\Drupal\Core\State\StateInterface $state: State service.
\Symfony\Component\EventDispatcher\EventDispatcherInterface $event_dispatcher: Event dispatcher service.
Throws
\Drupal\Component\Plugin\Exception\InvalidPluginDefinitionException
\Drupal\Component\Plugin\Exception\PluginNotFoundException
File
- modules/
salesforce_pull/ src/ DeleteHandler.php, line 88
Class
- DeleteHandler
- Handles pull cron deletion of Drupal entities based onSF mapping settings.
Namespace
Drupal\salesforce_pullCode
public function __construct(RestClientInterface $sfapi, EntityTypeManagerInterface $entity_type_manager, StateInterface $state, EventDispatcherInterface $event_dispatcher) {
$this->sfapi = $sfapi;
$this->etm = $entity_type_manager;
$this->mappingStorage = $this->etm
->getStorage('salesforce_mapping');
$this->mappedObjectStorage = $this->etm
->getStorage('salesforce_mapped_object');
$this->state = $state;
$this->eventDispatcher = $event_dispatcher;
}