class NodePreviewAccessCheck implements AccessInterface (View source)

Determines access to node previews.

Properties

protected EntityTypeManagerInterface $entityTypeManager

The entity type manager service.

Methods

__construct(EntityTypeManagerInterface $entity_type_manager)

Constructs an EntityCreateAccessCheck object.

access(AccountInterface $account, NodeInterface $node_preview)

Checks access to the node preview page.

Details

__construct(EntityTypeManagerInterface $entity_type_manager)

Constructs an EntityCreateAccessCheck object.

Parameters

EntityTypeManagerInterface $entity_type_manager

The entity type manager service.

AccessResultInterface access(AccountInterface $account, NodeInterface $node_preview)

Checks access to the node preview page.

Parameters

AccountInterface $account

The currently logged in account.

NodeInterface $node_preview

The node that is being previewed.

Return Value

AccessResultInterface

The access result.