]> git.immae.eu Git - github/wallabag/wallabag.git/blobdiff - src/Wallabag/CoreBundle/Event/Activity/Actions/Entry/EntryEvent.php
WIP
[github/wallabag/wallabag.git] / src / Wallabag / CoreBundle / Event / Activity / Actions / Entry / EntryEvent.php
diff --git a/src/Wallabag/CoreBundle/Event/Activity/Actions/Entry/EntryEvent.php b/src/Wallabag/CoreBundle/Event/Activity/Actions/Entry/EntryEvent.php
new file mode 100644 (file)
index 0000000..0e0c90d
--- /dev/null
@@ -0,0 +1,41 @@
+<?php
+
+namespace Wallabag\CoreBundle\Event\Activity\Actions\Entry;
+
+use Symfony\Component\EventDispatcher\Event;
+use Wallabag\CoreBundle\Entity\Entry;
+
+/**
+ * This event is fired when entry-related stuff is made.
+ */
+abstract class EntryEvent extends Event
+{
+    protected $entry;
+
+    /**
+     * EntryEvent constructor.
+     * @param Entry $entry
+     */
+    public function __construct(Entry $entry)
+    {
+        $this->entry = $entry;
+    }
+
+    /**
+     * @return Entry
+     */
+    public function getEntry()
+    {
+        return $this->entry;
+    }
+
+    /**
+     * @param Entry $entry
+     * @return EntryEvent
+     */
+    public function setEntry(Entry $entry)
+    {
+        $this->entry = $entry;
+        return $this;
+    }
+}