You are here

UserManagementServiceInterface.php in Auto Purge Users 8.3

Same filename and directory in other branches
  1. 8.2 src/Services/UserManagementServiceInterface.php

File

src/Services/UserManagementServiceInterface.php
View source
<?php

namespace Drupal\purge_users\Services;

use Drupal\user\UserInterface;

/**
 * Contract for the purge service.
 */
interface UserManagementServiceInterface {

  /**
   * Cancel a user and anonymize it.
   *
   * @param \Drupal\user\UserInterface $user
   *   The user to block.
   * @param string $method
   *   The cancel method to use.
   */
  public function purgeUser(UserInterface $user, string $method);

  /**
   * Sends a user notification before cancel and anonymize it.
   *
   * @param \Drupal\user\UserInterface $user
   *   The user to block.
   */
  public function notifyUser(UserInterface $user) : void;

}

Interfaces

Namesort descending Description
UserManagementServiceInterface Contract for the purge service.