I\'m working in the Symfony2 framework and wondering when would one use a Doctrine subscriber versus a listener. Doctrine\'s documentation for listeners is very clear, howe
From my point of view, there is only one major difference:
This might not seem like a big difference, but if you think about it, there are some cases when you want to use one over the other:
getSubscribedEvents
(Think about a time where you listen to a very noisy event and you only want to execute something one time)There might be other differences I'm not aware of though!