本文整理汇总了PHP中Drupal\Core\Entity\EntityAccessControlHandler::__construct方法的典型用法代码示例。如果您正苦于以下问题:PHP EntityAccessControlHandler::__construct方法的具体用法?PHP EntityAccessControlHandler::__construct怎么用?PHP EntityAccessControlHandler::__construct使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Drupal\Core\Entity\EntityAccessControlHandler
的用法示例。
在下文中一共展示了EntityAccessControlHandler::__construct方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: __construct
/**
* Constructs the block access control handler instance
*
* @param \Drupal\Core\Entity\EntityTypeInterface $entity_type
* The entity type definition.
* @param \Drupal\Core\Executable\ExecutableManagerInterface $manager
* The ConditionManager for checking visibility of blocks.
* @param \Drupal\Core\Plugin\Context\ContextHandlerInterface $context_handler
* The ContextHandler for applying contexts to conditions properly.
* @param \Drupal\Core\Plugin\Context\ContextRepositoryInterface $context_repository
* The lazy context repository service.
*/
public function __construct(EntityTypeInterface $entity_type, ExecutableManagerInterface $manager, ContextHandlerInterface $context_handler, ContextRepositoryInterface $context_repository)
{
parent::__construct($entity_type);
$this->manager = $manager;
$this->contextHandler = $context_handler;
$this->contextRepository = $context_repository;
}
示例2: __construct
public function __construct(EntityTypeInterface $entity_type, FillPdfAccessHelperInterface $access_helper, FillPdfLinkManipulatorInterface $link_manipulator, FillPdfContextManagerInterface $context_manager) {
parent::__construct($entity_type);
$this->accessHelper = $access_helper;
$this->linkManipulator = $link_manipulator;
$this->contextManager = $context_manager;
}
示例3: __construct
/**
* Creates a new MenuLinkContentAccessControlHandler.
*
* @param \Drupal\Core\Entity\EntityTypeInterface $entity_type
* The entity type definition.
* @param \Drupal\Core\Access\AccessManagerInterface $access_manager
* The access manager to check routes by name.
*/
public function __construct(EntityTypeInterface $entity_type, AccessManagerInterface $access_manager)
{
parent::__construct($entity_type);
$this->accessManager = $access_manager;
}
示例4: __construct
/**
* Constructs a NodeAccessControlHandler object.
*
* @param \Drupal\Core\Entity\EntityTypeInterface $entity_type
* The entity type definition.
* @param \Drupal\node\NodeGrantDatabaseStorageInterface $grant_storage
* The node grant storage.
*/
public function __construct(EntityTypeInterface $entity_type, NodeGrantDatabaseStorageInterface $grant_storage)
{
parent::__construct($entity_type);
$this->grantStorage = $grant_storage;
}
示例5: __construct
/**
* Constructs an access control handler instance.
*
* @param \Drupal\Core\Entity\EntityTypeInterface $entity_type
* The entity type definition.
* @param \Drupal\Core\Plugin\Context\ContextHandlerInterface $context_handler
* The context handler.
*/
public function __construct(EntityTypeInterface $entity_type, ContextHandlerInterface $context_handler)
{
parent::__construct($entity_type);
$this->contextHandler = $context_handler;
}
示例6: __construct
/**
* {@inheritdoc}
*/
public function __construct(EntityTypeInterface $entity_type)
{
parent::__construct($entity_type);
$this->eventManager = \Drupal::service('rng.event_manager');
}
示例7: __construct
/**
* Constructs a ShortcutAccessControlHandler object.
*
* @param \Drupal\Core\Entity\EntityTypeInterface $entity_type
* The entity type definition.
* @param \Drupal\shortcut\ShortcutSetStorageInterface $shortcut_set_storage
* The shortcut_set storage.
*/
public function __construct(EntityTypeInterface $entity_type, ShortcutSetStorageInterface $shortcut_set_storage)
{
parent::__construct($entity_type);
$this->shortcutSetStorage = $shortcut_set_storage;
}
示例8: __construct
/**
* Constructs a NodeAccessControlHandler object.
*
* @param \Drupal\Core\Entity\EntityTypeInterface $entity_type
* The entity type definition.
*/
public function __construct(EntityTypeInterface $entity_type) {
parent::__construct($entity_type);
}
示例9: __construct
/**
* Constructor
*
* @param \Drupal\Core\Entity\EntityTypeInterface $entity_type
* The entity info for the entity type.
* @param \Drupal\Core\Extension\ModuleHandlerInterface $module_handler
* The module handler.
*/
public function __construct(EntityTypeInterface $entity_type, ModuleHandlerInterface $module_handler)
{
parent::__construct($entity_type);
$this->moduleHandler = $module_handler;
}
示例10: __construct
/**
* Constructs a TranslatorAccessControlHandler object.
*
* @param \Drupal\Core\Entity\EntityTypeInterface $entity_type
* The entity type definition.
* @param \Drupal\tmgmt\TranslatorManager $translator_manager
* The translator manager.
*/
public function __construct(EntityTypeInterface $entity_type, TranslatorManager $translator_manager)
{
parent::__construct($entity_type);
$this->translatorManager = $translator_manager;
}