interface IpBanSetBanInterface in IP Ban 8
Hierarchy
- interface \Drupal\ip_ban\IpBanSetBanInterface
Expanded class hierarchy of IpBanSetBanInterface
All classes that implement IpBanSetBanInterface
1 file declares its use of IpBanSetBanInterface
- IpBanSubscriber.php in src/
EventSubscriber/ IpBanSubscriber.php - Contains \Drupal\ip_ban\EventSubscriber\IpBanSubscriber.
File
- src/
IpBanSetBanInterface.php, line 10 - Contains \Drupal\ip_ban\IpBanSetBanInterface.
Namespace
Drupal\ip_banView source
interface IpBanSetBanInterface {
/**
* Set the user's ban value based on their country or individual IP address.
*
* Load the user's country code based on their IP address, then check if
* that country is set to complete ban, read-only, or has no access
* restrictions. We then do the same for any additional read-only or complete
* ban IP addresses added. If the user matched a country or an IP address
* entered, then they are shown a message and/or redirected based on complete
* ban or read-only.
*/
public function iPBanSetValue();
/**
* Returns the ban value currently set.
*
* @return int
* The user's ban value (one of IP_BAN_NOBAN (0), IP_BAN_READONLY (1),
* or IP_BAN_BANNED (2), which are defined in the .module file.
*/
public function getBanValue();
/**
* Determines action based on current user's ban setting.
*
* Determine the action based on the user's ban setting. If the user is
* anonymous, this will be set via middleware; otherwise it will be set via
* an event subscriber.
*/
public function iPBanDetermineAction();
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
IpBanSetBanInterface:: |
public | function | Returns the ban value currently set. | 1 |
IpBanSetBanInterface:: |
public | function | Determines action based on current user's ban setting. | 1 |
IpBanSetBanInterface:: |
public | function | Set the user's ban value based on their country or individual IP address. | 1 |