interface KeyProviderInterface in Key 8
Provides an interface for Key Provider plugins.
Hierarchy
- interface \Drupal\key\Plugin\KeyProviderInterface
Expanded class hierarchy of KeyProviderInterface
All classes that implement KeyProviderInterface
File
- src/
Plugin/ KeyProviderInterface.php, line 11
Namespace
Drupal\key\PluginView source
interface KeyProviderInterface {
/**
* Returns the value of a key.
*
* @param \Drupal\key\KeyInterface $key
* The key whose value will be retrieved.
*
* @return string
* The key value.
*/
public function getKeyValue(KeyInterface $key);
/**
* Obscures a key value.
*
* @param string $key_value
* The key value to obscure.
* @param array $options
* Options to use when obscuring the value.
*
* @return string
* The obscured key value.
*/
public static function obscureKeyValue($key_value, array $options);
/**
* Allows a key provider to perform actions after a key entity is saved.
*
* @param \Drupal\key\KeyInterface $key
* The key entity that was saved.
* @param \Drupal\Core\Entity\EntityStorageInterface $storage
* The entity storage object.
* @param bool $update
* TRUE if the entity has been updated, or FALSE if it has been inserted.
*/
public function postSave(KeyInterface $key, EntityStorageInterface $storage, $update = TRUE);
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
KeyProviderInterface:: |
public | function | Returns the value of a key. | 4 |
KeyProviderInterface:: |
public static | function | Obscures a key value. | 1 |
KeyProviderInterface:: |
public | function | Allows a key provider to perform actions after a key entity is saved. | 1 |