-
-
Notifications
You must be signed in to change notification settings - Fork 188
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3292 from acrobat/nested_subentity_deletes
[PagePartBundle] Allow deleting nested sub-entities
- Loading branch information
Showing
2 changed files
with
101 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
<?php | ||
|
||
namespace Kunstmaan\PagePartBundle\Dto; | ||
|
||
/** | ||
* @internal | ||
*/ | ||
final class PagePartDeleteInfo | ||
{ | ||
private string $name; | ||
private string $id; | ||
private ?PagePartDeleteInfo $nestedDeleteInfo; | ||
|
||
public function __construct(string $name, string $id, ?self $nestedDeleteInfo) | ||
{ | ||
$this->name = $name; | ||
$this->id = $id; | ||
$this->nestedDeleteInfo = $nestedDeleteInfo; | ||
} | ||
|
||
public function getName(): string | ||
{ | ||
return $this->name; | ||
} | ||
|
||
public function getId(): string | ||
{ | ||
return $this->id; | ||
} | ||
|
||
public function getNestedDeleteInfo(): ?PagePartDeleteInfo | ||
{ | ||
return $this->nestedDeleteInfo; | ||
} | ||
|
||
public function hasNestedDeleteInfo(): bool | ||
{ | ||
return null !== $this->nestedDeleteInfo; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters