diff options
Diffstat (limited to 'vendor/doctrine/orm/src/Mapping/OwningSideMapping.php')
-rw-r--r-- | vendor/doctrine/orm/src/Mapping/OwningSideMapping.php | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/vendor/doctrine/orm/src/Mapping/OwningSideMapping.php b/vendor/doctrine/orm/src/Mapping/OwningSideMapping.php new file mode 100644 index 0000000..ab8b7b2 --- /dev/null +++ b/vendor/doctrine/orm/src/Mapping/OwningSideMapping.php | |||
@@ -0,0 +1,28 @@ | |||
1 | <?php | ||
2 | |||
3 | declare(strict_types=1); | ||
4 | |||
5 | namespace Doctrine\ORM\Mapping; | ||
6 | |||
7 | abstract class OwningSideMapping extends AssociationMapping | ||
8 | { | ||
9 | /** | ||
10 | * required for bidirectional associations | ||
11 | * The name of the field that completes the bidirectional association on | ||
12 | * the inverse side. This key must be specified on the owning side of a | ||
13 | * bidirectional association. | ||
14 | */ | ||
15 | public string|null $inversedBy = null; | ||
16 | |||
17 | /** @return list<string> */ | ||
18 | public function __sleep(): array | ||
19 | { | ||
20 | $serialized = parent::__sleep(); | ||
21 | |||
22 | if ($this->inversedBy !== null) { | ||
23 | $serialized[] = 'inversedBy'; | ||
24 | } | ||
25 | |||
26 | return $serialized; | ||
27 | } | ||
28 | } | ||