public function DefaultParagraphsAddEvent::__construct in Default Paragraphs 8
DefaultParagraphsAddEvent constructor.
Parameters
\Drupal\paragraphs\ParagraphInterface $paragraph_entity: The paragraph entity being created.
string $target_bundle: The bundle, which the paragraph is referenced to.
File
- src/
Events/ DefaultParagraphsAddEvent.php, line 35
Class
- DefaultParagraphsAddEvent
- Represents Paragraph Entity adding as default.
Namespace
Drupal\default_paragraphs\EventsCode
public function __construct(ParagraphInterface $paragraph_entity, $target_bundle) {
$this->paragraphEntity = $paragraph_entity;
$this->targetBundle = $target_bundle;
}