Code Coverage |
||||||||||||||||
Lines |
Branches |
Paths |
Functions and Methods |
Classes and Traits |
||||||||||||
| Total | n/a |
0 / 0 |
n/a |
0 / 0 |
n/a |
0 / 0 |
n/a |
0 / 0 |
CRAP | n/a |
0 / 0 |
|||||
| IslandReloadEventsTrait | n/a |
0 / 0 |
n/a |
0 / 0 |
n/a |
0 / 0 |
n/a |
0 / 0 |
0 | n/a |
0 / 0 |
|||||
| 1 | <?php |
| 2 | |
| 3 | declare(strict_types=1); |
| 4 | |
| 5 | namespace Drupal\display_builder\Island; |
| 6 | |
| 7 | /** |
| 8 | * Convenience trait combining structure and lifecycle reload event handlers. |
| 9 | * |
| 10 | * Composes IslandStructureReloadTrait and IslandLifecycleReloadTrait to provide |
| 11 | * full reload-on-event behavior for the most common handler groups. All eight |
| 12 | * implemented methods delegate to reloadWithGlobalData(), which the using |
| 13 | * island plugin must provide. |
| 14 | * |
| 15 | * Plugins that also need to react to onPublish(), onPresetSave(), or |
| 16 | * onActive() must implement those methods explicitly. |
| 17 | * |
| 18 | * This trait is kept as a convenience aggregate for the six island plugins that |
| 19 | * already use it. New islands should prefer composing the focused sub-traits |
| 20 | * (IslandStructureReloadTrait, IslandLifecycleReloadTrait) directly. |
| 21 | * |
| 22 | * @see \Drupal\display_builder\Island\IslandStructureReloadTrait |
| 23 | * @see \Drupal\display_builder\Island\IslandLifecycleReloadTrait |
| 24 | */ |
| 25 | trait IslandReloadEventsTrait { |
| 26 | |
| 27 | use IslandStructureReloadTrait; |
| 28 | use IslandLifecycleReloadTrait; |
| 29 | |
| 30 | } |