4 * Contains \Drupal\bootstrap\Plugin\Alter\AlterInterface.
7 namespace Drupal\bootstrap\Plugin\Alter;
10 * Defines the interface for an object oriented alter.
12 * @ingroup plugins_alter
14 interface AlterInterface {
17 * Alters data for a specific hook_TYPE_alter() implementation.
20 * The variable that will be passed to hook_TYPE_alter() implementations to
21 * be altered. The type of this variable depends on the value of the $type
22 * argument. For example, when altering a 'form', $data will be a structured
23 * array. When altering a 'profile', $data will be an object.
24 * @param mixed $context1
25 * (optional) An additional variable that is passed by reference.
26 * @param mixed $context2
27 * (optional) An additional variable that is passed by reference. If more
28 * context needs to be provided to implementations, then this should be an
29 * associative array as described above.
31 public function alter(&$data, &$context1 = NULL, &$context2 = NULL);