You are here

interface MailingListManagerInterface in Mailing List 8

Interface definition for the mailing list manager service.

Hierarchy

Expanded class hierarchy of MailingListManagerInterface

All classes that implement MailingListManagerInterface

2 files declare their use of MailingListManagerInterface
MailingListController.php in src/Controller/MailingListController.php
SubscriptionBlock.php in src/Plugin/Block/SubscriptionBlock.php

File

src/MailingListManagerInterface.php, line 10

Namespace

Drupal\mailing_list
View source
interface MailingListManagerInterface {

  /**
   * Grants the current user access to a subscription for the current session.
   *
   * @param \Drupal\mailing_list\SubscriptionInterface\SubscriptionInterface $subscription
   *   The subscription.
   */
  public function grantSessionAccess(SubscriptionInterface $subscription);

  /**
   * Revoke any session access to a subscription to the current user.
   *
   * @param \Drupal\mailing_list\SubscriptionInterface\SubscriptionInterface $subscription
   *   The subscription.
   */
  public function revokeSessionAccess(SubscriptionInterface $subscription);

  /**
   * Checks if the current user has session access to a given subscription.
   *
   * @param \Drupal\mailing_list\SubscriptionInterface\SubscriptionInterface $subscription
   *   The subscription.
   *
   * @return bool
   *   TRUE if the current user has session access granted to the subscription.
   */
  public function hasSessionAccess(SubscriptionInterface $subscription);

}

Members

Namesort descending Modifiers Type Description Overrides
MailingListManagerInterface::grantSessionAccess public function Grants the current user access to a subscription for the current session. 1
MailingListManagerInterface::hasSessionAccess public function Checks if the current user has session access to a given subscription. 1
MailingListManagerInterface::revokeSessionAccess public function Revoke any session access to a subscription to the current user. 1