public function LingotekWorkbenchModerationSettingsForm::__construct in Lingotek Translation 3.2.x
Same name and namespace in other branches
- 8.2 src/Moderation/LingotekWorkbenchModerationSettingsForm.php \Drupal\lingotek\Moderation\LingotekWorkbenchModerationSettingsForm::__construct()
- 4.0.x src/Moderation/LingotekWorkbenchModerationSettingsForm.php \Drupal\lingotek\Moderation\LingotekWorkbenchModerationSettingsForm::__construct()
- 3.1.x src/Moderation/LingotekWorkbenchModerationSettingsForm.php \Drupal\lingotek\Moderation\LingotekWorkbenchModerationSettingsForm::__construct()
- 3.3.x src/Moderation/LingotekWorkbenchModerationSettingsForm.php \Drupal\lingotek\Moderation\LingotekWorkbenchModerationSettingsForm::__construct()
- 3.4.x src/Moderation/LingotekWorkbenchModerationSettingsForm.php \Drupal\lingotek\Moderation\LingotekWorkbenchModerationSettingsForm::__construct()
- 3.5.x src/Moderation/LingotekWorkbenchModerationSettingsForm.php \Drupal\lingotek\Moderation\LingotekWorkbenchModerationSettingsForm::__construct()
- 3.6.x src/Moderation/LingotekWorkbenchModerationSettingsForm.php \Drupal\lingotek\Moderation\LingotekWorkbenchModerationSettingsForm::__construct()
- 3.7.x src/Moderation/LingotekWorkbenchModerationSettingsForm.php \Drupal\lingotek\Moderation\LingotekWorkbenchModerationSettingsForm::__construct()
- 3.8.x src/Moderation/LingotekWorkbenchModerationSettingsForm.php \Drupal\lingotek\Moderation\LingotekWorkbenchModerationSettingsForm::__construct()
Constructs a new LingotekWorkbenchModerationSettingsForm object.
Parameters
\Drupal\Core\Extension\ModuleHandlerInterface $module_handler: The module handler.
\Drupal\Core\Entity\EntityTypeManagerInterface $entity_type_manager: The entity type manager.
\Drupal\lingotek\Moderation\LingotekModerationConfigurationServiceInterface $moderation_configuration: A Lingotek moderation configuration service.
\Symfony\Component\DependencyInjection\ContainerInterface $container: The container from which optional services can be requested.
\Drupal\Core\Routing\UrlGeneratorInterface $url_generator: The url generator.
File
- src/
Moderation/ LingotekWorkbenchModerationSettingsForm.php, line 64
Class
- LingotekWorkbenchModerationSettingsForm
- Moderation settings form for the Lingotek workbench_moderation integration.
Namespace
Drupal\lingotek\ModerationCode
public function __construct(ModuleHandlerInterface $module_handler, EntityTypeManagerInterface $entity_type_manager, LingotekModerationConfigurationServiceInterface $moderation_configuration, ContainerInterface $container, UrlGeneratorInterface $url_generator = NULL) {
$this
->setModuleHandler($module_handler);
$this->entityTypeManager = $entity_type_manager;
$this->moderationConfiguration = $moderation_configuration;
// We need a service we cannot depend on, as it may not exist if the module
// is not present. Ignore the error.
if ($container
->has('workbench_moderation.moderation_information')) {
$this->moderationInfo = $container
->get('workbench_moderation.moderation_information');
}
$this->urlGenerator = $url_generator;
}