class LayoutParagraphsUpdateLayoutEvent in Layout Paragraphs 2.0.x
Class definition for Layout Paragraphs Allowed Types event.
Hierarchy
- class \Drupal\layout_paragraphs\Event\LayoutParagraphsUpdateLayoutEvent extends \Symfony\Component\EventDispatcher\Event
Expanded class hierarchy of LayoutParagraphsUpdateLayoutEvent
2 files declare their use of LayoutParagraphsUpdateLayoutEvent
File
- src/
Event/ LayoutParagraphsUpdateLayoutEvent.php, line 11
Namespace
Drupal\layout_paragraphs\EventView source
class LayoutParagraphsUpdateLayoutEvent extends Event {
const EVENT_NAME = 'layout_paragraphs_update_layout';
/**
* The origin layout object.
*
* @var \Drupal\layout_paragraphs\LayoutParagraphsLayout
*/
protected $originalLayout;
/**
* The updated layout object.
*
* @var \Drupal\layout_paragraphs\LayoutParagraphsLayout
*/
protected $layout;
/**
* TRUE if the entire layout needs to be refreshed.
*
* @var bool
*/
public $needsRefresh = FALSE;
/**
* Class cosntructor.
*
* @param \Drupal\layout_paragraphs\LayoutParagraphsLayout $original_layout
* The layout object.
* @param \Drupal\layout_paragraphs\LayoutParagraphsLayout $layout
* The layout object.
*/
public function __construct(LayoutParagraphsLayout $original_layout, LayoutParagraphsLayout $layout) {
$this->originalLayout = $original_layout;
$this->layout = $layout;
}
/**
* Get the original layout.
*
* @return \Drupal\layout_paragraphs\LayoutParagraphsLayout
* The original layout.
*/
public function getOriginalLayout() {
return $this->originalLayout;
}
/**
* Get the updated layout.
*
* @return \Drupal\layout_paragraphs\LayoutParagraphsLayout
* The updated layout.
*/
public function getUpdatedLayout() {
return $this->layout;
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
LayoutParagraphsUpdateLayoutEvent:: |
protected | property | The updated layout object. | |
LayoutParagraphsUpdateLayoutEvent:: |
public | property | TRUE if the entire layout needs to be refreshed. | |
LayoutParagraphsUpdateLayoutEvent:: |
protected | property | The origin layout object. | |
LayoutParagraphsUpdateLayoutEvent:: |
constant | |||
LayoutParagraphsUpdateLayoutEvent:: |
public | function | Get the original layout. | |
LayoutParagraphsUpdateLayoutEvent:: |
public | function | Get the updated layout. | |
LayoutParagraphsUpdateLayoutEvent:: |
public | function | Class cosntructor. |