diff --git a/application/Espo/Core/Hook/Hook/AfterMassRelate.php b/application/Espo/Core/Hook/Hook/AfterMassRelate.php index 9789e547ef..b1173ad855 100644 --- a/application/Espo/Core/Hook/Hook/AfterMassRelate.php +++ b/application/Espo/Core/Hook/Hook/AfterMassRelate.php @@ -36,7 +36,7 @@ use Espo\ORM\Repository\Option\MassRelateOptions; /** * An afterMassRelate hook. * - * @template TEntity of Entity + * @template TEntity of Entity = Entity */ interface AfterMassRelate { diff --git a/application/Espo/Core/Hook/Hook/AfterRelate.php b/application/Espo/Core/Hook/Hook/AfterRelate.php index 1c74bae4ad..bc9e0774c7 100644 --- a/application/Espo/Core/Hook/Hook/AfterRelate.php +++ b/application/Espo/Core/Hook/Hook/AfterRelate.php @@ -35,7 +35,8 @@ use Espo\ORM\Repository\Option\RelateOptions; /** * An afterRelate hook. * - * @template TEntity of Entity + * @template TEntity of Entity = Entity + * @template TRelatedEntity of Entity = Entity */ interface AfterRelate { @@ -44,7 +45,7 @@ interface AfterRelate * * @param TEntity $entity An entity. * @param string $relationName A relation name. - * @param Entity $relatedEntity An entity is being related. + * @param TRelatedEntity $relatedEntity An entity is being related. * @param array $columnData Middle table role values. * @param RelateOptions $options Options. */ diff --git a/application/Espo/Core/Hook/Hook/AfterRemove.php b/application/Espo/Core/Hook/Hook/AfterRemove.php index d4252ca4db..133aed666d 100644 --- a/application/Espo/Core/Hook/Hook/AfterRemove.php +++ b/application/Espo/Core/Hook/Hook/AfterRemove.php @@ -35,7 +35,7 @@ use Espo\ORM\Repository\Option\RemoveOptions; /** * An afterRemove hook. * - * @template TEntity of Entity + * @template TEntity of Entity = Entity */ interface AfterRemove { diff --git a/application/Espo/Core/Hook/Hook/AfterSave.php b/application/Espo/Core/Hook/Hook/AfterSave.php index c9938f422b..f8cbf78dd0 100644 --- a/application/Espo/Core/Hook/Hook/AfterSave.php +++ b/application/Espo/Core/Hook/Hook/AfterSave.php @@ -35,7 +35,7 @@ use Espo\ORM\Repository\Option\SaveOptions; /** * An afterSave hook. * - * @template TEntity of Entity + * @template TEntity of Entity = Entity */ interface AfterSave { diff --git a/application/Espo/Core/Hook/Hook/AfterUnrelate.php b/application/Espo/Core/Hook/Hook/AfterUnrelate.php index e020f435e0..175972f7a5 100644 --- a/application/Espo/Core/Hook/Hook/AfterUnrelate.php +++ b/application/Espo/Core/Hook/Hook/AfterUnrelate.php @@ -35,7 +35,8 @@ use Espo\ORM\Repository\Option\UnrelateOptions; /** * An afterUnrelate hook. * - * @template TEntity of Entity + * @template TEntity of Entity = Entity + * @template TRelatedEntity of Entity = Entity */ interface AfterUnrelate { @@ -44,7 +45,7 @@ interface AfterUnrelate * * @param TEntity $entity An entity. * @param string $relationName A relation name. - * @param Entity $relatedEntity An entity is being unrelated. + * @param TRelatedEntity $relatedEntity An entity is being unrelated. * @param UnrelateOptions $options Options. */ public function afterUnrelate( diff --git a/application/Espo/Core/Hook/Hook/BeforeRemove.php b/application/Espo/Core/Hook/Hook/BeforeRemove.php index a2b7615d3a..a7c944bdb1 100644 --- a/application/Espo/Core/Hook/Hook/BeforeRemove.php +++ b/application/Espo/Core/Hook/Hook/BeforeRemove.php @@ -35,7 +35,7 @@ use Espo\ORM\Repository\Option\RemoveOptions; /** * An beforeRemove hook. * - * @template TEntity of Entity + * @template TEntity of Entity = Entity */ interface BeforeRemove { diff --git a/application/Espo/Core/Hook/Hook/BeforeSave.php b/application/Espo/Core/Hook/Hook/BeforeSave.php index 67666d642b..dad80416a4 100644 --- a/application/Espo/Core/Hook/Hook/BeforeSave.php +++ b/application/Espo/Core/Hook/Hook/BeforeSave.php @@ -35,7 +35,7 @@ use Espo\ORM\Repository\Option\SaveOptions; /** * A beforeSave hook. * - * @template TEntity of Entity + * @template TEntity of Entity = Entity */ interface BeforeSave { diff --git a/application/Espo/Hooks/Common/Stream.php b/application/Espo/Hooks/Common/Stream.php index e0ce8ac28c..94ef170d16 100644 --- a/application/Espo/Hooks/Common/Stream.php +++ b/application/Espo/Hooks/Common/Stream.php @@ -42,13 +42,6 @@ use Espo\ORM\Repository\Option\SaveOptions; use Espo\ORM\Repository\Option\UnrelateOptions; use Espo\Tools\Stream\HookProcessor; -/** - * @implements BeforeSave - * @implements AfterSave - * @implements AfterRemove - * @implements AfterRelate - * @implements AfterUnrelate - */ class Stream implements BeforeSave, AfterSave, AfterRemove, AfterRelate, AfterUnrelate { public static int $order = 9; diff --git a/application/Espo/ORM/EntityCollection.php b/application/Espo/ORM/EntityCollection.php index c09a085c9f..3a83a4b522 100644 --- a/application/Espo/ORM/EntityCollection.php +++ b/application/Espo/ORM/EntityCollection.php @@ -42,7 +42,7 @@ use Closure; /** * A standard collection of entities. It allocates a memory for all entities. * - * @template TEntity of Entity + * @template TEntity of Entity = Entity * @implements Iterator * @implements Collection * @implements ArrayAccess